Skip to content

Convert git-rebase.sh to C

Nguyễn Thái Ngọc Duy git 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest8 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/8strbuf: add and use strbuf_read_file_or_die()builtin/blame.c builtin/commit.c builtin/merge.c +4 more+21 -220 replies
2/8Move reset_tree from builtin/checkout.c to unpack-trees.cbuiltin/checkout.c builtin/merge.c unpack-trees.c +1 more+47 -590 replies
3/8rebase: turn rebase--am into a separate programMakefile git-rebase--am.sh git-rebase.sh+45 -20 replies
4/8rebase: turn rebase--merge into a separate programMakefile git-rebase--merge.sh git-rebase.sh+37 -10 replies
5/8rebase: turn rebase--interactive into a separate programMakefile git-rebase--interactive.sh git-rebase.sh+38 -90 replies
6/8rebase: remove unused functiongit-rebase.sh+0 -130 replies
7/8rebase: move resolvemsg to rebase--* scriptsgit-rebase--am.sh git-rebase--interactive.sh git-rebase--merge.sh +1 more+16 -60 replies
8/8Build in rebaseMakefile builtin.h builtin/rebase.c +5 more+1291 -5370 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH/WIP 0/8] Convert git-rebase.sh to C

In the spirit of sharing code proactively [1], despite my embarrassment, this is what I got for converting git-rebase.sh to C. Note that this is only about git-rebase.sh, not git-rebase--*.sh. Some changes in git-rebase.sh are pushed back to git-rebase--*.sh. The idea is we convert git-rebase.sh first, then the rest later.

Anybody who wants to base their work on this code, feel free to --reset-author (and take all the bugs with you, I'm sure there are lots of them). This work is from 2013. git-rebase.sh has received lots of updates since then, so there's still lots of work to do.

[1] http://article.gmane.org/gmane.comp.version-control.git/265699

Nguyễn Thái Ngọc Duy (8):
strbuf: add and use strbuf_read_file_or_die() Move reset_tree from builtin/checkout.c to unpack-trees.c
rebase: turn rebase--am into a separate program
rebase: turn rebase--merge into a separate program
rebase: turn rebase--interactive into a separate program
rebase: remove unused function
rebase: move resolvemsg to rebase--* scripts Build in rebase

 Makefile                                |   8 +-
 builtin.h                               |   1 +
 builtin/blame.c                         |   4 +-
 builtin/checkout.c                      |  40 +-
 builtin/commit.c                        |  16 +-
 builtin/merge.c                         |  32 +-
 builtin/notes.c                         |   4 +-
 builtin/rebase.c (new)                  | 752 ++++++++++++++++++++++++++++++++
 builtin/tag.c                           |   7 +-
 commit.c                                |   4 +-
 commit.h                                |   4 +-
 contrib/examples/git-rebase.sh (new +x) | 532 ++++++++++++++++++++++
 git-rebase--am.sh (mode +x)             |  39 ++
 git-rebase--interactive.sh (mode +x)    |  41 +-
 git-rebase--merge.sh (mode +x)          |  39 ++
 git-rebase.sh (gone)                    | 544 -----------------------
 git.c                                   |   1 +
 strbuf.c                                |   8 +
 strbuf.h                                |   1 +
 unpack-trees.c                          |  33 ++
 unpack-trees.h                          |   4 +
 21 files changed, 1480 insertions(+), 634 deletions(-)
 create mode 100644 builtin/rebase.c
 create mode 100755 contrib/examples/git-rebase.sh
 mode change 100644 => 100755 git-rebase--am.sh
 mode change 100644 => 100755 git-rebase--interactive.sh
 mode change 100644 => 100755 git-rebase--merge.sh
 delete mode 100755 git-rebase.sh
Signature · 1 line
2.3.0.rc1.137.g477eb31