Repository navigation
Expand file tree
/
Copy pathai.opencode.opencode.yml
More file actions
87 lines (84 loc) · 3.06 KB
/
Copy pathai.opencode.opencode.yml
File metadata and controls
87 lines (84 loc) · 3.06 KB
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
id: ai.opencode.opencode
runtime: org.freedesktop.Platform
runtime-version: '26.08'
sdk: org.freedesktop.Sdk
sdk-extensions:
- org.freedesktop.Sdk.Extension.rust-stable
base: org.electronjs.Electron2.BaseApp
base-version: '26.08'
command: run.sh
rename-desktop-file: ai.opencode.desktop.desktop
rename-icon: ai.opencode
finish-args:
- --share=ipc
- --socket=fallback-x11
- --socket=wayland
- --socket=pulseaudio
- --device=dri
- --share=network
- --filesystem=home
- --filesystem=/media
- --filesystem=/mnt
- --filesystem=/run/media
- --talk-name=org.freedesktop.Flatpak
- --env=ELECTRON_TRASH=gio
- --env=XCURSOR_PATH=/run/host/user-share/icons:/run/host/share/icons
modules:
- name: git
build-options:
append-path: /usr/lib/sdk/rust-stable/bin
cleanup:
- /share
make-args:
- NO_PERL=1
- NO_TCLTK=1
make-install-args:
- INSTALL_SYMLINKS=1
- NO_PERL=1
- NO_TCLTK=1
sources:
- type: archive
url: https://www.kernel.org/pub/software/scm/git/git-2.56.1.tar.gz
sha256: fd0c0495427dc9ac445fdced8e36bb5eb6f233a14da5db3c6dfd8dcfa7f85761
x-checker-data:
type: anitya
project-id: 5350
url-template: https://www.kernel.org/pub/software/scm/git/git-$version.tar.gz
- name: opencode
buildsystem: simple
build-options:
# flatpak-builder's debuginfo phase runs eu-strip on every ELF file,
# which rewrites opencode-cli and drops Bun's appended payload: the
# result is a plain bun binary ("Script not found" for every command,
# bun's version for --version). Disable the phase for this module.
no-debuginfo: true
build-commands:
- ar x opencode-desktop-linux*.deb
- tar xf data.tar.xz
- patch -p1 < metainfo.patch
- mv opt/* /app/main
- rm /app/main/chrome-sandbox
- mv usr/share/applications usr/share/icons /app/share
- desktop-file-edit --set-key Exec --set-value "run.sh %U" /app/share/applications/ai.opencode.desktop.desktop
- patch-electron-desktop-filename /app/main/resources/app.asar
- install -Dm644 usr/share/metainfo/ai.opencode.desktop.metainfo.xml /app/share/metainfo/ai.opencode.opencode.metainfo.xml
- install -Dm755 -t /app/bin run.sh
sources:
- type: file
only-arches: [x86_64]
url: https://opencode.ai/files/bin/2.4.4/opencode-desktop-linux-amd64.deb
sha256: dcc684f49be67ac939035d0f0ba4ea25292b06962ece6a159e359537f5573217
x-checker-data:
type: rotating-url
url: https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-linux-amd64.deb
- type: file
only-arches: [aarch64]
url: https://opencode.ai/files/bin/2.4.4/opencode-desktop-linux-arm64.deb
sha256: 079bbe9d5deccbc19308e5de50eaffaedc567edf62356774b97872b0a9cc9fb1
x-checker-data:
type: rotating-url
url: https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-linux-arm64.deb
- type: file
path: run.sh
- type: file
path: metainfo.patch