Is there a way to run a command on a different git branch? -


i have large rails project several feature branches active @ 1 time. have long running task (rebuild db, run tests).

i able run test task on 1 feature branch while changing code on another. there way run particular command on branch, have branch active in terminal?

some git commands can operate on reference, doesn't have branch checked out working copy:

git log <branch> git diff <branch-one> <branch-two> 

other git commands operate on branch have checked out in working copy:

git reset --hard head@{1} 

if tests depend on there being branch checked out working copy, far know, can't have more 1 branch checked out working copy, can have 1 working copy.

as alternative, possibly clone local repo again second working copy way:

git clone <path local repo> second-repo 

Comments

Popular posts from this blog

plot - Remove Objects from Legend When You Have Also Used Fit, Matlab -

java - Why does my date parsing return a weird date? -

Need help in packaging app using TideSDK on Windows -