Files
scwrypts/zsh/scwrypts/configure
T

34 lines
1.1 KiB
Bash
Raw Normal View History

2022-04-28 16:09:23 -06:00
#!/bin/zsh
2023-02-21 18:44:27 -07:00
use scwrypts/meta
2022-04-28 16:09:23 -06:00
#####################################################################
2024-02-06 14:06:44 -07:00
MAIN() {
local USER_CONFIG_OVERRIDES="$SCWRYPTS_CONFIG_PATH/config.zsh"
[ ! -f "$USER_CONFIG_OVERRIDES" ] && {
STATUS 'first-time setup detected; creating local configuration override...'
cp "$DEFAULT_CONFIG" "$USER_CONFIG_OVERRIDES"
2023-02-21 18:44:27 -07:00
2024-02-06 14:06:44 -07:00
EDIT $USER_CONFIG_OVERRIDES
STATUS 'attempting first-time build for virtual environments'
SCWRYPTS__RUN --name scwrypts/virtualenv/update-all --group scwrypts --type zsh \
&& SUCCESS 'finished updating virtualenvs' \
|| WARNING 'unable to create one or more virtualenv (see above)' \
;
REMINDER '
in the future, you can use the following scwrypt to update required virtual
environments (equivalent to "npm install" or "pip install -r requirements"):
scwrypts --name scwrypts/virtualenv/update-all --group scwrypts --type zsh
'
} || {
EDIT "$USER_CONFIG_OVERRIDES"
}
SUCCESS 'saved new configuration'
REMINDER 'changes which affect the hot-key plugin will require a ZSHRC reload'
2022-04-28 16:09:23 -06:00
}