Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Build flatpak package #4168

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,15 @@ jobs:
with:
name: chezmoi-windows-amd64
path: dist/chezmoi-nocgo_windows_amd64_v1/chezmoi.exe
- name: create-flatpak
if: github.event_name == 'push' || needs.changes.outputs.code == 'true'
run: |
sudo apt-get --no-install-suggests --no-install-recommends --quiet --yes install flatpak flatpak-builder
flatpak --version
flatpak-builder --version
flatpak remote-add --if-not-exists --user flathub https://dl.flathub.org/repo/flathub.flatpakrepo
flatpak-builder --force-clean --user --install-deps-from=flathub --repo=repo --install builddir io.chezmoi.chezmoi.yml
flatpak run io.chezmoi.chezmoi --version
test-ubuntu:
name: test-ubuntu-umask${{ matrix.umask }}-${{ matrix.test-index }}
strategy:
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/.flatpak-builder
/.vagrant
/COMMIT
/bin/actionlint
Expand All @@ -9,9 +10,11 @@
/bin/golangci-lint
/bin/goreleaser
/bin/goversioninfo
/builddir
/chezmoi
/chezmoi.exe
/coverage.out
/dist
/repo
/resource_windows_*.syso
/versioninfo.json
18 changes: 18 additions & 0 deletions io.chezmoi.chezmoi.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
id: io.chezmoi.chezmoi
runtime: org.freedesktop.Platform
runtime-version: '23.08'
sdk: org.freedesktop.Sdk
command: chezmoi
modules:
- name: chezmoi
buildsystem: simple
build-commands:
- install -Dm755 chezmoi /app/bin/chezmoi
sources:
- type: file
path: dist/chezmoi-cgo-glibc_linux_amd64_v1/chezmoi
finish-args:
- --share=network
- --filesystem=host
- --filesystem=host-etc
- --filesystem=host-os
Loading