From 56f04e9fce09f6e1574f9d60a05da259723d0211 Mon Sep 17 00:00:00 2001 From: aristocratos Date: Tue, 1 Sep 2020 21:09:08 +0200 Subject: [PATCH] Added theme search path for snap install --- bpytop.py | 6 +++--- themes/index.txt | 9 --------- 2 files changed, 3 insertions(+), 12 deletions(-) delete mode 100644 themes/index.txt diff --git a/bpytop.py b/bpytop.py index 1a6c310..11fa3b8 100755 --- a/bpytop.py +++ b/bpytop.py @@ -194,9 +194,9 @@ for td in site.getsitepackages() + [site.getusersitepackages()]: THEME_DIR = f'{td}/bpytop-themes' break else: - for td in ["local/", ""]: - if os.path.isdir(f'/usr/{td}share/bpytop/themes'): - THEME_DIR = f'/usr/{td}share/bpytop/themes' + for td in ["/usr/local/", "/usr/", "/snap/bpytop/current/usr/"]: + if os.path.isdir(f'{td}share/bpytop/themes'): + THEME_DIR = f'{td}share/bpytop/themes' break USER_THEME_DIR: str = f'{CONFIG_DIR}/themes' diff --git a/themes/index.txt b/themes/index.txt deleted file mode 100644 index a0af567..0000000 --- a/themes/index.txt +++ /dev/null @@ -1,9 +0,0 @@ -default_black.theme -flat-remix-light.theme -flat-remix.theme -greyscale.theme -gruvbox_dark.theme -monokai.theme -nord.theme -solarized_dark.theme -whiteout.theme