mirror of
https://github.com/wekan/wekan.git
synced 2026-11-24 20:45:00 -05:00
The checkout is at ~/repos/wekan on Linux, ~/Documents/repos/wekan on macOS and Downloads\repos\wekan on Windows (CLAUDE.md). release.sh, release-bundle.sh, release-snap.sh, release-sandstorm.sh, release-cleanup.sh, install-sandstorm.sh, node-update.sh, docker-push-gantt.sh, up.sh and rel.sh hard-coded Linux's ~/repos/wekan (rel.sh also /home/wekan/repos), so on a Mac they cd'd into nothing - or into a stale copy - and edited or packed the wrong tree. Each finds the checkout from its own location now (REPO_DIR, as mirror.sh already did), which is right on every system; the parent directory is $(dirname "$REPO_DIR"). DOWNLOAD_DIR defaulted to ~/Lataukset, the Finnish Linux name of Downloads. macOS keeps ~/Downloads in every language, so it is Lataukset where that exists and Downloads otherwise. The VirtualBox appliance scripts keep /home/wekan: that image is a Linux VM with its own fixed layout. tests/repoLocationPerOs.test.cjs pins the three locations in CLAUDE.md and AGENTS.md and fails on any script that hard-codes one system's checkout path or assumes Lataukset. Thanks to xet7 !
35 lines
781 B
Bash
Executable File
35 lines
781 B
Bash
Executable File
#!/bin/bash
|
|
# The checkout is wherever this script is: ~/repos/wekan on Linux,
|
|
# ~/Documents/repos/wekan on macOS, Downloads\repos\wekan on Windows.
|
|
REPO_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
|
# Usage: ./release-snap.sh 1.36
|
|
|
|
if [ "$#" -ne 1 ]; then
|
|
echo "Usage: ./release-snap.sh <version>"
|
|
exit 1
|
|
fi
|
|
|
|
# Cleanup
|
|
cd "$REPO_DIR/releases"
|
|
./release-cleanup.sh
|
|
|
|
# Build Source
|
|
cd "$REPO_DIR"
|
|
./releases/rebuild-release.sh
|
|
|
|
# Build Snap
|
|
cd "$REPO_DIR"
|
|
sudo snapcraft
|
|
|
|
# Cleanup
|
|
cd "$REPO_DIR"
|
|
./releases/release-cleanup.sh
|
|
|
|
# Push snap
|
|
cd "$REPO_DIR"
|
|
sudo snap install --dangerous wekan_$1_amd64.snap
|
|
echo "Now you can test local installed snap."
|
|
snapcraft push wekan_$1_amd64.snap
|
|
scp wekan_$1_amd64.snap x2:/var/www/releases.wekan.team/
|
|
mv wekan_$1_amd64.snap ..
|