Skip to main content

Command Palette

Search for a command to run...

Microsoft October Challenge Learning ?

Published
2 min read
S

I love learning about technology and sharing that with others

Here i am basically documenting what i have learned during the process of the Microsoft October learning challenge

This one is the coolest ever ?

  • Lets say you made some commit and made some mistake in last commit you fixed it and now you have to make another commit but it will show more commits with the changes to avoid this , with this we can make changes and those will be added to the last commit ,
git commit --amend --no-edit

How to add all the files from the last commit ?

-a flag will add all the files which has modified from last commit so, here basically we don't need to add the files again and again.

git commit -a -m "Add a heading to index.html"

Git Does not track empty Folder

Git doesn't consider adding an empty directory to be a change. That's because Git tracks only changes to files, not changes to directories. In that case we can add a file name as .git-keep in that folder and later we can remove that

Why Git is faster?

Git records the contents of your files rather than the deltas (changes) between them. That's a large part of what makes committing, branching, and switching between branches so fast in Git. Other VCSes have to apply a list of changes to get between one version of a file and another. Git just unzips the other version.

Git log in one liner

git log --oneline

Git log last few commits

this will give you last 3 commits

git log -n3
14 views

More from this blog

H

hashcodehub

271 posts

Consistent, Passionate and Organized :)