118 lines
4.3 KiB
YAML
118 lines
4.3 KiB
YAML
id: com.kompac.client
|
|
branch: stable
|
|
runtime: org.gnome.Platform
|
|
runtime-version: "50"
|
|
sdk: org.gnome.Sdk
|
|
command: komp-ac
|
|
|
|
sdk-extensions:
|
|
- org.freedesktop.Sdk.Extension.node22
|
|
- org.freedesktop.Sdk.Extension.rust-stable
|
|
|
|
finish-args:
|
|
- --share=ipc
|
|
- --share=network
|
|
- --socket=wayland
|
|
- --socket=fallback-x11
|
|
- --device=dri
|
|
- --env=GTK_USE_PORTAL=1
|
|
- --talk-name=org.a11y.Bus
|
|
|
|
build-options:
|
|
append-path: /usr/lib/sdk/node22/bin:/usr/lib/sdk/rust-stable/bin
|
|
|
|
modules:
|
|
- name: komp-ac
|
|
buildsystem: simple
|
|
build-options:
|
|
strip: true
|
|
no-debuginfo: true
|
|
build-args:
|
|
- --share=network
|
|
env:
|
|
HOME: /run/build/komp-ac
|
|
CARGO_HOME: /run/build/komp-ac/cargo-home
|
|
CARGO_TARGET_DIR: /run/build/komp-ac/target/server
|
|
COREPACK_HOME: /run/build/komp-ac/corepack
|
|
POSTGRESQL_VERSION: "=17.10.0"
|
|
PROTOC: /app/bin/protoc
|
|
PROTOC_INCLUDE: /app/include
|
|
RUSTFLAGS: ""
|
|
SQLX_OFFLINE: "true"
|
|
YARN_CACHE_FOLDER: /run/build/komp-ac/yarn-cache
|
|
sources:
|
|
- type: dir
|
|
path: ../..
|
|
skip:
|
|
- .git
|
|
- .agents
|
|
- .codex
|
|
- .codex-scheduled
|
|
- .direnv
|
|
- .env
|
|
- .env.*
|
|
- .env_*
|
|
- .envrc
|
|
- .idea
|
|
- .vscode
|
|
- "*.log"
|
|
- target
|
|
- "*/target"
|
|
- node_modules
|
|
- "*/node_modules"
|
|
- client-gui2/dist
|
|
- client-gui2/dist-ssr
|
|
- client-gui2/coverage
|
|
- client-gui2/.vite
|
|
- debian-dist
|
|
- flatpak-dist
|
|
- result
|
|
- result-*
|
|
- tantivy_indexes
|
|
- "*/tantivy_indexes"
|
|
- dumps
|
|
- "*/dumps"
|
|
- .postgres-data
|
|
- "*/.postgres-data"
|
|
- benchmark-results
|
|
- "*/benchmark-results"
|
|
- testing
|
|
- run_bins
|
|
- corporate_erp
|
|
- type: archive
|
|
url: https://github.com/protocolbuffers/protobuf/releases/download/v21.12/protoc-21.12-linux-x86_64.zip
|
|
sha256: 3a4c1e5f2516c639d3079b1586e703fc7bcfa2136d58bda24d1d54f949c315e8
|
|
dest: protoc-source
|
|
- type: file
|
|
url: https://github.com/theseus-rs/postgresql-binaries/releases/download/17.10.0/postgresql-17.10.0-x86_64-unknown-linux-gnu.tar.gz
|
|
sha256: 333937dac26a33d367810b0db20892bbca6cf244f670e26f54f3e0b57dcb50b6
|
|
dest: postgresql-cache
|
|
dest-filename: postgresql-17.10.0-x86_64-unknown-linux-gnu.tar.gz
|
|
- type: archive
|
|
url: https://github.com/typst/typst/releases/download/v0.13.1/typst-x86_64-unknown-linux-musl.tar.xz
|
|
sha256: 7d214bfeffc2e585dc422d1a09d2b144969421281e8c7f5d784b65fc69b5673f
|
|
dest: typst-source
|
|
build-commands:
|
|
- install -Dm755 protoc-source/protoc /app/bin/protoc
|
|
- install -d /app/include
|
|
- cp -a protoc-source/google /app/include/
|
|
- mkdir -p "$HOME/.theseus/postgresql"
|
|
- cp postgresql-cache/postgresql-17.10.0-x86_64-unknown-linux-gnu.tar.gz "$HOME/.theseus/postgresql/"
|
|
- cargo build --locked --release --package server --features full-embed
|
|
- cd client-gui2 && corepack yarn install --frozen-lockfile --non-interactive
|
|
- cd client-gui2 && CARGO_TARGET_DIR=/run/build/komp-ac/target/gui corepack yarn tauri build --no-bundle
|
|
- install -Dm755 /run/build/komp-ac/target/server/release/server /app/bin/komp-ac-server
|
|
- install -Dm755 /run/build/komp-ac/target/gui/release/client-gui2 /app/bin/client-gui2
|
|
- install -Dm755 packaging/flatpak/launcher.sh /app/bin/komp-ac
|
|
- install -Dm755 typst-source/typst /app/bin/typst
|
|
- install -d /app/lib/komp_ac/themes
|
|
- cp -a client/runtime/themes/. /app/lib/komp_ac/themes/
|
|
- install -Dm644 packaging/flatpak/com.kompac.client.desktop /app/share/applications/com.kompac.client.desktop
|
|
- install -Dm644 packaging/flatpak/com.kompac.client.metainfo.xml /app/share/metainfo/com.kompac.client.metainfo.xml
|
|
- install -Dm644 client-gui2/src-tauri/icons/32x32.png /app/share/icons/hicolor/32x32/apps/com.kompac.client.png
|
|
- install -Dm644 client-gui2/src-tauri/icons/128x128.png /app/share/icons/hicolor/128x128/apps/com.kompac.client.png
|
|
- install -Dm644 client-gui2/src-tauri/icons/128x128@2x.png /app/share/icons/hicolor/256x256/apps/com.kompac.client.png
|
|
cleanup:
|
|
- /bin/protoc
|
|
- /include
|