Help:
We made a branch in git called “–track” by accident, and now we can’t get rid of it. git thinks it’s a command-line argument, even when it’s in quotes.
Here’s the command what did it:
$ git checkout -b --track origin/actual_branch_name Branch --track set up to track remote branch refs/remotes/origin/actual_branch_name. Switched to a new branch "--track"
Consensus: kill it through RubyMine or gitX. There is also a way through the command line:
$ git branch -d -- --track
…but make sure you get the dashes in all the right places.
Interesting:
reset after tail – sometimes, if your PS1 has colors (or square brackets, or … ?) you can lose your Terminal after tailing a file. To get it back, type
reset, which should work even if you can’t see it echoing. You may need an extra return before it.The Giants seem to have won! There’s a parade tomorrow, right in front of the office. If you’re coming for the tech talk, leave extra time as streets will be closed and they’re expecting a crowd.
I get the terminal issue without fail when tailing development log, but not many other types of files. I think it must be improperly closed colors.
November 2, 2010 at 10:05 am
Using `–` is a good thing to know, and is applicable to any shell command, not just git. It means ‘nothing after this is an option’.
I used to used it as part of my questionnaire for employing sys admins: ‘How would you delete a file called `-rf *` in your home directory?’
November 2, 2010 at 1:46 pm