Skip to content

Instantly share code, notes, and snippets.

@heypoom
Created April 19, 2018 18:57
Show Gist options
  • Save heypoom/1c8ac6275154003aa01da7a19c50a23e to your computer and use it in GitHub Desktop.
Save heypoom/1c8ac6275154003aa01da7a19c50a23e to your computer and use it in GitHub Desktop.
# --- Workspace Management Commands ---
# ws: Manage Workspaces
ws() {
make -C "$HOME/Workspaces/$1" $2
}
# wg: Go to Workspace
wg() {
cd "$HOME/Workspaces/$1" || return
}
# wsh: Shell into the Workspace
wsh() {
docker exec -it "$1" bash
}
# wr: Run the Workspace
wr() {
(wg $1 && docker-compose up -d)
}
# wk: Kill the Workspace
wk() {
(wg $1 && docker-compose down)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment