Hello
I'm using SourceTree and I forgot to add a file to a previous commit - about 3 or 4 commits ago. How can I inlude this file in the desired commit?
Hi Jesse,
You can use rebase to do this.
Thanks for the reply Jeff. I should've specified this is a Windows install. I do not see Select Rebase children in the context menu. I can share a screen shot it you'd like.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It looks like the Windows version does not support interactive rebasing (https://jira.atlassian.com/browse/SRCTREEWIN-405) yet. I don't know of another way to do this in SourceTree, but maybe someone else will.
You could also try to rebase with the command line - http://stackoverflow.com/a/2719636/1133218
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Just a note to say that SourceTree for Windows does now support rebasing children interactively (I am using 1.6.10), so the above method now works.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Looks like you can do it, at least in version 1.6.18.0 on Windows: Stage (add) your changes, as if you were going to perform a new commit. Then under "File Status" put your cursor into the Commit message box to open up the full commit pane. Top right choose from "commit options..." and select "Amend latest commit". You then get to copy the message from the previous commit into the message box, edit it if you want and commit. It performs a `git commit --amend` for you and voila - the previous commit is amended. Loverly.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks I can confirm this (also) works great in v1.8.3 on Windows
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.