diff options
author | Xiao Pan <xyz@flylightning.xyz> | 2024-07-22 21:32:48 -0700 |
---|---|---|
committer | Xiao Pan <xyz@flylightning.xyz> | 2024-07-22 21:32:48 -0700 |
commit | 8426b555f5756bca6e0bfb48969856a9967c7e08 (patch) | |
tree | e30c38bf4c9e23dd75848d14c1325e18319262b5 | |
parent | 191896d48a562e28b9004efe636755b12fff3398 (diff) |
sb: ssh to cfg branches servers to execute specified commands
-rwxr-xr-x | sh/sb | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -0,0 +1,7 @@ +#!/bin/sh +# Ssh Branches + +for branch in $(git -C "$HOME/programs/config_local_arch" branch | awk '!/master/{print ($1=="*")?$2:$1}'); do + echo "sshing to server $branch..." + ssh -t "$branch" '. "$HOME/.profile";' "$@" +done |