-
Notifications
You must be signed in to change notification settings - Fork 6
/
me.proton.Pass.yml
97 lines (91 loc) · 3.99 KB
/
me.proton.Pass.yml
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
88
89
90
91
92
93
94
95
96
97
app-id: me.proton.Pass
runtime: org.freedesktop.Platform
runtime-version: &runtime-version '24.08'
sdk: org.freedesktop.Sdk
base: org.electronjs.Electron2.BaseApp
base-version: *runtime-version
command: start-proton-pass
finish-args:
- --share=ipc
- --share=network
- --socket=wayland
- --socket=fallback-x11
- --device=all
# DBus-based libsecret
- --talk-name=org.freedesktop.secrets
# Tray icon
- --talk-name=org.kde.StatusNotifierWatcher
- --env=ELECTRON_OZONE_PLATFORM_HINT=auto
- --env=XCURSOR_PATH=~/.icons:/app/share/icons:/icons:/run/host/user-share/icons:/run/host/share/icons
modules:
# fix auto logout
# https://github.com/flathub/org.signal.Signal/pull/756/commits/2caf105b18f906e7707f67b3cf7384a21f461564
- name: libsecret
buildsystem: meson
config-opts:
- -Dmanpage=false
- -Dcrypto=disabled
- -Dvapi=false
- -Dgtk_doc=false
- -Dintrospection=false
- -Dbash_completion=disabled
cleanup:
- /bin
- /include
- /lib/pkgconfig
- /share/man
sources:
- type: archive
url: https://download.gnome.org/sources/libsecret/0.21/libsecret-0.21.4.tar.xz
sha256: 163d08d783be6d4ab9a979ceb5a4fecbc1d9660d3c34168c581301cd53912b20
x-checker-data:
type: gnome
name: libsecret
stable-only: true
- name: proton-pass
buildsystem: simple
build-commands:
- bsdtar -Oxf ProtonPass.deb data.tar.xz | bsdtar -xf -
- mv "usr/lib/proton-pass" ${FLATPAK_DEST}/proton-pass
# To allow separate locales
# https://searchfox.org/mozilla-central/rev/8a4f55bc09ffc5c25dcb4586c51ae4a9fee77b4c/taskcluster/docker/firefox-flatpak/runme.sh#131-133
- |
for lang in ${FLATPAK_DEST}/proton-pass/locales/*.pak
do
locale="$(basename -s .pak $lang)"
install -Dm644 -t "${FLATPAK_DEST}/share/runtime/locale/${locale%%-*}/" "$lang"
ln -sf "${FLATPAK_DEST}/share/runtime/locale/${locale%%-*}/$(basename $lang)" "${FLATPAK_DEST}/proton-pass/locales/$(basename $lang)"
done
- install -Dm644 proton-pass.svg "${FLATPAK_DEST}/share/icons/hicolor/scalable/apps/${FLATPAK_ID}.svg"
- install -Dm644 usr/share/applications/proton-pass.desktop "${FLATPAK_DEST}/share/applications/${FLATPAK_ID}.desktop"
- desktop-file-edit --set-key=Exec --set-value='start-proton-pass %U' --set-icon=${FLATPAK_ID}
"${FLATPAK_DEST}/share/applications/${FLATPAK_ID}.desktop"
# Fix icon image
- patch-desktop-filename "${FLATPAK_DEST}/proton-pass/resources/app.asar"
# Install the wrapper script to start it.
- install -Dm 755 start-proton-pass.sh /app/bin/start-proton-pass
- install -Dm644 me.proton.Pass.metainfo.xml /app/share/metainfo/$FLATPAK_ID.metainfo.xml
sources:
- type: file
dest-filename: ProtonPass.deb
only-arches: [x86_64]
url: https://proton.me/download/pass/linux/proton-pass_1.25.0_amd64.deb
# The upstream publishes sha512sum
sha512: aa1bb99b594210abf861c6767dbee09f1fdc6f784f82e9ad2323ae6a0f2df311020c66f1c22caafb2760b207d27f57f9bac7fd1764939c9951b09caad765751d
x-checker-data:
type: json
# https://github.com/ProtonMail/WebClients/blob/d1a23fc2c4ab1e1632118baaee6f2531022ae4cf/applications/pass-desktop/tools/deploy.sh#L127
url: https://proton.me/download/PassDesktop/linux/x64/version.json
version-query: .Releases[0].Version
url-query: .Releases[0].File[0].Url
is-main-source: true
- type: file
dest-filename: proton-pass.svg
url: https://raw.githubusercontent.com/ProtonMail/WebClients/d1a23fc2c4ab1e1632118baaee6f2531022ae4cf/applications/pass-desktop/assets/logo.svg
sha256: 485abebe08af491753b9060c539f012c2c0a8d20a1e559d42f623c281ed691b9
- type: script
dest-filename: start-proton-pass.sh
commands:
- exec zypak-wrapper "/app/proton-pass/Proton Pass" "$@"
- type: file
path: me.proton.Pass.metainfo.xml