diff options
-rw-r--r-- | pypaste/client/__main__.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/pypaste/client/__main__.py b/pypaste/client/__main__.py index fabf50c..7a86445 100644 --- a/pypaste/client/__main__.py +++ b/pypaste/client/__main__.py @@ -1,7 +1,6 @@ import sys import pkgutil import subprocess -import shlex import pypaste.client.plugins as plugins from importlib import import_module from argparse import ArgumentParser @@ -77,8 +76,13 @@ def main() -> int: except Exception as e: print(f"failed to read {file}: {e}") elif (command := args.command) is not None: - cmd = shlex.split(command, posix=True) - proc = subprocess.run(cmd, capture_output=True, text=True, shell=True) + proc = subprocess.run( + command, + text=True, + shell=True, + stdout=subprocess.PIPE, + stderr=subprocess.STDOUT, + ) if proc.returncode != 0: print( |