class to functions and check=True to subprocess.run
This commit is contained in:
parent
39550b392d
commit
28cc423138
Binary file not shown.
@ -97,7 +97,7 @@ class Create:
|
||||
process = subprocess.run(
|
||||
["pkexec", "/usr/local/bin/ssl_decrypt.py"],
|
||||
stdout=subprocess.PIPE,
|
||||
text=True,
|
||||
text=True, check=True
|
||||
)
|
||||
# print(process.stdout)
|
||||
if process.returncode == 0:
|
||||
@ -113,7 +113,7 @@ class Create:
|
||||
process = subprocess.run(
|
||||
["pkexec", "/usr/local/bin/ssl_encrypt.py"],
|
||||
stdout=subprocess.PIPE,
|
||||
text=True,
|
||||
text=True, check=True
|
||||
)
|
||||
print(process.stdout)
|
||||
if process.returncode == 0:
|
||||
@ -122,15 +122,11 @@ class Create:
|
||||
print(f"Error with the following code... {process.returncode}")
|
||||
|
||||
|
||||
class UOS:
|
||||
"""
|
||||
The class is only for unixoidal systems "UOS" = UnixOS
|
||||
|
||||
def uos():
|
||||
"""
|
||||
|
||||
@staticmethod
|
||||
def username():
|
||||
"""
|
||||
uos = LOGIN USERNAME
|
||||
|
||||
This method displays the user name of the logged-in user,
|
||||
even if you are rooted in a shell
|
||||
"""
|
||||
@ -377,14 +373,7 @@ class Tunnel:
|
||||
pass
|
||||
|
||||
|
||||
class Tipi:
|
||||
"""
|
||||
Class for Tooltip setting write in File
|
||||
Calling request path to file
|
||||
"""
|
||||
|
||||
@staticmethod
|
||||
def if_tip(path):
|
||||
def if_tip(path):
|
||||
"""
|
||||
method that writes in file whether tooltip is displayed or not
|
||||
"""
|
||||
|
@ -12,16 +12,16 @@ import tkinter as tk
|
||||
from pathlib import Path
|
||||
from subprocess import check_call
|
||||
from tkinter import filedialog, ttk, TclError
|
||||
from cls_mth_fc import Tunnel, Create, msg_window, Tipi, GiteaUpdate, UOS
|
||||
from cls_mth_fc import Tunnel, Create, msg_window, if_tip, GiteaUpdate, uos
|
||||
|
||||
UOS.username()
|
||||
uos()
|
||||
Create.dir_and_files()
|
||||
Create.make_dir()
|
||||
Create.decrypt()
|
||||
|
||||
tcl_path = Path("/usr/share/TK-Themes")
|
||||
wg_set = Path(Path.home() / ".config/wire_py/settings")
|
||||
wg_tips = Tipi.if_tip(wg_set)
|
||||
wg_tips = if_tip(wg_set)
|
||||
dirname = Path("/tmp/tlecdcwg/")
|
||||
|
||||
""" 1 = 1. Year, 09 = Month of the Year, 2924 = Day and Year of the Year """
|
||||
|
Loading…
x
Reference in New Issue
Block a user