forked from stravu/crystal
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcom.stravu.crystal.yml
More file actions
59 lines (57 loc) · 2.01 KB
/
com.stravu.crystal.yml
File metadata and controls
59 lines (57 loc) · 2.01 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
# Flatpak manifest for Crystal
# To build: flatpak-builder --force-clean build-dir com.stravu.crystal.yml
app-id: com.stravu.crystal
runtime: org.freedesktop.Platform
runtime-version: '23.08'
sdk: org.freedesktop.Sdk
base: org.electronjs.Electron2.BaseApp
base-version: '23.08'
command: crystal
separate-locales: false
finish-args:
# X11 + XShm access
- --share=ipc
- --socket=x11
# Wayland access
- --socket=wayland
# GPU acceleration
- --device=dri
# Network access for Claude API
- --share=network
# File system access for projects
- --filesystem=home
# Notifications
- --talk-name=org.freedesktop.Notifications
# Required for Electron apps
- --socket=pulseaudio
- --talk-name=org.kde.StatusNotifierWatcher
modules:
- name: crystal
buildsystem: simple
build-commands:
# Install the pre-built AppImage
- install -D Crystal-*.AppImage /app/bin/crystal-appimage
- chmod +x /app/bin/crystal-appimage
# Extract the AppImage
- cd /app/bin && ./crystal-appimage --appimage-extract
- rm /app/bin/crystal-appimage
- mv /app/bin/squashfs-root /app/bin/crystal-app
# Create wrapper script
- |
cat > /app/bin/crystal <<EOF
#!/bin/bash
export TMPDIR="$XDG_RUNTIME_DIR/app/$FLATPAK_ID"
exec /app/bin/crystal-app/crystal "$@"
EOF
- chmod +x /app/bin/crystal
# Install desktop file
- install -Dm644 /app/bin/crystal-app/crystal.desktop /app/share/applications/com.stravu.crystal.desktop
- desktop-file-edit --set-key=Icon --set-value=com.stravu.crystal /app/share/applications/com.stravu.crystal.desktop
# Install icon
- install -Dm644 /app/bin/crystal-app/crystal.png /app/share/icons/hicolor/512x512/apps/com.stravu.crystal.png
sources:
- type: file
path: dist-electron/Crystal-*.AppImage
# This would be replaced with a URL in a real build:
# url: https://github.com/stravu/crystal/releases/download/vX.X.X/Crystal-X.X.X-x64.AppImage
# sha256: <sha256sum>