summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pkgs/pywb/default.nix5
1 files changed, 3 insertions, 2 deletions
diff --git a/pkgs/pywb/default.nix b/pkgs/pywb/default.nix
index 9664cd7..4e98969 100644
--- a/pkgs/pywb/default.nix
+++ b/pkgs/pywb/default.nix
@@ -13,9 +13,10 @@ writeShellApplication {
echo "not specified command to run" >&2
exit 2
fi
- if [ -f "$pwbs/''${1:-}.py" ]; then
+ cmd="''${1:-}"; shift
+ if [ -f "$pwbs/$cmd.py" ]; then
exec "${pywikibot}/bin/pwb" "$pwbs/''${1:-}" "$@"
- elif [ -f "$pwbs/''${1:-}" ]; then
+ elif [ -f "$pwbs/$cmd" ]; then
exec "${pywikibot}/bin/pwb" "$pwbs/''${1:-}" "$@"
else
if [ "$1" = "__get_path" ]; then