diff options
| author | black <dylan.araps@gmail.com> | 2019-04-30 12:02:28 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-04-30 12:02:28 +0300 |
| commit | e7d956ca18c72f52dd6c5f5c2e606d287d025723 (patch) | |
| tree | 875db0b2abb17478d7acdfd846539060112346af /pywal | |
| parent | c823e3c9dbd0100ca09caf824e77d296685a1c1e (diff) | |
| parent | efa7c86ec5f9b0f5df0d361fe1f8b7a9076b65de (diff) | |
Merge pull request #406 from WillEccles/pidof-mac-fix
Fixed pidof invalid argument on Mac OS
Diffstat (limited to 'pywal')
| -rw-r--r-- | pywal/util.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/pywal/util.py b/pywal/util.py index a158da9..e4b146a 100644 --- a/pywal/util.py +++ b/pywal/util.py @@ -8,6 +8,7 @@ import os import shutil import subprocess import sys +import platform class Color: @@ -183,7 +184,11 @@ def get_pid(name): return False try: - subprocess.check_output(["pidof", "-s", name]) + if platform.system() != 'Darwin': + subprocess.check_output(["pidof", "-s", name]) + else: + subprocess.check_output(["pidof", name]) + except subprocess.CalledProcessError: return False |
