From 6e566f3adbd450b704081c7ce963c59e57a81e7b Mon Sep 17 00:00:00 2001
From: Jeremy Auguste <jeremy.auguste@etu.univ-amu.fr>
Date: Wed, 5 Jul 2017 10:28:40 +0200
Subject: [PATCH] Small change to the way command arguments are handled

---
 pylauncher.sh | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/pylauncher.sh b/pylauncher.sh
index 617c416..a7318d2 100755
--- a/pylauncher.sh
+++ b/pylauncher.sh
@@ -1,13 +1,14 @@
 #! /bin/zsh
 
-if [[ $# -ne 2 ]]; then
-    echo "Usage: $0 environment_name command" >&2
+if [[ $# -lt 2 ]]; then
+    echo "Usage: $0 environment_name command [arg1..argn]" >&2
     exit 1
 fi
 
 environment="$1"
-command="$2"
+shift 1
+# command="$2"
 
 source activate $environment
 
-eval $command
+eval "$@"
-- 
GitLab