Useful Git Commands

Useful Git Commands Create New Branch and Switch to Branch Clean Cache for Untracked Files  Clean All Untracked Directories  Clean

admin ·

Useful Git Commands

Create New Branch and Switch to Branch

[sourcecode language=”plain”]git checkout -b branch_name[/sourcecode]

Clean Cache for Untracked Files 

[sourcecode language=”plain”]
git rm -r –cached .
git add .
git commit -m “fixed untracked files”
[/sourcecode]

Clean All Untracked Directories 

[sourcecode language=”plain”]git clean -f -d[/sourcecode]

Clean All Untracked Files 

[sourcecode language=”plain”]git clean -f[/sourcecode]

Stage All Deleted Files 

[sourcecode language=”plain”]git ls-files –deleted -z | xargs -0 git rm[/sourcecode]

Post Author Profile Image

admin

Hi i am an admin of provis technologies.

I am an ambitious workaholic, but apart from that, pretty simple person. Whether it's branding, print, UI + UX I've got you covered. I strive to figure out the right solutions for your look to stand out amongst the rest.

All posts by admin

Add Comment

Your email address will not be published. Required fields are marked *