Skip to content

Instantly share code, notes, and snippets.

@conspirator
Created August 1, 2012 14:15
Show Gist options
  • Save conspirator/3227197 to your computer and use it in GitHub Desktop.
Save conspirator/3227197 to your computer and use it in GitHub Desktop.
Selenium Slam: A shell script to quickly push branches with incremental naming
#!/bin/bash
# ## git-ss
#
# Author: Christopher Webb <[email protected]>
# Website: http://conspirator.co
# License: http://www.opensource.org/licenses/MIT
#
# A shell script to quickly push branches with incremental naming
#
# Place this script somewhere in your PATH and make it executable
# This script can then be ran within any git repository by calling
# `git ss $BRANCH_NAME` within the repository
#
# Example usage:
#
# $ cd path/to/my/git/repo
# $ git ss rebase/master/refactor
#
# Output:
#
# git push origin HEAD:rebase/master/refactor1
# git push origin HEAD:rebase/master/refactor2
# git push origin HEAD:rebase/master/refactor3
#
for i in {1..3}; do git push origin HEAD:$1$i; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment