summaryrefslogtreecommitdiff
path: root/bin/build-distribution-archives
blob: 0fcadb594db79015f8d79884200d53b3e1b7af7e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/bash

VERSION="$(echo ${GITHUB_REF} | tr / -)"
OS="${BUILD:-$(uname)}"
ARCH="$(uname -m)"

cp -a images/examples palettes symbols fonts dist/inkstitch
cp -a icons locales print dist/inkstitch/bin

if [ "$BUILD" = "osx" ]; then
    cp -a electron/dist/mac dist/inkstitch/electron
else
    cp -a electron/dist/*-unpacked dist/inkstitch/electron
fi

mkdir artifacts

for d in inx/*; do
	lang=${d%.*}
	lang=${lang#*/}	
	cp $d/*.inx dist

    cd dist
    python -m zipfile -c ../artifacts/inkstitch-${VERSION}-${OS}-${lang}.zip *
	cd ..
done