mirror of
https://github.com/robbyrussell/oh-my-zsh.git
synced 2026-12-01 04:43:04 +01:00
feat(cli): make shellsaver the public command
This commit is contained in:
1 parent
035556d687
commit
b4e1e1083f
3 files changed
+26
-29
No files matched your search
+8
-9
@@ -28,8 +28,7 @@ function _omz {
|
||||
'plugin:Manage plugins'
|
||||
'pr:Manage Oh My Zsh Pull Requests'
|
||||
'reload:Reload the current zsh session'
|
||||
'screensaver:Launch a whimsical terminal screensaver'
|
||||
'shellsaver:Alias for screensaver'
|
||||
'shellsaver:Launch a whimsical terminal screensaver'
|
||||
'shop:Open the Oh My Zsh shop'
|
||||
'theme:Manage themes'
|
||||
'update:Update Oh My Zsh'
|
||||
@@ -38,12 +37,12 @@ function _omz {
|
||||
|
||||
if [[ "$words[2]" == (screensaver|shellsaver) ]] && (( CURRENT > 2 )); then
|
||||
_arguments \
|
||||
'1:command:(screensaver shellsaver)' \
|
||||
'1:command:' \
|
||||
'2::scene:(aquarium logo hermit party)' \
|
||||
'--mono[Use the default foreground color]' \
|
||||
'--seconds[Exit after a number of seconds]:seconds:' \
|
||||
'--snapshot[Print a plain-text still]::frame:' \
|
||||
'--help[Show screensaver help]'
|
||||
'--help[Show Shellsaver help]'
|
||||
return
|
||||
fi
|
||||
|
||||
@@ -187,8 +186,7 @@ Available commands:
|
||||
plugin <command> Manage plugins
|
||||
pr <command> Manage Oh My Zsh Pull Requests
|
||||
reload Reload the current zsh session
|
||||
screensaver [scene] Launch a screensaver (aquarium by default)
|
||||
shellsaver [scene] Alias for screensaver
|
||||
shellsaver [scene] Launch a Shellsaver (aquarium by default)
|
||||
shop Open the Oh My Zsh shop
|
||||
theme <command> Manage themes
|
||||
update Update Oh My Zsh
|
||||
@@ -197,12 +195,13 @@ Available commands:
|
||||
EOF
|
||||
}
|
||||
|
||||
function _omz::screensaver {
|
||||
function _omz::shellsaver {
|
||||
command zsh -f "$ZSH/tools/screensaver.zsh" "$@"
|
||||
}
|
||||
|
||||
function _omz::shellsaver {
|
||||
_omz::screensaver "$@"
|
||||
# Hidden alias; only shellsaver is advertised in help and command completion.
|
||||
function _omz::screensaver {
|
||||
_omz::shellsaver "$@"
|
||||
}
|
||||
|
||||
function _omz::changelog {
|
||||
|
||||
Reference in new issue
Block a user