[Keeping things up to date][no-merge-policy].
If your reviewer requests changes, the procedure for those changes looks much
the same, with some steps skipped:
1. Ensure that you're making changes to the most recent version of your code:
`git checkout issue-12345-fix`.
2. Make, stage, and commit your additional changes just like before.
3. Push those changes to your fork: `git push`.
## Troubleshooting git issues
You don't need to clone `rust-lang/rust` from scratch if it's out of date!
Even if you think you've messed it up beyond repair, there are ways to fix
the git state that don't require downloading the whole repository again.
Here are some common issues you might run into:
### I made a merge commit by accident.
Git has two ways to update your branch with the newest changes: merging and rebasing.
Rust [uses rebasing][no-merge-policy]. If you make a merge commit, it's not too hard to fix:
`git rebase -i upstream/master`.
See [Rebasing](#rebasing) for more about rebasing.
### I deleted my fork on GitHub!
This is not a problem from git's perspective. If you run `git remote -v`,
it will say something like this:
```console
$ git remote -v
origin git@github.com:jyn514/rust.git (fetch)
origin git@github.com:jyn514/rust.git (push)
upstream https://github.com/rust-lang/rust (fetch)
upstream https://github.com/rust-lang/rust (fetch)
```
If you renamed your fork, you can change the URL like this:
```console
git remote set-url origin <URL>
```
where the `<URL>` is your new fork.
### I changed a submodule by accident
Usually people notice this when rustbot posts a comment on github that `cargo` has been modified:
You might also notice conflicts in the web UI: