I do my development of various features in git branches. When I want to check my code into SVN via git-svn, I do the following:

```
git co feature_branch
git svn rebase
git co master
git svn rebase
git merge --no-ff feature_branch
git commit --amend
git svn dcommit

```

This works reasonably well, unless another developer commits to SVN any time during this process, in which case either:

* If a SVN commit is made between the time I rebase feature\_branch and master, I get a log that looks like the following:

```
*   4e6992a BUG-003 My SVN commit (containing cdb40ba and 3b18ea4)
|\
| * cdb40ba local commit 1
| * 3b18ea4 local commit 2
* | cf8a028 BUG-002 Another developer's SVN commit
|/
* 940c613 BUG-001 Another developer's SVN commit
```

* If a SVN commit is made between the time I rebase master and `svn dcommit`, the latter fails due to merge issues (in which case I do a hard reset and start over)

How can I accomplish this in a single atomic operation?