True, the git rebase hasn't got a dry run but you can undo it if it didn't please you:

git reflog

be9dd19 HEAD@{0}: commit: added test2.txt
b182b7f HEAD@{1}: rebase finished: returning to refs/heads/master
b182b7f HEAD@{2}: pull --rebase: CREATED myFile1.txt
db46d91 HEAD@{3}: checkout: moving from master to db46d91ad5fcce68696de5d6eb66cf8ffff2f935^0
2c5f71c HEAD@{4}: commit: CREATED myFile1.txt
9d119a0 HEAD@{5}: rebase finished: returning to refs/heads/master
9d119a0 HEAD@{6}: pull --rebase: Added myFile.txt
af5e47b HEAD@{7}: checkout: moving from master to af5e47bfd2ec488d5f6ca70b54a58ee2505d1cc0^0
4865f0a HEAD@{8}: commit: Added myFile.txt

git reset --hard HEAD@{3} // to return before your rebase / pull --rebase

-Fred

-----Message d'origine----- From: Justin Mclean
Sent: Thursday, March 21, 2013 9:23 AM
To: dev@flex.apache.org
Subject: Re: [OT] Log history

Hi,

Ok, I should have say "in this case, use 'git rebase -p origin/develop' to preserve your 'merged branch commit' from being rewriten/flattened, then you can push.", I guess that's more english.

How do I know what this is going to do? git pull has a "--dry-run" option but it seems get rebase doesn't have a "--dry-run" option.

Justin

Reply via email to