mirror of
https://github.com/caelestia-dots/cli.git
synced 2026-06-05 23:09:27 -05:00
install: all subcommand
This commit is contained in:
@@ -22,7 +22,7 @@ complete -c caelestia -n $not_seen -a 'wallpaper' -d 'Change the wallpaper'
|
|||||||
complete -c caelestia -n $not_seen -a 'pip' -d 'Picture in picture utilities'
|
complete -c caelestia -n $not_seen -a 'pip' -d 'Picture in picture utilities'
|
||||||
|
|
||||||
# Install
|
# Install
|
||||||
set -l commands discord foot fuzzel hypr safeeyes scripts shell gtk vscode
|
set -l commands all discord foot fuzzel hypr safeeyes scripts shell gtk vscode
|
||||||
complete -c caelestia -n "$seen install && not $seen $commands" -a "$commands"
|
complete -c caelestia -n "$seen install && not $seen $commands" -a "$commands"
|
||||||
|
|
||||||
# Shell
|
# Shell
|
||||||
|
|||||||
@@ -45,7 +45,13 @@ end
|
|||||||
|
|
||||||
if test "$argv[1]" = install
|
if test "$argv[1]" = install
|
||||||
set -l valid_modules discord foot fuzzel hypr safeeyes scripts shell gtk vscode
|
set -l valid_modules discord foot fuzzel hypr safeeyes scripts shell gtk vscode
|
||||||
contains -- "$argv[2]" $valid_modules && $src/install/$argv[2].fish $argv[3..] || error "Invalid module: $argv[2]"
|
if test "$argv[2]" = all
|
||||||
|
for module in $valid_modules
|
||||||
|
$src/install/$module.fish $argv[3..]
|
||||||
|
end
|
||||||
|
else
|
||||||
|
contains -- "$argv[2]" $valid_modules && $src/install/$argv[2].fish $argv[3..] || error "Invalid module: $argv[2]"
|
||||||
|
end
|
||||||
exit
|
exit
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user