diff options
Diffstat (limited to 'builtin/pull.c')
-rw-r--r-- | builtin/pull.c | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/builtin/pull.c b/builtin/pull.c index 1ab4de0005..0c7bac97b7 100644 --- a/builtin/pull.c +++ b/builtin/pull.c @@ -7,8 +7,12 @@ */ #define USE_THE_INDEX_VARIABLE #include "cache.h" +#include "advice.h" #include "config.h" #include "builtin.h" +#include "gettext.h" +#include "hex.h" +#include "object-name.h" #include "parse-options.h" #include "exec-cmd.h" #include "run-command.h" @@ -359,8 +363,6 @@ static enum rebase_type config_get_rebase(int *rebase_unspecified) */ static int git_pull_config(const char *var, const char *value, void *cb) { - int status; - if (!strcmp(var, "rebase.autostash")) { config_autostash = git_config_bool(var, value); return 0; @@ -372,10 +374,6 @@ static int git_pull_config(const char *var, const char *value, void *cb) check_trust_level = 0; } - status = git_gpg_config(var, value, cb); - if (status) - return status; - return git_default_config(var, value, cb); } @@ -1036,7 +1034,7 @@ int cmd_pull(int argc, const char **argv, const char *prefix) if (file_exists(git_path_merge_head(the_repository))) die_conclude_merge(); - if (get_oid("HEAD", &orig_head)) + if (repo_get_oid(the_repository, "HEAD", &orig_head)) oidclr(&orig_head); if (opt_rebase) { @@ -1049,7 +1047,7 @@ int cmd_pull(int argc, const char **argv, const char *prefix) if (!opt_autostash) require_clean_work_tree(the_repository, N_("pull with rebase"), - _("please commit or stash them."), 1, 0); + _("Please commit or stash them."), 1, 0); if (get_rebase_fork_point(&rebase_fork_point, repo, *refspecs)) oidclr(&rebase_fork_point); @@ -1061,7 +1059,7 @@ int cmd_pull(int argc, const char **argv, const char *prefix) if (opt_dry_run) return 0; - if (get_oid("HEAD", &curr_head)) + if (repo_get_oid(the_repository, "HEAD", &curr_head)) oidclr(&curr_head); if (!is_null_oid(&orig_head) && !is_null_oid(&curr_head) && |