batou icon indicating copy to clipboard operation
batou copied to clipboard

Improve lib.git with branch

Open zagy opened this issue 5 years ago • 1 comments

The current behaviour is a bit odd. git.Clone with branch makes sure the right version is there, but it resets the master.

@gforcada wrote:

One could do git clean -dfxq to get rid of all untracked files and then follow it with a regular git checkout BRANCH/REVISION.

zagy avatar Oct 29 '19 14:10 zagy

@gforcada the git clean -x – I'm not sure about that. That is, I'm not against it, I just really don't know if that's a good idea. It would remove all untracked files, including the ignored ones. While is will allow a quite stable switch, it will, well, remove things. So it'll remove stuff like .pyc files. I can imagine, that this could delete too much.

One could also argue that this is a repo and there should not be anything in there.

zagy avatar Feb 28 '20 14:02 zagy