WordPress, GIT, Renamed Plugin Dir + files – oops!

This post might not belong here, but I didn’t see anything covering this topic when I searched, so here goes…

I’ve been working on a custom plugin, and I’m getting close to being finished with it. I’ve been keeping a repo on Github to track my changes. I don’t know what I did, but somehow I managed to cause my code to stop working in my local repo. I tried git reset --hard HEAD~1 (as I didn’t make note of the commit hash prior). That didn’t help because i am somehow misplacing the commit that WAS working.

This isn’t the first time i’ve messed up using Github. I want to say “what is the point, if your code gets messed up!” (calm down, Geoffrey!).

I know I can DIFF at Github, but how would I go about that if, E.g. I changed the directory name of a plugin? and need to see code from files in directories with different names, from different commits?

  • This topic was modified 41 minutes ago by Jan Dembowski. Reason: Moved to Fixing WordPress, this is not an Developing with WordPress topic

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer