Skip to content

Commit 01ea81e

Browse files
committed
naming convention
1 parent 8a20ec8 commit 01ea81e

26 files changed

+262
-252
lines changed
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
[Desktop Entry]
2-
Name=ArchLinux Tweak Tool
3-
GenericName=ArchLinux Tweak Tool
4-
X-GNOME-FullName=ArchLinux Tweak Tool
5-
Comment=ArchLinux Tweak Tool - graphical interface
2+
Name=Arch Linux Tweak Tool
3+
GenericName=Arch Linux Tweak Tool
4+
X-GNOME-FullName=Arch Linux Tweak Tool
5+
Comment=ArchLinux Tweak Tool - graphical tool to set Arch Linux
66
Exec=/usr/local/bin/archlinux-tweak-tool
77
Icon=archlinux
88
Terminal=false
99
Type=Application
1010
Categories=GTK;GNOME;Utility;Settings;Security;X-GNOME-Settings-Panel;X-GNOME-SystemSettings;X-Unity-Settings-Panel;X-XFCE-SettingsDialog;X-XFCE-SystemSettings;
11-
Keywords=tweak;tool;
11+
Keywords=tweak;tool;tweaktool
1212
StartupNotify=true

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ def GUI(self, Gtk, vboxStack1, Functions):
156156
#funami
157157
vbox3.pack_start(hboxStack18, False, False, 0)
158158
#jingk
159-
vbox3.pack_start(hboxStack19, False, False, 0)
159+
vbox3.pack_start(hboxStack19, False, False, 0)
160160
#seedhost
161161
vbox3.pack_start(hboxStack7, False, False, 0)
162162

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

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# #============================================================
2-
# #= Authors: Brad Heffernan - Erik Dubois - Cameron Percival =
2+
# #= Authors: Erik Dubois - Cameron Percival =
33
# #============================================================
4-
import Functions
54

65
def GUI(self, Gtk, vboxStack2, fish, base_dir, GdkPixbuf):
76
hbox3 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
@@ -12,7 +11,7 @@ def GUI(self, Gtk, vboxStack2, fish, base_dir, GdkPixbuf):
1211
hseparator = Gtk.Separator(orientation=Gtk.Orientation.HORIZONTAL)
1312
hbox4.pack_start(hseparator, True, True, 0)
1413
hbox3.pack_start(lbl1, False, False, 0)
15-
14+
1615
# ==========================================================
1716
# FISH
1817
# ==========================================================
@@ -29,7 +28,7 @@ def GUI(self, Gtk, vboxStack2, fish, base_dir, GdkPixbuf):
2928
# ==========================================================
3029
# FISH OH-MY-FISh
3130
# ==========================================================
32-
31+
3332
label02 = Gtk.Label()
3433
label02.set_text("Install oh-my-fish")
3534
hbox02 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=0)
@@ -38,7 +37,7 @@ def GUI(self, Gtk, vboxStack2, fish, base_dir, GdkPixbuf):
3837
self.ohmyfish = Gtk.Switch()
3938
hbox02.pack_end(self.ohmyfish, False, False, 10)
4039
self.ohmyfish.connect("notify::active", self.on_ohmyfish_toggle)
41-
40+
4241
# ==========================================================
4342
# BUTTONS
4443
# ==========================================================
@@ -76,7 +75,7 @@ def GUI(self, Gtk, vboxStack2, fish, base_dir, GdkPixbuf):
7675
vboxStack2.pack_start(hbox3, False, False, 0) # Combobox
7776
vboxStack2.pack_start(hbox4, False, False, 0) # Combobox
7877
vboxStack2.pack_start(hbox01, False, False, 0) # fish
79-
#vboxStack2.pack_start(hbox02, False, False, 0) # oh-my-fish
78+
#vboxStack2.pack_start(hbox02, False, False, 0) # oh-my-fish
8079

8180
vboxStack2.pack_start(hbox21, False, False, 0) # image
8281
vboxStack2.pack_end(hbox20, False, False, 0) # Buttons

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

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -4,36 +4,36 @@
44
import distro,os
55

66
def GUI(self, Gtk, GdkPixbuf, vboxStack19, sddm, Functions):
7-
7+
88
hbox1 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
99
hbox1_label = Gtk.Label(xalign=0)
10-
hbox1_label.set_text("Fixes for " + distro.id())
10+
hbox1_label.set_text("Fixes for " + Functions.change_distro_label(distro.id()))
1111
hbox1_label.set_name("title")
1212
hbox1.pack_start(hbox1_label, False, False, 10)
13-
13+
1414
hbox0 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
1515
hseparator = Gtk.Separator(orientation=Gtk.Orientation.HORIZONTAL)
1616
hbox0.pack_start(hseparator, True, True, 0)
1717

