git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [RFC/PATCH v2] create a skeleton for the command git rebase --status

From
GPGuillaume Pages <guillaume.pages@ensimag.grenoble-inp.fr>
Date
May 29, 2015, 10:40 UTC
Message-ID
<12496325.145058.1432896023146.JavaMail.zimbra@ensimag.grenoble-inp.fr>
In-Reply-To
<xmqq382gh465.fsf@gitster.dls.corp.google.com>

After this discussion I eventually agree that it would be better upgrading git status than creating a new command.When people use git status, it means that they need information to continue their work, so if you don't even know that you are in a rebase, you will very likely need information about the current rebase.

During a classic rebase we could have output like:

rebase in progress; onto d9d448a You are currently rebasing branch 'branche1' on 'd9d448a'. (fix conflicts and then run "git rebase --continue") (use "git rebase --skip" to skip this patch) (use "git rebase --abort" to check out the original branch) (5 commits applied, 3 remainings) Failed to apply:

252c273 commit message

Unmerged paths: (use "git reset HEAD <file>..." to unstage) (use "git add <file>..." to mark resolution)

both modified: file1
And during an interactive rebase:

rebase in progress; onto 247c883 You are currently editing a commit while rebasing branch 'b1.1' on '247c883'. (use "git commit --amend" to amend the current commit) (use "git rebase --continue" once you are satisfied with your changes)

Last commands done (5 commands done) :
pick 62609785 commit message1 reword 85ae9001 new commit message2
(See more at .git/rebase-merge/done)
Next commands to do (3 remainings commands) :
squash 62609785 commit message3 pick 85ae9001 commit message4
(See more at .git/rebase-merge/git-rebase-todo)

Changes not staged for commit: (use "git add <file>..." to update what will be committed) (use "git checkout -- <file>..." to discard changes in working directory)

modified: file1 ...

Is it a good practice to send the user find information in the .git directory?

Thanks
Guillaume
Previous: Junio C HamanoNext: Matthieu Moy
Message 8 of 10 in “create a skeleton for the command git rebase --status”
  1. create a skeleton for the command git rebase --statusGuillaume Pagès, May 28, 2015
  2. Matthieu MoyMay 28, 2015
  3. Guillaume PagesMay 28, 2015
  4. Matthieu MoyMay 28, 2015
  5. Junio C HamanoMay 28, 2015
  6. Matthieu MoyMay 28, 2015
  7. Junio C HamanoMay 28, 2015
  8. Guillaume PagesMay 29, 2015
  9. Matthieu MoyMay 29, 2015
  10. Junio C HamanoMay 29, 2015

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.