diff options
| author | 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> | 2025-01-17 23:58:03 +1100 |
|---|---|---|
| committer | 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> | 2025-01-17 23:58:03 +1100 |
| commit | cac1e1545defeb0e661e7c4fdf3fd7c35743a1a7 (patch) | |
| tree | c35cec3551d1f2228cc4a265bdae5546c9a6da1b /main.fish | |
| parent | clipboard and emoji scripts (diff) | |
| download | caelestia-cli-cac1e1545defeb0e661e7c4fdf3fd7c35743a1a7.tar.gz caelestia-cli-cac1e1545defeb0e661e7c4fdf3fd7c35743a1a7.tar.bz2 caelestia-cli-cac1e1545defeb0e661e7c4fdf3fd7c35743a1a7.zip | |
shell: start shell if no args
Also pip daemon log started
Diffstat (limited to 'main.fish')
| -rwxr-xr-x | main.fish | 14 |
1 files changed, 8 insertions, 6 deletions
@@ -5,15 +5,17 @@ cd (dirname (realpath (status filename))) || exit . ./util.fish if test "$argv[1]" = shell - if contains 'caelestia' (astal -l) - if test -n "$argv[2..]" + # Start shell if no args + if test -z "$argv[2..]" + set -q CAELESTIA_SHELL_DIR && set shell_dir $CAELESTIA_SHELL_DIR || set shell_dir ~/.config/caelestia/shell + $shell_dir/run.fish + else + if contains 'caelestia' (astal -l) log "Sent command '$argv[2..]' to shell" astal -i caelestia $argv[2..] else - warn 'No args given, ignoring' + warn 'Shell unavailable' end - else - warn 'Shell unavailable' end exit end @@ -45,7 +47,7 @@ echo echo 'COMMAND := help | shell | workspace-action | change-wallpaper' echo echo ' help: show this help message' -echo ' shell: send a message to the shell' +echo ' shell: start the shell or message it' echo ' screenshot: take a screenshot' echo ' workspace-action: execute a Hyprland workspace dispatcher in the current group' echo ' change-wallpaper: change the wallpaper' |