1818
hbox2 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
1919
hbox2_label = Gtk.Label(xalign=0)
20-
hbox2_label.set_text("Reset and reload pacman keys")
20+
hbox2_label.set_text("Reset and reload pacman keys")
2121
button_Apply_Pacman_Key_Fix = Gtk.Button(label="Fix keys")
2222
button_Apply_Pacman_Key_Fix.connect ("clicked", self.on_click_fix_pacman_keys)
2323
hbox2.pack_start(hbox2_label, False, False, 10)
2424
hbox2.pack_end(button_Apply_Pacman_Key_Fix, False, False, 10)
25-
25+
2626
hbox3 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
2727
hbox3_label = Gtk.Label(xalign=0)
28-
hbox3_label.set_text("Set mainstream servers for ArchLinux")
28+
hbox3_label.set_text("Set mainstream servers for ArchLinux")
2929
button_Apply_Osbeck = Gtk.Button(label="Set mainstream")
3030
button_Apply_Osbeck.connect ("clicked", self.on_click_fix_mainstream)
3131
hbox3.pack_start(hbox3_label, False, False, 10)
32-
hbox3.pack_end(button_Apply_Osbeck, False, False, 10)
33-
32+
hbox3.pack_end(button_Apply_Osbeck, False, False, 10)
33+
3434
hbox4 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
3535
hbox4_label = Gtk.Label(xalign=0)
36-
hbox4_label.set_text("Get the best Arch Linux servers (takes a while)")
36+
hbox4_label.set_text("Get the best Arch Linux servers (takes a while)")
3737
button_Apply_Mirrors = Gtk.Button(label="Get Arch mirrors (reflector)")
3838
button_Apply_Mirrors.connect ("clicked", self.on_click_get_arch_mirrors)
3939
button_Apply_Mirrors2 = Gtk.Button(label="Get Arch mirrors (rate-mirrors)")
@@ -46,39 +46,39 @@ def GUI(self, Gtk, GdkPixbuf, vboxStack19, sddm, Functions):
4646
button_Apply_Mirrors.set_sensitive(False)
4747
if not os.path.exists("/usr/bin/rate-mirrors"):
4848
button_Apply_Mirrors2.set_sensitive(False)
49-
49+
5050
hbox5 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
5151
hbox5_label = Gtk.Label(xalign=0)
52-
hbox5_label.set_text("Get the original ArcoLinux /etc/sddm.conf and /etc/sddm.conf.d/kde_settings.conf")
52+
hbox5_label.set_text("Get the original ArcoLinux /etc/sddm.conf and /etc/sddm.conf.d/kde_settings.conf")
5353
button_Apply_Mirrors = Gtk.Button(label="Reset sddm.conf")
5454
button_Apply_Mirrors.connect ("clicked", self.on_click_fix_sddm_conf)
5555
hbox5.pack_start(hbox5_label, False, False, 10)
5656
hbox5.pack_end(button_Apply_Mirrors, False, False, 10)
57-
57+
5858
hbox6 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
5959
hbox6_label = Gtk.Label(xalign=0)
60-
hbox6_label.set_text("Get the original ArcoLinux /etc/pacman.conf")
60+
hbox6_label.set_text("Get the original ArcoLinux /etc/pacman.conf")
6161
button_Apply_Pacman_Conf = Gtk.Button(label="Reset pacman.conf")
6262
button_Apply_Pacman_Conf.connect ("clicked", self.on_click_fix_pacman_conf)
6363
hbox6.pack_start(hbox6_label, False, False, 10)
64-
hbox6.pack_end(button_Apply_Pacman_Conf, False, False, 10)
65-
64+
hbox6.pack_end(button_Apply_Pacman_Conf, False, False, 10)
65+
6666
hbox7 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
6767
hbox7_label = Gtk.Label(xalign=0)
68-
hbox7_label.set_text("Get the best keyservers for /etc/pacman.d/gnupg/gpg.conf")
68+
hbox7_label.set_text("Get the best keyservers for /etc/pacman.d/gnupg/gpg.conf")
6969
button_Apply_Pacman_Gpg_Conf = Gtk.Button(label="Backup and reset gpg.conf")
7070
button_Apply_Pacman_Gpg_Conf.connect ("clicked", self.on_click_fix_pacman_gpg_conf)
7171
hbox7.pack_start(hbox7_label, False, False, 10)
72-
hbox7.pack_end(button_Apply_Pacman_Gpg_Conf, False, False, 10)
72+
hbox7.pack_end(button_Apply_Pacman_Gpg_Conf, False, False, 10)
7373

