"Revert this commit" error

I’ve been committing versions of my code through VS Code and want to revert to a previous version using GitHub Desktop. As I understand it I have to “Revert this commit” from History and then recommit it?

I’ve tried doing this. The app first warns me about committing a conflicted file and then I get a “Commit failed - exit code 1 received” error. I googled the error and apparently this can happen if there are nested repositories. I had initially created a copy of the repo inside the original repo as recommended on a site I’d read. When I couldn’t see a use for it I deleted it using file explorer and it doesn’t show up at all when I select “Repository list”.

Any ideas on where I go from here?

Hi gottogethelp! :wave: If it’s no longer showing up in your repository list, that suggests you may have deleted the whole repo, rather than the copy inside the repo?

Can you still see the repo in file explorer? Are you able to add it back to GitHub Desktop:


It might be worth noting that Git history is stored in a hidden .git folder, so you’d need to make sure you are viewing hidden files when using file explorer.

1 Like

Hi. Thanks for replying. I definitely have the original repo - the delete I was referring to was deleting the copy of the repo I made inside the repo folder. I have no idea why the setup website I read recommended this but I decided to remove it.

Touch wood things seem to be working fine now after doing precisely nothing different. Thanks again for replying!