summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbundle_pyinstaller.sh10
1 files changed, 6 insertions, 4 deletions
diff --git a/bundle_pyinstaller.sh b/bundle_pyinstaller.sh
index d504635..7bc9764 100755
--- a/bundle_pyinstaller.sh
+++ b/bundle_pyinstaller.sh
@@ -154,11 +154,13 @@ install_sumo(){
_cdsitepackages
- # the file name is like 'leap.bitmask-0.9.0rc1-12-g59bc704-SUMO.tar.gz'
+ # the file name may be like 'leap.bitmask-0.9.0rc1-12-g59bc704-SUMO.tar.gz',
+ # but it also can be 'leap.bitmask-latest-SUMO.tar.gz'
# and the root path inside the archive for that file would be
- # 'leap.bitmask-0.9.0rc1-12-g59bc704-SUMO'
- base_path=`basename $SUMO_PATH .tar.gz`
- tar xzf $SUMO_PATH $base_path/src/leap/ --strip-components=2
+ # 'leap.bitmask-0.9.0rc1-12-g59bc704-SUMO' in both cases.
+ base_path=`tar tzf $SUMO_PATH | head -n 1`
+ target_subpath=src/leap
+ tar xzf $SUMO_PATH $base_path$target_subpath --strip-components=2
}
add_files(){