7474
hbox8 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
7575
hbox8_label = Gtk.Label(xalign=0)
76-
hbox8_label.set_text("Get the best keyservers for ~/.gnupg/gpg.conf")
76+
hbox8_label.set_text("Get the best keyservers for ~/.gnupg/gpg.conf")
7777
button_Apply_Pacman_Gpg_Conf_Local = Gtk.Button(label="Backup and reset gpg.conf")
7878
button_Apply_Pacman_Gpg_Conf_Local.connect ("clicked", self.on_click_fix_pacman_gpg_conf_local)
7979
hbox8.pack_start(hbox8_label, False, False, 10)
8080
hbox8.pack_end(button_Apply_Pacman_Gpg_Conf_Local, False, False, 10)
81-
81+
8282
hbox9 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
8383
hbox9_label = Gtk.Label(xalign=0)
8484
hbox9_label.set_markup("<b>Distro specific</b>")
@@ -87,21 +87,21 @@ def GUI(self, Gtk, GdkPixbuf, vboxStack19, sddm, Functions):
8787
hbox10 = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
8888
hbox10_label = Gtk.Label(xalign=0)
8989
hbox10_label.set_markup("<b>For any Arch based system</b>")
90-
hbox10.pack_start(hbox10_label, False, False, 10)
91-
90+
hbox10.pack_start(hbox10_label, False, False, 10)
91+
9292
# ======================================================================
93-
# VBOX STACK
93+
# VBOX STACK
9494
# ======================================================================
95-
95+
9696
vboxStack19.pack_start(hbox1, False, False, 0)
9797
vboxStack19.pack_start(hbox0, False, False, 0)
98-
vboxStack19.pack_start(hbox10, False, False, 20)
98+
vboxStack19.pack_start(hbox10, False, False, 20)
9999
vboxStack19.pack_start(hbox2, False, False, 0)
100100
vboxStack19.pack_start(hbox3, False, False, 0)
101101
vboxStack19.pack_start(hbox4, False, False, 0)
102102
vboxStack19.pack_start(hbox7, False, False, 0)
103103
vboxStack19.pack_start(hbox8, False, False, 0)
104-
vboxStack19.pack_start(hbox9, False, False, 20)
104+
vboxStack19.pack_start(hbox9, False, False, 20)
105105
if Functions.distr == "arcolinux":
106106
vboxStack19.pack_start(hbox5, False, False, 0)
107107
#vboxStack19.pack_start(hbox6, False, False, 0)

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

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -224,11 +224,11 @@ def permissions(dst):
224224

225225
except Exception as e:
226226
print(e)
227+
227228
# =====================================================
228229
# COPY FUNCTION
229230
# =====================================================
230231

231-
232232
def copy_func(src, dst, isdir=False):
233233
if isdir:
234234
subprocess.run(["cp", "-Rp", src, dst], shell=False)
@@ -258,7 +258,7 @@ def source_shell(self):
258258
elif output == "/usr/bin/fish":
259259
subprocess.run(["fish", "-c", "su - " + sudo_username +
260260
" -c \"source " + home + "/.config/fish/config.fish\""],
261-
stdout=subprocess.PIPE)
261+
stdout=subprocess.PIPE)
262262

