Code Update
This commit is contained in:
19
src/commands/maintenance/install.sh
Normal file
19
src/commands/maintenance/install.sh
Normal file
@@ -0,0 +1,19 @@
|
||||
wx-install(){
|
||||
if [[ -z $1 ]]
|
||||
then
|
||||
wx-header "Install"
|
||||
fi
|
||||
|
||||
wx-restricted
|
||||
|
||||
if [[ -f "./wx" ]] && [[ -d "./src" ]]
|
||||
then
|
||||
podman run -it --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp docker.io/library/php:8-cli php generator.php &> /dev/null
|
||||
mv wx.tmp wx &> /dev/null
|
||||
chmod +x wx &> /dev/null
|
||||
fi
|
||||
|
||||
mkdir $HOME/bin &> /dev/null
|
||||
curl https://git.waren.io/warengroup/wx/raw/branch/master/wx -o $HOME/bin/wx &> /dev/null
|
||||
chmod +x $HOME/bin/wx &> /dev/null
|
||||
}
|
8
src/commands/maintenance/uninstall.sh
Normal file
8
src/commands/maintenance/uninstall.sh
Normal file
@@ -0,0 +1,8 @@
|
||||
wx-uninstall(){
|
||||
wx-header "Uninstall"
|
||||
wx-logout
|
||||
if [[ ! -d "$HOME/.config/warengroup" ]]
|
||||
then
|
||||
rm "$HOME/.config/warengroup" -rf
|
||||
fi
|
||||
}
|
4
src/commands/maintenance/update.sh
Normal file
4
src/commands/maintenance/update.sh
Normal file
@@ -0,0 +1,4 @@
|
||||
wx-update(){
|
||||
wx-header "Update"
|
||||
wx-install --update
|
||||
}
|
Reference in New Issue
Block a user