Skip to content

Commit 466132f

Browse files
Update main.py
1 parent 1f05900 commit 466132f

1 file changed

Lines changed: 9 additions & 4 deletions

File tree

main.py

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/usr/bin/env python3
22

3-
PYFETCH_VERSION = "1.1.1" # Changing the version in this line is highly not recommended.
3+
PYFETCH_VERSION = "1.1.1-2" # Changing the version in this line is highly not recommended.
44
import os
55

66
# Load ~/.config/pyfetch/pyfetch.conf
@@ -204,7 +204,7 @@ def pyfetchbase():
204204
else:
205205
print("Packages: Unknown")
206206
if cfg.get('fun_facts', 'true') == 'true':
207-
print(random_fact)
207+
print("Fun Fact:", random_fact)
208208
if cfg.get('show_pyfversion', 'true') == 'true':
209209
print(f"PyFetch Version:", PYFETCH_VERSION)
210210
if cfg.get('show_shell_version', 'true') == 'true':
@@ -231,7 +231,7 @@ def pyfetchbasenonconfig():
231231
print(f"Packages: {pkg_count}")
232232
else:
233233
print("Packages: Unknown")
234-
print(random_fact)
234+
print("Fun Fact:", random_fact)
235235
print(f"PyFetch Version:", PYFETCH_VERSION)
236236
print("Shell:", get_shell_version())
237237
print("Battery:", get_battery_percentage())
@@ -260,7 +260,7 @@ def nopluginsbase():
260260
else:
261261
print("Packages: Unknown")
262262
if cfg.get('fun_facts', 'true') == 'true':
263-
print(random_fact)
263+
print("Fun Fact:", random_fact)
264264
if cfg.get('show_pyfversion', 'true') == 'true':
265265
print(f"PyFetch Version:", PYFETCH_VERSION)
266266
if cfg.get('show_shell_version', 'true') == 'true':
@@ -282,6 +282,7 @@ def nopluginsbase():
282282
parser.add_argument("--noplugins", action="store_true", help="Exclude Plugins")
283283
parser.add_argument("--list-plugins", action="store_true", help="List all available plugins")
284284
parser.add_argument("--fun-fact", action="store_true", help="Show some fun facts")
285+
parser.add_argument("--edit-config", action="store_true", help="A easier way to edit pyfetch.conf")
285286
args = parser.parse_args()
286287

287288
if args.minimal:
@@ -326,6 +327,10 @@ def nopluginsbase():
326327
print(random_fact)
327328
exit()
328329

330+
if args.edit_config:
331+
os.system('nano ~/.config/pyfetch/pyfetch.conf')
332+
exit()
333+
329334
# If no flags are running
330335
pyfetchbase()
331336
else:

0 commit comments

Comments
 (0)