Skip to content

Instantly share code, notes, and snippets.

@jahirvidrio
Last active March 20, 2026 22:30
Show Gist options
  • Select an option

  • Save jahirvidrio/02a23ae2594806e862ea4e9bde321371 to your computer and use it in GitHub Desktop.

Select an option

Save jahirvidrio/02a23ae2594806e862ea4e9bde321371 to your computer and use it in GitHub Desktop.
Git SVN: How to

Git SVN: How to

Create new branch from existing

# Get latest repository changes
$ git svn fetch
$ git svn rebase

# Get remote branches
$ git --no-pager branch --remotes
origin/feature
origin/trunk

# Create new branch
$ git checkout -b feature origin/feature

Delete old and origin brances

# Get latest repository changes
$ git svn rebase
$ git svn fetch

# Get remote branches
$ git --no-pager branch --remotes
origin/feature
origin/old-feature
origin/trunk

# Delete old branch
$ git branch --remotes --delete origin/old-feature
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment