Yogesh Chauhan's Blog

Solution for the error Commit failed – exit code 1 received in Desktop Github

in Miscellaneous on July 28, 2020

From GitHub Desktop Team:

Some users have run into this error due to having nested .git directories. Please try searching your repository to see if you have multiple .git directories.

For most users, the above solution should work. If that doesn't work then check if you have added files to your index. You can do that using the command line — basically check your git status.

If you commit changes in sub-module then GitHub Desktop is able to push and/or commit changes after that. After sub-module is committed manually SHA1 changes from dirty. At this point I can commit to main repo.

Sometimes, you might not have any nested .git folders. You can just remove the repo from GitHub Desktop and add it again. You only need to remove it from GitHub and not from your hard drive.

There are few other solutions available on the GitHub's issues page. Good luck!

Most Read

#1 Solution to the error “Visual Studio Code can’t be opened because Apple cannot check it for malicious software” #2 How to add Read More Read Less Button using JavaScript? #3 How to check if radio button is checked or not using JavaScript? #4 Solution to “TypeError: ‘x’ is not iterable” in Angular 9 #5 How to uninstall Cocoapods from the Mac OS? #6 PHP Login System using PDO Part 1: Create User Registration Page

Recently Posted

#Apr 8 JSON.stringify() in JavaScript #Apr 7 Middleware in NextJS #Jan 17 4 advanced ways to search Colleague #Jan 16 Colleague UI Basics: The Search Area #Jan 16 Colleague UI Basics: The Context Area #Jan 16 Colleague UI Basics: Accessing the user interface
You might also like these
How to undo Git Commits on Pantheon?MiscellaneousAvoid using new Array() in JavaScriptJavaScriptFlash of Invisible Text and Mitt Romney Web Font ProblemCSSSQL Right JoinSQL/MySQLUnderstand Inheritance in PHP in this Basic Example (For Beginners)PHPQuick Introduction to 11 Array Iteration Methods in JavaScriptJavaScriptA simple example on grid ‘auto-fill’ vs ‘auto-fit’CSSCREATE DATABASE in PostgreSQLPostgresHow to create a flip effect with CSS?CSSFile System Integrity: How to Keep an Eye on Your Files and Folder Change?MiscellaneousWhat are Modules and Components in Angular?AngularHow different is Handling Events in React vs HTML DOM?React