Deploy script fo Linux
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -8,6 +8,5 @@ pyinstaller_cmd.txt
|
|||||||
themes/.current_theme
|
themes/.current_theme
|
||||||
launch.bat
|
launch.bat
|
||||||
designer.bat
|
designer.bat
|
||||||
*.sh
|
|
||||||
default_pics/
|
default_pics/
|
||||||
.vscode/
|
.vscode/
|
||||||
|
|||||||
30
deploy/Linux/deploy_linux.sh
Normal file
30
deploy/Linux/deploy_linux.sh
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
clear
|
||||||
|
# Set the correct permissions for Artemis folder
|
||||||
|
sudo chmod 700 $PWD/../../
|
||||||
|
# Download necessary libraries with pip3
|
||||||
|
read -p "Install the necessary Python libraries? [Y,N] " doit
|
||||||
|
case $doit in
|
||||||
|
y|Y) pip3 install -r requirements_lin.txt --user ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
# Generation of shortcut
|
||||||
|
read -p "Create a desktop shortcut? [Y/N] " doit
|
||||||
|
case $doit in
|
||||||
|
y|Y)
|
||||||
|
cat << EOR > /home/$USER/.local/share/applications/artemis.desktop
|
||||||
|
#!/usr/bin/env xdg-open
|
||||||
|
[Desktop Entry]
|
||||||
|
Name=Artemis
|
||||||
|
StartupWMClass=artemis3
|
||||||
|
Exec=sh -c "cd $PWD/../../ && python3 artemis.py"
|
||||||
|
Terminal=False
|
||||||
|
Icon=artemis3
|
||||||
|
Type=Application
|
||||||
|
EOR
|
||||||
|
sudo cp ./artemis3.svg /usr/share/icons/
|
||||||
|
;;
|
||||||
|
n|N) ;;
|
||||||
|
*) echo "invalid option $REPLY";;
|
||||||
|
esac
|
||||||
|
echo ""
|
||||||
|
echo "SETTING COMPLETE!"
|
||||||
@@ -34,7 +34,7 @@ set /p choice=Download necessary Python libraries? [Y]/N
|
|||||||
if /I '%choice%'=='Y' pip3 install -r %~dp0requirements_win.txt
|
if /I '%choice%'=='Y' pip3 install -r %~dp0requirements_win.txt
|
||||||
echo:
|
echo:
|
||||||
|
|
||||||
REM Create a shortcut
|
REM Generation of shortcut
|
||||||
set choice=Y
|
set choice=Y
|
||||||
set /p choice=Create a desktop shortcut? [Y]/N
|
set /p choice=Create a desktop shortcut? [Y]/N
|
||||||
if /I '%choice%'=='N' goto end
|
if /I '%choice%'=='N' goto end
|
||||||
|
|||||||
Reference in New Issue
Block a user