263263
def get_shell():
264264
process = subprocess.run(["su", "-", sudo_username,"-c","echo \"$SHELL\""],
@@ -272,7 +272,7 @@ def get_shell():
272272
elif output == "/bin/zsh" or output == "/usr/bin/zsh":
273273
return "zsh"
274274
elif output == "/bin/fish" or output == "/usr/bin/fish":
275-
return "fish"
275+
return "fish"
276276

277277
def run_as_user(script):
278278
subprocess.call(["su - " + sudo_username + " -c " + script], shell=False)
@@ -795,7 +795,7 @@ def checkIfProcessRunning(processName):
795795
def restart_program():
796796
python = sys.executable
797797
os.execl(python, python, *sys.argv)
798-
798+
799799
def check_content(value, file): # noqa
800800
with open(file, "r") as myfile:
801801
lines = myfile.readlines()
@@ -808,3 +808,16 @@ def check_content(value, file): # noqa
808808
else:
809809
return False
810810
return False
811+
812+
# =====================================================
813+
# DISTRO LABEL
814+
# =====================================================
815+
816+
def change_distro_label(name): # noqa
817+
if name == "arcolinux":
818+
name = "ArcoLinux"
819+
if name == "garuda":
820+
name = "Garuda"
821+
if name == "endeavouros":
822+
name = "EndeavourOS"
823+
return name

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

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,10 +41,10 @@ def GUI(self, Gtk, vboxStack2, Gtk_Functions, Functions):
4141
self.cursor_size = Gtk.SpinButton()
4242
self.cursor_size.set_adjustment(adj1)
4343

44-
44+
4545
# self.fonts = Gtk.FontButton()
4646
# self.monofonts = Gtk.FontButton()
47-
47+
4848
self.themeCombo.set_size_request(200, 0)
4949
self.iconCombo.set_size_request(200, 0)
5050
self.cursorCombo.set_size_request(200, 0)
@@ -94,4 +94,4 @@ def GUI(self, Gtk, vboxStack2, Gtk_Functions, Functions):
9494
vboxStack2.pack_start(hbox5, False, False, 0) # Gtk Cursor Size
9595
vboxStack2.pack_start(hbox6, False, False, 0) # Gtk Fonts
9696
vboxStack2.pack_start(hbox7, False, False, 0) # Gtk Mono Fonts
97-
vboxStack2.pack_end(hbox4, False, False, 0) # Save Button
97+
vboxStack2.pack_end(hbox4, False, False, 0) # Save Button

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

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ def GUI(self, Gtk, Gdk, GdkPixbuf, base_dir, os, Pango): # noqa
230230
# ==========================================================
231231

232232
HBlock_GUI.GUI(self, Gtk, vboxStack3, Functions)
233-
233+
234234
# # ==========================================================
235235
# # SDDM
236236
# # ==========================================================
@@ -292,13 +292,13 @@ def GUI(self, Gtk, Gdk, GdkPixbuf, base_dir, os, Pango): # noqa
292292
# # ==========================================================
293293
# # TERMINAL FUN
294294
# # ==========================================================
295-
295+
296296
Utilities_GUI.GUI(self, Gtk, GdkPixbuf, vboxStack20, Functions)
297297

298298
# ==========================================================
299299
# THEMES
300300
# ==========================================================
301-
301+
302302
if distro.id() == "arcolinux":
303303
Themer_GUI.GUI(self, Gtk, GdkPixbuf, vboxStack10, themer, Functions, base_dir)
304304

@@ -324,11 +324,11 @@ def GUI(self, Gtk, Gdk, GdkPixbuf, base_dir, os, Pango): # noqa
324324
stack.add_titled(vboxStack13, "stack13", "Autostart") # Autostart
325325

326326
stack.add_titled(vboxStack12, "stack12", "Desktop") # Desktop installer
327-
327+
328328
#stack.add_titled(vboxStack2, "stack5", "Fish") # Fish
329329

330330
stack.add_titled(vboxStack19, "stack19", "Fixes") # Fixes
331-
331+
332332
stack.add_titled(vboxStack4, "stack1", "Grub") # Grub config
333333

334334
stack.add_titled(vboxStack11, "stack3", "Lightdm") # Lightdm config
@@ -361,7 +361,7 @@ def GUI(self, Gtk, Gdk, GdkPixbuf, base_dir, os, Pango): # noqa
361361
# =====================================================
362362
# LOGO
363363
# =====================================================
364-
364+
365365
ivbox = Gtk.Box(orientation=Gtk.Orientation.VERTICAL, spacing=10)
366366
pixbuf = GdkPixbuf.Pixbuf().new_from_file_at_size(
367367
os.path.join(base_dir, 'images/arcolinux-stock.png'), 45, 45)
@@ -370,9 +370,9 @@ def GUI(self, Gtk, Gdk, GdkPixbuf, base_dir, os, Pango): # noqa
370370
# =====================================================
371371
# RESTART BUTTON
372372
# =====================================================
373-
373+
374374
lbl_distro = Gtk.Label(xalign=0)
375-
lbl_distro.set_markup("Working on\n" + distro.id())
375+
lbl_distro.set_markup("Working on\n" + Functions.change_distro_label(distro.id()))
376376
btnReStartAtt = Gtk.Button(label="Restart ATT")
377377
btnReStartAtt.connect('clicked', self.on_refresh_att_clicked)
378378
#btnReStartAtt.set_property("has-tooltip", True)

0 commit comments

Comments
 (0)