A repository to play around with git and Gitub, learning along the way!
Needless to mention, Git should be installed in your system.
sudo apt install git-all
Here is a list of problems that I faced and found a workaround for!
If you have mistakenly initialised your git repository in the wrong parent or root directory of the desired directroy, you can fix it without losing any logs and git status would return only renamed files.
Example:
current: git-explore/inside/.git
desired: git-explore/.git
Solution:
mv .git ../
cd ../
git add inside/
git commit -a
Example:
current: git-explore/.git
desired: git-explore/inside/.git
Solution:
mv .git inside/
cd inside/
git add .
git commit -a
After the inspiration hit me, I was trying to find a way to write commit messages with bodies but I didn't want to do it separately in a proper text editor (who has the time and patience for that) and wanted to do the same from the CL itself.
Here is how you can do it!
git commit -m "Title" -m "Description"
PRs are welcome! :)