586b543a4c
ZIP release artifacts were tracked in git, bloating the repo and causing oversized release uploads on Gitea. Build output now goes to build/ which is gitignored along with *.zip. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
20 lines
697 B
Bash
Executable File
20 lines
697 B
Bash
Executable File
#!/bin/bash
|
|
# Build extension ZIP package
|
|
set -euo pipefail
|
|
VERSION=$(python3 -c "import json; print(json.load(open('manifest.json'))['version'])")
|
|
MODULE=$(python3 -c "import json; m=json.load(open('manifest.json')); print(m.get('module', m['name']))")
|
|
ZIPNAME="${MODULE}-${VERSION}.zip"
|
|
BUILDDIR="build"
|
|
|
|
# Update version in README.md if it exists
|
|
if [[ -f README.md ]]; then
|
|
sed -i "s/\*\*גרסה:\*\* [^ |]*/\*\*גרסה:\*\* ${VERSION}/" README.md
|
|
fi
|
|
|
|
mkdir -p "$BUILDDIR"
|
|
echo "Building $ZIPNAME..."
|
|
rm -f "$BUILDDIR/$ZIPNAME"
|
|
zip -r "$BUILDDIR/$ZIPNAME" manifest.json files/ \
|
|
-x "*.DS_Store" "*__MACOSX*"
|
|
echo "✓ Built: $BUILDDIR/$ZIPNAME ($(du -h "$BUILDDIR/$ZIPNAME" | cut -f1))"
|