Sha256: b316cb31db5408351b218b841f7fb3b091ffff040f19b716be9bf363460e4ea2

Contents?: true

Size: 389 Bytes

Versions: 38

Compression:

Stored size: 389 Bytes

Contents

#!/usr/bin/env ruby

branch = ARGV[0] or raise "Need the branch name as first argument"

`git status`.include?('working directory clean') or raise 'Dirty working directory. Nothing was pushed.'
`git checkout #{branch}`
`git push origin #{branch}`
`git config branch.#{branch}.remote origin`
`git config branch.#{branch}.merge #{branch}`

puts "#{branch} is now tracking origin/#{branch}"

Version data entries

38 entries across 38 versions & 1 rubygems

Version Path
geordi-0.9.12 bin/remotify-local-branch
geordi-0.9.11 bin/remotify-local-branch
geordi-0.9.10 bin/remotify-local-branch
geordi-0.9.9 bin/remotify-local-branch
geordi-0.9.8 bin/remotify-local-branch
geordi-0.9.7 bin/remotify-local-branch
geordi-0.9.6 bin/remotify-local-branch
geordi-0.9.5 bin/remotify-local-branch
geordi-0.9.4 bin/remotify-local-branch
geordi-0.9.3 bin/remotify-local-branch
geordi-0.9.2 bin/remotify-local-branch
geordi-0.9.1 bin/remotify-local-branch
geordi-0.9.0 bin/remotify-local-branch
geordi-0.8.1 bin/remotify-local-branch
geordi-0.8.0 bin/remotify-local-branch
geordi-0.7.0 bin/remotify-local-branch
geordi-0.6.1 bin/remotify-local-branch
geordi-0.6.0 bin/remotify-local-branch
geordi-0.5.0 bin/remotify-local-branch
geordi-0.4.6 bin/remotify-local-branch