mirror of
https://github.com/namibia/tips.git
synced 2024-11-13 08:46:29 +00:00
Add a tip for automatically stashing changes before a rebase
Signed-off-by: Eric James Michael Ritz <ejmr@plutono.com>
This commit is contained in:
parent
1646af51e3
commit
c46f049974
@ -64,6 +64,7 @@
|
||||
* [Import from a bundle](https://github.com/git-tips/tips#import-from-a-bundle)
|
||||
* [Get the name of current branch.](https://github.com/git-tips/tips#get-the-name-of-current-branch)
|
||||
* [Ignore one file on commit (e.g. Changelog).](https://github.com/git-tips/tips#ignore-one-file-on-commit-eg-changelog)
|
||||
* [Stash changes before rebasing](https://github.com/git-tips/tips#stash-changes-before-rebasing)
|
||||
|
||||
<!-- Don’t remove or change the comment below – that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
|
||||
<!-- @doxie.inject end toc -->
|
||||
@ -449,5 +450,10 @@ git rev-parse --abbrev-ref HEAD
|
||||
git update-index --assume-unchanged Changelog; git commit -a; git update-index --no-assume-unchanged Changelog
|
||||
```
|
||||
|
||||
## Stash changes before rebasing
|
||||
```sh
|
||||
git rebase --autostash
|
||||
```
|
||||
|
||||
<!-- Don’t remove or change the comment below – that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
|
||||
<!-- @doxie.inject end -->
|
||||
|
@ -255,5 +255,9 @@
|
||||
{
|
||||
"title": "Ignore one file on commit (e.g. Changelog).",
|
||||
"tip": "git update-index --assume-unchanged Changelog; git commit -a; git update-index --no-assume-unchanged Changelog"
|
||||
},
|
||||
{
|
||||
"title": "Stash changes before rebasing",
|
||||
"tip": "git rebase --autostash"
|
||||
}
|
||||
]
|
||||
|
Loading…
Reference in New Issue
Block a user