From: Patrick Ohly <patrick.ohly@intel.com>
To: git@vger.kernel.org
Subject: git rebase --whitespace
Date: Tue, 11 Nov 2008 15:12:50 +0100 [thread overview]
Message-ID: <1226412770.17450.839.camel@ecld0pohly> (raw)
[-- Attachment #1: Type: text/plain, Size: 986 bytes --]
Hello!
I tried to use "git --rebase --whitespace=..." and noticed some
oddities. Git 1.6.0.4.
* --whitespace is not supported when using --interactive. Should
be mentioned in the docs.
* Without --interactive, rebase will bail out early if the current
branch is up-to-date. I was trying to use --whitespace=fix to
clean up my patches and had to patch git-rebase (see attached),
otherwise it didn't let me do that.
* The documentation mentions --whitespace=check, but "check" is
not a valid option.
I don't have time to fix the documentation, but I thought I should at
least mention the issues and send the patch your way in case someone
finds it useful.
--
Best Regards, Patrick Ohly
The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.
[-- Attachment #2: git-rebase-whitespace.patch --]
[-- Type: text/x-patch, Size: 496 bytes --]
--- git-1.6.0.4/git-rebase.sh 2008-11-09 07:53:38.000000000 +0100
+++ git-1.6.0.4/git-rebase.sh.patched 2008-11-11 15:10:27.000000000 +0100
@@ -375,6 +375,7 @@
# but this should be done only when upstream and onto are the same.
mb=$(git merge-base "$onto" "$branch")
if test "$upstream" = "$onto" && test "$mb" = "$onto" &&
+ ! (echo $git_am_opt | grep -e --whitespace ) > /dev/null &&
# linear history?
! (git rev-list --parents "$onto".."$branch" | grep " .* ") > /dev/null
then
reply other threads:[~2008-11-11 14:14 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1226412770.17450.839.camel@ecld0pohly \
--to=patrick.ohly@intel.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox