Is "git clean" followed by "git stash clear" redundant when creating a pristine checkout? -
I would like to write a script that guarantees successful checks without user intervention. I am not dumping anything that can not be solved without user intervention: For example, without any latent change, I want to keep the files that I have clearly not seen (I consider them "under version control").
I've created a script based on fixing the problems encountered over time and fixing problems (as it does at all and not at all).
Now I am concerned that my piece-script script has talent, or can be small. Is any of the following calls unnecessary?
CD / Some / FDA GIT Clean-DF & amp; GIT Checkout GIT Stache GIT Steps Clean GIT Checkout Ao-Branch # or GIT Checkout-A Ao-Remote Some Branches [1] # Possible for Manual Call: GIT Bridge - Ribbase Ao-Remote
[1] Can this call be git checkout -f
and git checkout -fB
?
is that I use one of my own build scripts with any branch in HEAD < / Code> (in place of the
HEAD
) to clean checkout or whatever you want, or use a shell variable):
if [$ (git status - Republican-venture | wc -l) - Gt 0]; Then echo "Making old check of the head" GIT Reset - Quite - Hard Head GIT Clean - Quiet - FDI
If
checks whether anything is to be done. If you do not care about the slight increase in efficiency then you can leave it (or even be).
If you also want to delete the files that are ignoring rules ( .gitignore
files), then you -x < / Code> option must be given to
git-clean
, and - ignored
git-status
option; You said that you not want to do this.
I do not think any other calls you make are necessary. Cleaning is not necessary to clean up the place (but it does not hurt, either).
Comments
Post a Comment