-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sh
31 lines (20 loc) · 959 Bytes
/
build.sh
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
27
28
29
30
31
# This script uses PyInstaller to package the CircuitPython Bundle Manager v2
# Make sure to install everything you need in build-requirements.txt
# Build
# Hidden imports are from https://stackoverflow.com/a/53848300/10291933
pyinstaller main.py --name "CircuitPython_Bundle_Manager_v2" \
--icon="icon.ico" \
--noconfirm --clean \
--hidden-import="PIL" \
--hidden-import="PIL._imagingtk" \
--hidden-import="PIL._tkinter_finder" \
# Copy the necessary files
cp "LICENSE" "dist/CircuitPython_Bundle_Manager_v2"
cp "icon.png" "dist/CircuitPython_Bundle_Manager_v2"
# Set the binary as executable
cd dist/CircuitPython_Bundle_Manager_v2
chmod +x CircuitPython_Bundle_Manager_v2
# Get out of the directory
cd ..
# Compress the folder into a .tar.gz file for distribution
tar -czvf CircuitPython_Bundle_Manager_v2.tar.gz CircuitPython_Bundle_Manager_v2