Merge branch 'pk/rebase-in-c-2-basic'
authorJunio C Hamano <gitster@pobox.com>
Fri, 2 Nov 2018 02:04:53 +0000 (11:04 +0900)
committerJunio C Hamano <gitster@pobox.com>
Fri, 2 Nov 2018 02:04:53 +0000 (11:04 +0900)
Rewrite "git rebase" in C.

* pk/rebase-in-c-2-basic:
builtin rebase: support `git rebase <upstream> <switch-to>`
builtin rebase: only store fully-qualified refs in `options.head_name`
builtin rebase: start a new rebase only if none is in progress
builtin rebase: support --force-rebase
builtin rebase: try to fast forward when possible
builtin rebase: require a clean worktree
builtin rebase: support the `verbose` and `diffstat` options
builtin rebase: support --quiet
builtin rebase: handle the pre-rebase hook and --no-verify
builtin rebase: support `git rebase --onto A...B`
builtin rebase: support --onto

1  2 
builtin/rebase.c
index e695d8a430f155b46f79c906474ca7b8f5645ec7,e817956d96fe50bce975a1c87fd8f8df132e53ea..71367c8530e77035fe89ddfee8fcef0d77eaced0
  #include "cache-tree.h"
  #include "unpack-trees.h"
  #include "lockfile.h"
+ #include "parse-options.h"
+ #include "commit.h"
+ #include "diff.h"
+ #include "wt-status.h"
+ #include "revision.h"
++#include "commit-reach.h"
+ static char const * const builtin_rebase_usage[] = {
+       N_("git rebase [-i] [options] [--exec <cmd>] [--onto <newbase>] "
+               "[<upstream>] [<branch>]"),
+       N_("git rebase [-i] [options] [--exec <cmd>] [--onto <newbase>] "
+               "--root [<branch>]"),
+       N_("git rebase --continue | --abort | --skip | --edit-todo"),
+       NULL
+ };
  
  static GIT_PATH_FUNC(apply_dir, "rebase-apply")
  static GIT_PATH_FUNC(merge_dir, "rebase-merge")