Skip to content

Commit

Permalink
fix_linux_installer
Browse files Browse the repository at this point in the history
  • Loading branch information
trappitsch committed Jun 7, 2024
1 parent bc08b77 commit 9c410ac
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/box/installer_utils/linux_hlp.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,10 @@ def create_bash_installer_gui(name_pkg, version, icon_name) -> str:
echo " exit 1" >> $UNINSTALL_FILE
echo " fi" >> $UNINSTALL_FILE
echo "" >> $UNINSTALL_FILE
echo "rm -rf $INSTALL_DIR" >> $UNINSTALL_FILE
echo "rm -f $INSTALL_DIR/$INSTALL_NAME" >> $UNINSTALL_FILE
echo "rm -f $INSTALL_DIR/$ICON_NAME" >> $UNINSTALL_FILE
echo "rm -f $UNINSTALL_FILE" >> $UNINSTALL_FILE
echo "rmdir $INSTALL_DIR" >> $UNINSTALL_FILE
echo "rm -f $DESKTOP_FILE" >> $UNINSTALL_FILE
echo "rm -rf $HOME/.local/share/pyapp/$INSTALL_NAME" >> $UNINSTALL_FILE
echo "" >> $UNINSTALL_FILE
Expand Down
3 changes: 3 additions & 0 deletions tests/cli/test_cli_installer.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,9 @@ def test_installer_gui_linux(rye_project):
assert file_content.find(icon_file_content, icon_start) != -1
assert os.stat(installer_file).st_mode & stat.S_IXUSR != 0

# assure we only have one `rm -rf` in the install file (for pyapp folder)
assert file_content.count("rm -rf") == 1

assert installer_file.name in result.output


Expand Down

0 comments on commit 9c410ac

Please sign in to comment.