File tree Expand file tree Collapse file tree 5 files changed +86
-56
lines changed
Expand file tree Collapse file tree 5 files changed +86
-56
lines changed Original file line number Diff line number Diff line change @@ -22,14 +22,14 @@ jobs:
2222 uses : actions/checkout@v4
2323
2424 - name : Setup Build Env
25- run : ./setup-env .sh
25+ run : ./setup.sh
2626
2727 - name : Build Ghostty
28- run : just setup compile extract
28+ run : ./build.sh
2929
3030 - name : Upload Artifact
3131 uses : actions/upload-artifact@v4
3232 with :
3333 name : Ghostty_AppImage
3434 retention-days : 7
35- path : Ghostty-*.AppImage
35+ path : /tmp/ghostty-build/ Ghostty-*.AppImage
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ set -e
4+
5+ GHOSTTY_VERSION=" 1.0.1"
6+ TMP_DIR=" /tmp/ghostty-build"
7+ APP_DIR=" ${TMP_DIR} /ghostty.AppDir"
8+ PUB_KEY=" RWQlAjJC23149WL2sEpT/l0QKy7hMIFhYdQOFy0Z7z7PbneUgvlsnYcV"
9+
10+ rm -rf " ${TMP_DIR} "
11+
12+ mkdir -p -- " ${TMP_DIR} " " ${APP_DIR} /usr"
13+
14+ cd " ${TMP_DIR} "
15+
16+ wget -q " https://release.files.ghostty.org/${GHOSTTY_VERSION} /ghostty-${GHOSTTY_VERSION} .tar.gz"
17+ wget -q " https://release.files.ghostty.org/${GHOSTTY_VERSION} /ghostty-${GHOSTTY_VERSION} .tar.gz.minisig"
18+
19+ minisign -V -m " ghostty-${GHOSTTY_VERSION} .tar.gz" -P " ${PUB_KEY} " -s " ghostty-${GHOSTTY_VERSION} .tar.gz.minisig"
20+
21+ rm ghostty-${GHOSTTY_VERSION} .tar.gz.minisig
22+
23+ tar -xzmf " ghostty-${GHOSTTY_VERSION} .tar.gz"
24+
25+ rm " ghostty-${GHOSTTY_VERSION} .tar.gz"
26+
27+ cd " ${TMP_DIR} /ghostty-${GHOSTTY_VERSION} "
28+
29+ sed -i ' s/linkSystemLibrary2("bzip2", dynamic_link_opts)/linkSystemLibrary2("bz2", dynamic_link_opts)/' build.zig
30+
31+ # Fetch Zig Cache
32+ ZIG_GLOBAL_CACHE_DIR=/tmp/offline-cache ./nix/build-support/fetch-zig-cache.sh
33+
34+ # Build Ghostty with zig
35+ zig build \
36+ --summary all \
37+ --prefix " ${APP_DIR} /usr" \
38+ --system /tmp/offline-cache/p \
39+ -Doptimize=ReleaseFast \
40+ -Dcpu=baseline \
41+ -Dpie=true \
42+ -Demit-docs \
43+ -Dversion-string=" ${GHOSTTY_VERSION} "
44+
45+ cd " ${APP_DIR} "
46+
47+ # prep appimage
48+ printf ' #!/bin/sh\n\nexec "$(dirname "$(readlink -f "$0")")/usr/bin/ghostty"\n' | tee AppRun > /dev/null
49+ chmod +x AppRun
50+ ln -s usr/share/applications/com.mitchellh.ghostty.desktop
51+ ln -s usr/share/icons/hicolor/256x256/apps/com.mitchellh.ghostty.png
52+
53+ cd " ${TMP_DIR} "
54+ # create app image
55+ ARCH=x8_64 appimagetool " ${APP_DIR} "
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ set -e
4+
5+ ZIG_VERSION=" 0.13.0"
6+
7+ # update & install os base dependencies
8+ buildPkgs=" build-essential libonig-dev libbz2-dev lintian lsb-release pandoc git wget"
9+ ghosttyPkgs=" libgtk-4-dev libadwaita-1-dev"
10+ apt-get -qq update && apt-get -qq -y upgrade && apt-get -qq -y --no-install-recommends install $buildPkgs $ghosttyPkgs
11+
12+ # download & install other dependencie
13+ # appimagetool: https://github.com/AppImage/appimagetool
14+ wget -q " https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-x86_64.AppImage"
15+ install appimagetool-x86_64.AppImage /usr/local/bin/appimagetool
16+ rm appimagetool-x86_64.AppImage
17+
18+ # minisign: https://github.com/jedisct1/minisign
19+ wget -q " https://github.com/jedisct1/minisign/releases/download/0.11/minisign-0.11-linux.tar.gz"
20+ tar -xzf minisign-0.11-linux.tar.gz
21+ mv minisign-linux/x86_64/minisign /usr/local/bin
22+ rm -r minisign-0.11-linux.tar.gz
23+
24+ # zig: https://ziglang.org
25+ wget -q " https://ziglang.org/download/$ZIG_VERSION /zig-linux-x86_64-$ZIG_VERSION .tar.xz"
26+ tar -xf " zig-linux-x86_64-$ZIG_VERSION .tar.xz" -C /opt
27+ rm " zig-linux-x86_64-$ZIG_VERSION .tar.xz"
28+ ln -s " /opt/zig-linux-x86_64-$ZIG_VERSION /zig" /usr/local/bin/zig
You can’t perform that action at this time.
0 commit comments