From: Finn Arne Gangstad Date: Mon, 16 Mar 2009 15:42:50 GMT Subject: [PATCH v3 0/2] New config variable push.default Message-ID: <1237218172-16565-1-git-send-email-finnag@pvv.org> Add a new configuration variable push.default that decides what action to take if you do not give "git push" any refspecs, and no refspecs are implied by options (--all or --mirror), and no refspecs are configured for the current remote. Some minor rewording of error messages since last time, and split the patch into two. Patch 1 introduces the variable with all functionality, and patch 2 adds a warning if the default behavior is trigged and push.default has not been configured. Possible configuration values are: - nothing: Do not push anything. - tracking: Push the current branch to the branch it is tracking. In this mode, push will always push to the same branch that pull would pull from. This functionality does not exist today. - current: Push the current branch to a branch of the same name on the current remote, create it if it does not exist. Identical to "git push HEAD", but you do not have to explicitly give the remote. - matching: The current behavior, push every branch to the current remote if a branch with the same name already exists there. Finn Arne Gangstad (2): New config push.default to decide default behavior for push Display warning for default git push with no push.default config Documentation/RelNotes-1.6.3.txt | 7 +++ Documentation/config.txt | 18 +++++++++ builtin-push.c | 76 +++++++++++++++++++++++++++++++++++-- cache.h | 9 ++++ config.c | 28 ++++++++++++++ environment.c | 1 + 6 files changed, 134 insertions(+), 5 deletions(-)