Skip to content

Commit

Permalink
fixed mistake in last commit
Browse files Browse the repository at this point in the history
  • Loading branch information
ErikBjare committed Apr 21, 2017
1 parent 31af22d commit e98a1ce
Showing 1 changed file with 2 additions and 27 deletions.
29 changes: 2 additions & 27 deletions scripts/package.sh → scripts/package-zip.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,40 +2,15 @@

set -e

# Clean
rm -r dist/ || true
mkdir dist
mkdir dist/activitywatch

PYINSTALL_TARGETS=$(find . -maxdepth 2 | egrep 'aw-.*/.*\.spec')

echo "PyInstaller .spec files found"
for target in $PYINSTALL_TARGETS; do
echo " - $target";
done

for target in $PYINSTALL_TARGETS; do
target_dir=$(dirname $target)

echo
echo "-------------------------------------"
echo "Building $target_dir"
pyinstaller $target --clean

# Putting it all in one folder
cp -r dist/$target_dir/* dist/activitywatch
rm -r dist/$target_dir
done

echo
echo "-------------------------------------"
echo "Zipping executables..."
cd dist;
platform=$(uname | tr '[:upper:]' '[:lower:]')
if [[ "$platform" == "darwin" ]]; then
platform="macos";
elif [[ $platform == "cygwin"* ]]; then
platform="windows"
echo "ERROR: cygwin is not a valid platform"
exit 1
fi

if [[ $platform == "windows"* ]]; then
Expand Down

0 comments on commit e98a1ce

Please sign in to comment.