diff options
| author | Dylan Araps <dylan.araps@gmail.com> | 2017-07-23 11:32:03 +1000 |
|---|---|---|
| committer | Dylan Araps <dylan.araps@gmail.com> | 2017-07-23 11:32:03 +1000 |
| commit | 7e5723d7c1104f984642059e7e514a58924afd49 (patch) | |
| tree | 5ed6eca3ebb4552cf3173c3829fe8d873be22c92 | |
| parent | 1eb16c8f97332bc63103dae6f2ac1fb46a168445 (diff) | |
reload: Add missing arg.
| -rw-r--r-- | .pylintrc | 2 | ||||
| -rw-r--r-- | pywal/reload.py | 10 |
2 files changed, 8 insertions, 4 deletions
diff --git a/.pylintrc b/.pylintrc new file mode 100644 index 0000000..636c5a3 --- /dev/null +++ b/.pylintrc @@ -0,0 +1,2 @@ +[BASIC] +good-names=i3 diff --git a/pywal/reload.py b/pywal/reload.py index 2648a70..12769bf 100644 --- a/pywal/reload.py +++ b/pywal/reload.py @@ -9,10 +9,12 @@ from .settings import __cache_dir__ from . import util -def xrdb(cache_dir): +def xrdb(xrdb_file=None): """Merge the colors into the X db so new terminals use them.""" + xrdb_file = xrdb_file or __cache_dir__ / "colors.Xresources" + if shutil.which("xrdb"): - subprocess.call(["xrdb", "-merge", cache_dir / "colors.Xresources"], + subprocess.call(["xrdb", "-merge", xrdb_file], stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) @@ -29,9 +31,9 @@ def polybar(): util.disown("pkill", "-USR1", "polybar") -def env(cache_dir=__cache_dir__): +def env(xrdb_file=None): """Reload environment.""" - xrdb(cache_dir) + xrdb(xrdb_file) i3() polybar() print("reload: Reloaded environment.") |
