diff options
author | clarkzjw <[email protected]> | 2022-11-17 10:56:25 -0800 |
---|---|---|
committer | clarkzjw <[email protected]> | 2022-11-17 10:56:25 -0800 |
commit | d2d735742ca61b211c9b48a2209d36395daebcf4 (patch) | |
tree | bda27729a1bbac3ab354a1f10d4885899cdbf967 /dot_config/i3/scripts/executable_literal_empty_workspace | |
parent | a6d2e5e6fb9adc84c32e86630b4846b1765c7d77 (diff) | |
download | dotfiles-d2d735742ca61b211c9b48a2209d36395daebcf4.tar.gz |
+ add existing config
Diffstat (limited to 'dot_config/i3/scripts/executable_literal_empty_workspace')
-rw-r--r-- | dot_config/i3/scripts/executable_literal_empty_workspace | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/dot_config/i3/scripts/executable_literal_empty_workspace b/dot_config/i3/scripts/executable_literal_empty_workspace new file mode 100644 index 0000000..b962cde --- /dev/null +++ b/dot_config/i3/scripts/executable_literal_empty_workspace | |||
@@ -0,0 +1,10 @@ | |||
1 | #!/usr/bin/env bash | ||
2 | |||
3 | MAX_DESKTOPS=20 | ||
4 | |||
5 | WORKSPACES=$(seq -s '\n' 1 1 ${MAX_DESKTOPS}) | ||
6 | |||
7 | EMPTY_WORKSPACE=$( (i3-msg -t get_workspaces | tr ',' '\n' | grep num | awk -F: '{print int($2)}' ; \ | ||
8 | echo -e ${WORKSPACES} ) | sort -n | uniq -u | head -n 1) | ||
9 | |||
10 | i3-msg workspace ${EMPTY_WORKSPACE} | ||