updates sessions to include params, adds web param

This commit is contained in:
2024-08-10 16:11:49 -07:00
parent 811bcb67c2
commit 3363bf5f49
3 changed files with 12 additions and 2 deletions

3
sesh
View File

@@ -5,6 +5,7 @@ directory=~/linux-setup/sessions
alias wezterm='flatpak run org.wezfurlong.wezterm'
usage() {
echo "Sesh v0.2"
echo "Usage: $0 [-t] <session>"
echo " -t: Add <session>"
exit 1
@@ -23,7 +24,7 @@ if [ "$1" == "-t" ]; then
fi
flatpak run org.wezfurlong.wezterm start $directory/$2.sh
else
exec "$directory/$1.sh"
exec "$directory/$1.sh" "${@:2}"
fi
# Check if no parameter is provided

View File

@@ -25,3 +25,8 @@ pane=$(flatpak run org.wezfurlong.wezterm cli split-pane --left --pane-id $pane)
echo "cd ~/repos/syncopotamus-svelte" | flatpak run org.wezfurlong.wezterm cli send-text --no-paste --pane-id $pane
echo "nvim" | flatpak run org.wezfurlong.wezterm cli send-text --no-paste --pane-id $pane
flatpak run org.wezfurlong.wezterm cli adjust-pane-size --amount 50 --pane-id $pane right
if [ "$1" == "web" ]; then
firefox https://3.basecamp.com/5456546/buckets/34127086/card_tables/6496384013
firefox --new-window http://localhost:5173/user/noisycarlos/dashboard
fi

View File

@@ -1,4 +1,3 @@
# alias wezterm='flatpak run org.wezfurlong.wezterm'
PANE=$(flatpak run org.wezfurlong.wezterm cli list | grep syncopotamus | head -n 1 | awk '{print $3}')
if [ -n "${PANE}" ]; then
@@ -18,3 +17,8 @@ PANE=$(flatpak run org.wezfurlong.wezterm cli split-pane --left --pane-id $PANE)
echo "cd ~/repos/syncopotamus-rails" | flatpak run org.wezfurlong.wezterm cli send-text --no-paste --pane-id $PANE
echo "nvim" | flatpak run org.wezfurlong.wezterm cli send-text --no-paste --pane-id $PANE
flatpak run org.wezfurlong.wezterm cli adjust-pane-size --amount 50 --pane-id $PANE right
if [ "$1" == "web" ]; then
firefox https://3.basecamp.com/5456546/buckets/34127086/card_tables/6496384013
firefox --new-window http://localhost:4000
fi