Skip to content

Commit 7ee560b

Browse files
committed
Added builder script for Linux version
1 parent ebd5c98 commit 7ee560b

File tree

2 files changed

+30
-3
lines changed

2 files changed

+30
-3
lines changed

.github/workflows/appimage.yml

+1-3
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,9 @@ jobs:
2222
run: sudo pip3 install pyxel pyinstaller
2323
- name: build
2424
run: |
25-
pyxel package . ticoban.py
26-
pyxel app2exe ticoban-pyxel.pyxapp
25+
./build-linux.sh --appimage
2726
- name: Copy files
2827
run: |
29-
mkdir -p AppDir/usr/bin
3028
mkdir -p AppDir/usr/share/icons
3129
install -Dm755 ticoban-pyxel AppDir/usr/bin/ticoban
3230
install -Dm644 icon.png AppDir/usr/share/icons/ticoban.png

build-linux.sh

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
#!/bin/sh
2+
echo -e "\033[0;34mPreparing build folder\033[0m"
3+
if [ -d build_pyxapp ]; then rm -r build_pyxapp; fi
4+
mkdir -p build_pyxapp/levels
5+
cd build_pyxapp
6+
cp ../levels.py .
7+
cp ../rock.py .
8+
cp ../player.py .
9+
cp ../ticoban.py .
10+
cp ../levels/oficial.txt levels/
11+
cp ../assets.pyxres .
12+
cp ../assets.pyxpal .
13+
echo -e "\033[0;34mPackaging the game\033[0m"
14+
pyxel package . ticoban.py
15+
mv build_pyxapp.pyxapp ../ticoban-pyxel.pyxapp
16+
17+
echo -e "\033[0;34mMaking the executable\033[0m"
18+
pyxel app2exe ticoban-pyxel.pyxapp
19+
cd ..
20+
# rm -r build_pyxapp
21+
echo -e "\033[0;34mMaking the executable\033[0m"
22+
pyxel app2exe ticoban-pyxel.pyxapp
23+
24+
if [[ $# -eq 1 && $1 = '--appimage' ]]; then
25+
echo -e "\033[0;34mPreparing AppImage\033[0m"
26+
mkdir -p AppDir/usr/bin
27+
cp ticoban-pyxel AppDir/usr/bin/ticoban
28+
fi
29+
echo -e "\033[0;32mFinished\033[0m"

0 commit comments

Comments
 (0)