summaryrefslogtreecommitdiffstats
path: root/.scripts
diff options
context:
space:
mode:
authorGergely Horváth <horvath@gergely.xyz>2019-01-03 19:51:38 +0100
committerGergely Horváth <horvath@gergely.xyz>2019-01-03 19:51:38 +0100
commitbcdfd2e2c41a6d1f048276cfe8447735a1b9e2aa (patch)
treef87c1c8ce985e7bcb2b76d57e1931242b7c450c0 /.scripts
parentebdff2ce6aafc95e51986447b1add7389f7a3a3a (diff)
downloadeibhear-bcdfd2e2c41a6d1f048276cfe8447735a1b9e2aa.tar.gz
eibhear-bcdfd2e2c41a6d1f048276cfe8447735a1b9e2aa.tar.zst
eibhear-bcdfd2e2c41a6d1f048276cfe8447735a1b9e2aa.zip
Simplified ddspawn, no need for pause
Diffstat (limited to '.scripts')
-rwxr-xr-x.scripts/i3cmds/ddspawn7
1 files changed, 3 insertions, 4 deletions
diff --git a/.scripts/i3cmds/ddspawn b/.scripts/i3cmds/ddspawn
index 0871a59..123cecb 100755
--- a/.scripts/i3cmds/ddspawn
+++ b/.scripts/i3cmds/ddspawn
@@ -6,7 +6,7 @@
# argument 1: script to run in dropdown window
# all other args are interpreted as options for your terminal
# My usage:
-# ddpawn
+# ddspawn
# bindsym $mod+u exec --no-startup-id ddspawn tmuxdd
# Will hide/show window running the `tmuxdd` script when I press mod+u in i3
# bindsym $mod+a exec --no-startup-id ddspawn dropdowncalc -f mono:pixelsize=24
@@ -17,9 +17,8 @@
if xwininfo -tree -root | grep "(\"$1\" ";
then
echo "Window detected."
+ i3 "[instance=\"$1\"] scratchpad show; [instance=\"$1\"] move position center"
else
echo "Window not detected... spawning."
- i3 "exec --no-startup-id $TERMINAL -n $1 $(echo "$@" | cut -d ' ' -f2-) -e $1" && i3 "[instance=\"$1\"] scratchpad show; [instance=\"$1\"] move position center"
- sleep .25 # This sleep is my laziness, will fix later (needed for immediate appearance after spawn).
+ i3 "exec --no-startup-id $1"
fi
-i3 "[instance=\"$1\"] scratchpad show; [instance=\"$1\"] move position center"