master
Can202 2021-09-06 18:26:58 -03:00
parent 539d03c0ae
commit ffa9c40bf4
16 changed files with 106 additions and 5 deletions

9
deb/DEBIAN/control Normal file
View File

@ -0,0 +1,9 @@
Package: boxpackage
Priority: optional
Section: admin
Maintainer: Can202 <mgoopazo@gmail.com>
Architecture: amd64
Version: 0.1
Depends: python3, lxterminal
Description: Installer
Simple Visual Installer (apt)

2
deb/DEBIAN/postinst Executable file
View File

@ -0,0 +1,2 @@
#!/bin/bash
ln /usr/lib64/boxpackage/boxpackage /usr/bin/boxpackage

2
deb/DEBIAN/postrm Executable file
View File

@ -0,0 +1,2 @@
#!/bin/bash
rm -f /usr/bin/boxpackage

View File

@ -0,0 +1,28 @@
#!/bin/bash
if [ ! -z $1 ]
then
if [ $(whoami) = "root" ]
then
/usr/lib64/boxpackage/init $1
exit
fi
echo "Do you want to use sudo? (Y/n)"
read rootcommand
if [ $rootcommand = Y ] || [ $rootcommand = y ]
then
sudo /usr/lib64/boxpackage/init $1
exit
fi
echo "Do you want to use su? (Y/n)"
if [ $rootcommand = Y ] || [ $rootcommand = y ]
then
su root -c '/usr/lib64/boxpackage/init $1'
exit
fi
echo "Error, no root"
else
echo "Error, waiting \$1"
fi

View File

@ -0,0 +1,15 @@
#!/bin/bash
if [ ! -z $1 ]
then
if [ $1 = "sudo" ]
then
sudo /usr/lib64/boxpackage/init
fi
if [ $1 = "su" ]
then
su root -c '/usr/lib64/boxpackage/init'
fi
else
echo "Error, waiting \$1"
fi

View File

@ -0,0 +1,15 @@
#!/bin/bash
if [ ! -z $1 ]
then
if [ $1 = "sudo" ]
then
sudo /usr/lib64/boxpackage/init
fi
if [ $1 = "su" ]
then
su root -c '/usr/lib64/boxpackage/init'
fi
else
echo "Error, waiting \$1"
fi

View File

@ -0,0 +1,7 @@
[Desktop Entry]
Name=BoxPackage
Exec=boxpackage
Icon=boxpackage
Terminal=True
Type=Application
Categories=Utility

BIN
deb/usr/lib64/boxpackage/init Executable file

Binary file not shown.

View File

@ -0,0 +1,7 @@
[Desktop Entry]
Name=BoxPackage Su
Exec=boxpackage-su
Icon=boxpackage
Terminal=True
Type=Application
Categories=Utility

View File

@ -0,0 +1,7 @@
[Desktop Entry]
Name=BoxPackage Sudo
Exec=boxpackage-sudo
Icon=boxpackage
Terminal=True
Type=Application
Categories=Utility

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

17
exec
View File

@ -5,9 +5,18 @@ then
if [ $1 = "sudo" ]
then
sudo python3 /home/manuel/Descargas/installer-test/init.py
else
if [ $1 = "su" ]
then
su root -c 'python3 /home/manuel/Descargas/installer-test/init.py'
else
echo execute with sudo? (Y/n)
read sudo
if [ $sudo = Y ] || [ $sudo = y ]
then
sudo python3 /home/manuel/Descargas/installer-test/init.py
fi
fi
if [ $1 = "su" ]
then
su root -c 'python3 /home/manuel/Descargas/installer-test/init.py'
fi
fi

View File

@ -16,7 +16,7 @@ BUTTONWIDTH='39'
TEXTWIDTH=18
screen = tk.Tk()
screen.title("Install")
screen.title("BoxPackage")
screen.geometry("400x400")
screen.resizable(width = False, height = False)

BIN
media/icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 329 KiB

BIN
media/icon.xcf Normal file

Binary file not shown.

BIN
media/icon256.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB