[PATCH 1/2] pull: respect rebase.autostash

2013-06-14 Thread Ramkumar Ramachandra
If a rebasing pull is requested, pull unconditionally runs require_clean_worktree() resulting in: # dirty worktree or index $ git pull Cannot pull with rebase: Your index contains uncommitted changes. Please commit or stash them. It does this to inform the user early on that a rebase

Re: [PATCH 1/2] pull: respect rebase.autostash

2013-06-14 Thread Matthieu Moy
Ramkumar Ramachandra artag...@gmail.com writes: --- a/git-pull.sh +++ b/git-pull.sh @@ -44,6 +44,7 @@ merge_args= edit= curr_branch=$(git symbolic-ref -q HEAD) curr_branch_short=${curr_branch#refs/heads/} rebase=$(git config --bool branch.$curr_branch_short.rebase) +autostash=$(git

Re: [PATCH 1/2] pull: respect rebase.autostash

2013-06-14 Thread Ramkumar Ramachandra
Matthieu Moy wrote: It would be nice to have an --autostash command-line option too, I thought it would be a bit ugly, since it's already overloaded with options to pass to merge. and the error message in require_clean_work_tree could suggest using it. That would make the feature easily

Re: [PATCH 1/2] pull: respect rebase.autostash

2013-06-14 Thread Phil Hord
On Fri, Jun 14, 2013 at 6:41 AM, Ramkumar Ramachandra artag...@gmail.com wrote: Matthieu Moy wrote: It would be nice to have an --autostash command-line option too, I thought it would be a bit ugly, since it's already overloaded with options to pass to merge. Eventually I think a switch will

Re: [PATCH 1/2] pull: respect rebase.autostash

2013-06-14 Thread Phil Hord
On Fri, Jun 14, 2013 at 4:56 AM, Ramkumar Ramachandra artag...@gmail.com wrote: If a rebasing pull is requested, pull unconditionally runs require_clean_worktree() resulting in: # dirty worktree or index $ git pull Cannot pull with rebase: Your index contains uncommitted changes.

Re: [PATCH 1/2] pull: respect rebase.autostash

2013-06-14 Thread Phil Hord
On Fri, Jun 14, 2013 at 8:12 AM, Phil Hord phil.h...@gmail.com wrote: On Fri, Jun 14, 2013 at 4:56 AM, Ramkumar Ramachandra artag...@gmail.com wrote: If a rebasing pull is requested, pull unconditionally runs require_clean_worktree() resulting in: # dirty worktree or index $ git pull

Re: [PATCH 1/2] pull: respect rebase.autostash

2013-06-14 Thread Junio C Hamano
Matthieu Moy matthieu@grenoble-inp.fr writes: Ramkumar Ramachandra artag...@gmail.com writes: --- a/git-pull.sh +++ b/git-pull.sh @@ -44,6 +44,7 @@ merge_args= edit= curr_branch=$(git symbolic-ref -q HEAD) curr_branch_short=${curr_branch#refs/heads/} rebase=$(git config --bool