update final cleanup script
This commit is contained in:
parent
eddc40c39c
commit
4059618bc9
|
@ -21,3 +21,6 @@ chroot /target apt purge --autoremove -y \
|
|||
|
||||
# Clean unnecessary files
|
||||
rm -r /target/boot/firmware
|
||||
|
||||
# system update
|
||||
chroot /target apt update && apt upgrade -y
|
||||
|
|
|
@ -21,3 +21,6 @@ chroot /target apt purge --autoremove -y \
|
|||
|
||||
# Clean unnecessary files
|
||||
rm -r /target/boot/firmware
|
||||
|
||||
# system update
|
||||
chroot /target apt update && apt upgrade -y
|
||||
|
|
|
@ -32,6 +32,8 @@ def check_packages():
|
|||
backup_tool['state'] = tk.DISABLED
|
||||
if os.path.exists('/usr/bin/gnome-software'):
|
||||
store['state'] = tk.DISABLED
|
||||
if os.path.exists('/usr/bin/keepassxc'):
|
||||
store['state'] = tk.DISABLED
|
||||
|
||||
|
||||
def check_web_browsers():
|
||||
|
@ -61,6 +63,14 @@ def install_atril():
|
|||
check_packages()
|
||||
|
||||
|
||||
def install_keepass():
|
||||
""" Install KeePass """
|
||||
subprocess.Popen(["x-terminal-emulator", "-e", "sudo", "apt", "install",
|
||||
"keepassxc"]
|
||||
)
|
||||
check_packages()
|
||||
|
||||
|
||||
def install_parole():
|
||||
""" Install parole """
|
||||
subprocess.Popen(["x-terminal-emulator", "-e", "sudo", "apt", "install",
|
||||
|
@ -166,6 +176,78 @@ def install_falkon():
|
|||
check_web_browsers()
|
||||
|
||||
|
||||
def check_base_snaps():
|
||||
""" If Devuan is loaded do not show snaps """
|
||||
if os.path.exists("/etc/devuan_version"):
|
||||
flatpak = ttk.Button(software_frame,
|
||||
text="Flatpak Package Platform",
|
||||
cursor="hand2", style="dark",
|
||||
command=install_flatpak
|
||||
)
|
||||
flatpak.grid(row=4, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
store = ttk.Button(software_frame,
|
||||
text="Gnome Software Store",
|
||||
cursor="hand2", style="dark",
|
||||
command=install_store
|
||||
)
|
||||
store.grid(row=5, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
backup_tool = ttk.Button(software_frame,
|
||||
text="TimeShift: Backup Tool",
|
||||
cursor="hand2", style="dark",
|
||||
command=install_keepass
|
||||
)
|
||||
backup_tool.grid(row=7, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
pwd_tool = ttk.Button(software_frame,
|
||||
text="KeePassXC: Password Tool",
|
||||
cursor="hand2", style="dark",
|
||||
command=install_timeshift
|
||||
)
|
||||
pwd_tool.grid(row=6, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
|
||||
elif os.path.exists("/etc/debian_version"):
|
||||
snap = ttk.Button(software_frame,
|
||||
text="Snap Package Platform",
|
||||
cursor="hand2", style="dark",
|
||||
command=install_snap
|
||||
)
|
||||
snap.grid(row=4, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
flatpak = ttk.Button(software_frame,
|
||||
text="Flatpak Package Platform",
|
||||
cursor="hand2", style="dark",
|
||||
command=install_flatpak
|
||||
)
|
||||
flatpak.grid(row=5, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
store = ttk.Button(software_frame,
|
||||
text="Gnome Software Store",
|
||||
cursor="hand2", style="dark",
|
||||
command=install_store
|
||||
)
|
||||
store.grid(row=6, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
backup_tool = ttk.Button(software_frame,
|
||||
text="TimeShift: Backup Tool",
|
||||
cursor="hand2", style="dark",
|
||||
command=install_timeshift
|
||||
)
|
||||
backup_tool.grid(row=7, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
|
||||
|
||||
|
||||
# *** Below here is the layout of the forms***
|
||||
# Frame that managed the Welcome To Peppermint Section
|
||||
fsw = ttk.Frame(pwin, width=200)
|
||||
|
@ -195,32 +277,7 @@ fire_wall = ttk.Button(software_frame, text="gufw: GNU Firewall",
|
|||
fire_wall.grid(row=3, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
snap = ttk.Button(software_frame, text="Snap Package Platform",
|
||||
cursor="hand2", style="dark", command=install_snap
|
||||
)
|
||||
snap.grid(row=4, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
flatpak = ttk.Button(software_frame, text="Flatpak Package Platform",
|
||||
cursor="hand2", style="dark", command=install_flatpak
|
||||
)
|
||||
flatpak.grid(row=5, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
store = ttk.Button(software_frame, text="Gnome Software Store",
|
||||
cursor="hand2", style="dark", command=install_store
|
||||
)
|
||||
store.grid(row=6, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
backup_tool = ttk.Button(software_frame, text="TimeShift: Backup Tool",
|
||||
cursor="hand2", style="dark",
|
||||
command=install_timeshift
|
||||
)
|
||||
backup_tool.grid(row=7, column=0, ipadx=5, ipady=5, padx=5, pady=5,
|
||||
sticky='ew'
|
||||
)
|
||||
# Frame that manages the Community buttons
|
||||
# Frame that manages the Browser buttons
|
||||
fs = ttk.Frame(pwin)
|
||||
fs.grid(row=2, column=5, columnspan=2, ipadx=0, ipady=0, padx=10, pady=10)
|
||||
|
||||
|
@ -269,6 +326,7 @@ lblpmtitle = ttk.Label(pwin, style="F62817.TLabel",
|
|||
text='These suggestions are listed in the official'
|
||||
' repositories'
|
||||
).place(x=5, y=440)
|
||||
check_base_snaps()
|
||||
check_packages()
|
||||
check_web_browsers()
|
||||
pwin.mainloop()
|
||||
|
|
Loading…
Reference in New Issue