Skip to content

Commit a7da9db

Browse files
committed
update
1 parent cd204ff commit a7da9db

File tree

5 files changed

+50
-32
lines changed

5 files changed

+50
-32
lines changed
Binary file not shown.
Binary file not shown.

usr/share/archlinux-tweak-tool/get_desktop.sh

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,18 @@ function detect_i3wm()
102102
return 1
103103
}
104104

105+
function detect_leftwm()
106+
{
107+
ps -e | grep -E '^.* leftwm$' > /dev/null
108+
if [ $? -ne 0 ];
109+
then
110+
return 0
111+
fi
112+
VERSION=`leftwm --version | awk '{print $2}'`
113+
DESKTOP="LEFTWM"
114+
return 1
115+
}
116+
105117
function detect_lxde()
106118
{
107119
ps -e | grep -E '^.* lxsession$' > /dev/null
@@ -240,6 +252,7 @@ detect_jwm;
240252
detect_mate;
241253
detect_openbox;
242254
#needs to be here because of lxqt and openbox
255+
detect_leftwm;
243256
detect_lxde;
244257
detect_lxqt;
245258
detect_plasma;
53.9 KB
Loading

usr/share/archlinux-tweak-tool/sddm.py

Lines changed: 37 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -7,37 +7,42 @@
77
import os
88

99
def check_sddmk_complete(self):
10-
with open(fn.sddm_default_d2, "r", encoding="utf-8") as f:
11-
lines = f.readlines()
12-
f.close()
13-
flag_a = False
14-
flag_s = False
15-
flag_u = False
16-
flag_t = False
17-
flag_c = False
18-
flag_ct = False
19-
flag_f = False
20-
21-
for line in lines:
22-
if "[Autologin]" in line:
23-
flag_a = True
24-
if "Session=" in line:
25-
flag_s = True
26-
if "User=" in line:
27-
flag_u = True
28-
if "[Theme]" in line:
29-
flag_t = True
30-
if "Current=" in line:
31-
flag_c = True
32-
if "CursorTheme=" in line:
33-
flag_ct = True
34-
if "Font=" in line:
35-
flag_f = True
36-
37-
if flag_a and flag_s and flag_u and flag_t and flag_c and flag_ct and flag_f:
38-
return True
39-
else:
40-
return False
10+
try:
11+
with open(fn.sddm_default_d2, "r", encoding="utf-8") as f:
12+
lines = f.readlines()
13+
f.close()
14+
flag_a = False
15+
flag_s = False
16+
flag_u = False
17+
flag_t = False
18+
flag_c = False
19+
flag_ct = False
20+
flag_f = False
21+
22+
for line in lines:
23+
if "[Autologin]" in line:
24+
flag_a = True
25+
if "Session=" in line:
26+
flag_s = True
27+
if "User=" in line:
28+
flag_u = True
29+
if "[Theme]" in line:
30+
flag_t = True
31+
if "Current=" in line:
32+
flag_c = True
33+
if "CursorTheme=" in line:
34+
flag_ct = True
35+
if "Font=" in line:
36+
flag_f = True
37+
38+
if flag_a and flag_s and flag_u and flag_t and flag_c and flag_ct and flag_f:
39+
return True
40+
else:
41+
return False
42+
except Exception as FileNotFoundError:
43+
print("---------------------------------------------------------------------------")
44+
print("Type 'fix-sddm-conf' in a terminal and restart ATT")
45+
print("---------------------------------------------------------------------------")
4146

4247
def check_sddmk_session(value):
4348
with open(fn.sddm_default_d2, "r", encoding="utf-8") as myfile:
@@ -252,4 +257,4 @@ def pop_login_managers_combo (self,combo):
252257
if fn.check_content("lightdm", "/etc/systemd/system/display-manager.service"):
253258
self.login_managers_combo.set_active(1)
254259
if fn.check_content("lxdm", "/etc/systemd/system/display-manager.service"):
255-
self.login_managers_combo.set_active(2)
260+
self.login_managers_combo.set_active(2)

0 commit comments

Comments
 (0)