diff --git a/.gitignore b/.gitignore index d74fc8f..a631182 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ webxdc.js *.xdc +*~ \ No newline at end of file diff --git a/pack.sh~ b/pack.sh~ deleted file mode 100755 index 5a482ee..0000000 --- a/pack.sh~ +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/sh - -case "$1" in - "-h" | "--help") - echo "usage: ${0##*/} [PACKAGE_NAME]" - exit - ;; - "") - PACKAGE_NAME=${PWD##*/} # '##*/' removes everything before the last slash and the last slash - ;; - *) - PACKAGE_NAME=${1%.xdc} # '%.xdc' removes the extension and allows PACKAGE_NAME to be given with or without extension - ;; -esac - -rm "$PACKAGE_NAME.xdc" 2> /dev/null -zip -9 --recurse-paths "$PACKAGE_NAME.xdc" --exclude LICENSE README.md webxdc.js webxdc.d.ts "./*.sh" "./*.xdc" -- * - -echo "success, archive contents:" -unzip -l "$PACKAGE_NAME.xdc" - -# check package size -MAXSIZE=655360 -size=$(wc -c < "$PACKAGE_NAME.xdc") -if [ "$size" -ge $MAXSIZE ]; then - echo "WARNING: package size exceeded the limit ($size > $MAXSIZE)" -fi