Improve styler documentation

Replaced `list templates` with correct command `list packages` in styler
command line help printout.
This commit is contained in:
Marty Oehme 2020-02-16 14:28:28 +01:00
parent 3dac8e5034
commit 9919c68975
No known key found for this signature in database
GPG key ID: 0CCB0526EFB9611A

View file

@ -55,7 +55,7 @@ usage() {
" set [theme] Set the theme. Use any valid base16 theme name (without base16- prefix)." \ " set [theme] Set the theme. Use any valid base16 theme name (without base16- prefix)." \
" Same as 'theme' option, but changes will be made permanent." \ " Same as 'theme' option, but changes will be made permanent." \
"" \ "" \
" list [processors|template|themes] Print out all currently installed processors, templates, or themes from selection. " \ " list [processors|packages|themes] Print out all currently installed processors, templates, or themes from selection. " \
"" \ "" \
" download [username/repository] Download a base16 template into the package directory or download a processor16" \ " download [username/repository] Download a base16 template into the package directory or download a processor16" \
" into the processor directory. Use user/repo format to automatically pull from github." \ " into the processor directory. Use user/repo format to automatically pull from github." \
@ -149,10 +149,10 @@ set_theme() {
# carry standard names this removes everything before base16- # carry standard names this removes everything before base16-
# the result is the application it targets # the result is the application it targets
# shellcheck disable=SC2001 # shellcheck disable=SC2001
appext=$(sed "s|^[[:alnum:]]\{1,\}/base16-||" <<<"$pkg") appext=$(sed -e 's|^[A-Za-z0-9-]\{1,\}/base16-||' <<<"$pkg")
# Compares application extension with existing processors and runs the appropriate processor if found # Compares application extension with existing processors and runs the appropriate processor if found
processor=$(find "$PROCESSOR_PATH" -type f -name "theme_$appext") processor=$(find "$PROCESSOR_PATH" -type f | grep -e "theme_$appext")
if [[ -f "$processor" ]]; then if [[ -f "$processor" ]]; then
"$processor" "$PACKAGE_PATH" "$pkg" "$theme" "$permanent" "$processor" "$PACKAGE_PATH" "$pkg" "$theme" "$permanent"
else else