threads / discuss / 26545

Hint for rebase in progress

Subject: Hint for rebase in progress

## tl;dr

2 messages between Feb 18, 2011 and Feb 18, 2011.

replies: 1people: 2as markdown or json

Jeenu V· Feb 18, 2011, 08:12 UTC · lore

I was once in the middle of an interactive rebase, editing a commit and happened to do a git status. I could see that Git warns in red color "Not currently on any branch". Similarly, git branch said "* (no branch)". Having gone this far, wouldn't it be helpful for Git to also remind "Rebase in progress" or something like that, some where in these hints? Since git status is meant to display the current status of the tree, I think it's only apt for it to report so.

Because, once in a active rebase session, I think there's no command which tells user that an interactive session is in progress (or is there?); gitk doesn't help either. If the user happens to take a break or something, it might be bit perplexing to figure out where he was, why it was (seeing the working directory headless).

-- 
Jeenu
Stefan Naewe· Feb 18, 2011, 09:07 UTC · re: Jeenu V · lore

Re: Hint for rebase in progress

On 2/18/2011 9:12 AM, Jeenu V wrote:
Show 14 quoted lines
> I was once in the middle of an interactive rebase, editing a commit
> and happened to do a git status. I could see that Git warns in red
> color "Not currently on any branch". Similarly, git branch said "* (no
> branch)". Having gone this far, wouldn't it be helpful for Git to also
> remind "Rebase in progress" or something like that, some where in
> these hints? Since git status is meant to display the current status
> of the tree, I think it's only apt for it to report so.
> 
> Because, once in a active rebase session, I think there's no command
> which tells user that an interactive session is in progress (or is
> there?); gitk doesn't help either. If the user happens to take a break
> or something, it might be bit perplexing to figure out where he was,
> why it was (seeing the working directory headless).
> 

Look in $OFFICIAL-GIT-REPO/contrib/completion/git-completion.bash. Set your 'PS1' as explained there and you will see at your command prompt if you're currently rebasing.

HTH,
  Stefan
-- 
----------------------------------------------------------------
/dev/random says: URA Redneck if you own a homemade fur coat.

← back to recent threads