fix: add media appmenus

This commit is contained in:
Ben Grande 2024-07-19 15:14:40 +02:00
parent 3b6901b5d2
commit 5d6a50c286
No known key found for this signature in database
GPG Key ID: 00C64E14F51F9E56
6 changed files with 48 additions and 5 deletions

View File

@ -37,7 +37,9 @@ Requires: qusal-utils
%description %description
Creates the offline "media" qube for storing multimedia files and open the Creates the offline "media" qube for storing multimedia files and open the
files in a named disposable "disp-media" via MIME configuration. files in a named disposable "disp-media" via MIME configuration. You can also
connect any disposable qube based on "dvm-media" to a netvm and gather media
over the network.
%prep %prep
%setup -q %setup -q
@ -76,6 +78,7 @@ if test "$1" = "1"; then
qubesctl state.apply media.create qubesctl state.apply media.create
qubesctl --skip-dom0 --targets=tpl-media state.apply media.install qubesctl --skip-dom0 --targets=tpl-media state.apply media.install
qubesctl --skip-dom0 --targets=media state.apply media.configure qubesctl --skip-dom0 --targets=media state.apply media.configure
qubesctl state.apply media.appmenus
elif test "$1" = "2"; then elif test "$1" = "2"; then
## Upgrade ## Upgrade
true true

View File

@ -12,7 +12,9 @@ Media opener through disposables in Qubes OS.
## Description ## Description
Creates the offline "media" qube for storing multimedia files and open the Creates the offline "media" qube for storing multimedia files and open the
files in a named disposable "disp-media" via MIME configuration. files in a named disposable "disp-media" via MIME configuration. You can also
connect any disposable qube based on "dvm-media" to a netvm and gather media
over the network.
## Installation ## Installation
@ -22,6 +24,7 @@ files in a named disposable "disp-media" via MIME configuration.
sudo qubesctl top.enable media sudo qubesctl top.enable media
sudo qubesctl --targets=tpl-media,media state.apply sudo qubesctl --targets=tpl-media,media state.apply
sudo qubesctl top.disable media sudo qubesctl top.disable media
sudo qubesctl state.apply media.appmenus
``` ```
* State: * State:
@ -32,6 +35,7 @@ sudo qubesctl top.disable media
sudo qubesctl state.apply media.create sudo qubesctl state.apply media.create
sudo qubesctl --skip-dom0 --targets=tpl-media state.apply media.install sudo qubesctl --skip-dom0 --targets=tpl-media state.apply media.install
sudo qubesctl --skip-dom0 --targets=media state.apply media.configure sudo qubesctl --skip-dom0 --targets=media state.apply media.configure
sudo qubesctl state.apply media.appmenus
``` ```
<!-- pkg:end:post-install --> <!-- pkg:end:post-install -->

8
salt/media/appmenus.sls Normal file
View File

@ -0,0 +1,8 @@
{#
SPDX-FileCopyrightText: 2023 Benjamin Grande M. S. <ben.grande.b@gmail.com>
SPDX-License-Identifier: AGPL-3.0-or-later
#}
{% from 'utils/macros/sync-appmenus.sls' import sync_appmenus -%}
{{ sync_appmenus('tpl-' ~ sls_path) }}

10
salt/media/appmenus.top Normal file
View File

@ -0,0 +1,10 @@
{#
SPDX-FileCopyrightText: 2023 Benjamin Grande M. S. <ben.grande.b@gmail.com>
SPDX-License-Identifier: AGPL-3.0-or-later
#}
base:
'dom0':
- match: nodegroup
- media.appmenus

View File

@ -19,6 +19,12 @@ require:
- sls: {{ slsdotpath }}.clone - sls: {{ slsdotpath }}.clone
prefs: prefs:
- audiovm: "" - audiovm: ""
features:
- set:
# editorconfig-checker-disable
- default-menu-items: "calibre-ebook-edit.desktop calibre-ebook-viewer.desktop calibre-gui.desktop calibre-lrfviewer.desktop chromium.desktop gpicview.desktop mpv.desktop org.xfce.mousepad.desktop vlc.desktop xpdf.desktop qubes-run-terminal.desktop qubes-start.desktop" # noqa: 204
- menu-items: "calibre-ebook-edit.desktop calibre-ebook-viewer.desktop calibre-gui.desktop calibre-lrfviewer.desktop chromium.desktop gpicview.desktop mpv.desktop org.xfce.mousepad.desktop vlc.desktop xpdf.desktop qubes-run-terminal.desktop qubes-start.desktop" # noqa: 204
# editorconfig-checker-enable
{%- endload %} {%- endload %}
{{ load(defaults) }} {{ load(defaults) }}
@ -47,6 +53,8 @@ features:
- service.tinyproxy - service.tinyproxy
- service.tracker - service.tracker
- service.evolution-data-server - service.evolution-data-server
- set:
- menu-items: "qubes-run-terminal.desktop qubes-start.desktop"
{%- endload %} {%- endload %}
{{ load(defaults) }} {{ load(defaults) }}
@ -69,12 +77,18 @@ prefs:
- template_for_dispvms: True - template_for_dispvms: True
- include_in_backups: False - include_in_backups: False
features: features:
- enable:
- appmenus-dispvm
- disable: - disable:
- service.cups - service.cups
- service.cups-browsed - service.cups-browsed
- service.tinyproxy - service.tinyproxy
- service.tracker - service.tracker
- service.evolution-data-server - service.evolution-data-server
- set:
# editorconfig-checker-disable
- menu-items: "calibre-ebook-edit.desktop calibre-ebook-viewer.desktop calibre-gui.desktop calibre-lrfviewer.desktop chromium.desktop gpicview.desktop mpv.desktop org.xfce.mousepad.desktop vlc.desktop xpdf.desktop qubes-run-terminal.desktop qubes-start.desktop" # noqa: 204
# editorconfig-checker-enable
{%- endload %} {%- endload %}
{{ load(defaults) }} {{ load(defaults) }}
@ -98,15 +112,18 @@ prefs:
- autostart: False - autostart: False
- include_in_backups: False - include_in_backups: False
features: features:
- appmenus-dispvm: True - enable:
- service.shutdown-idle
- disable: - disable:
- service.cups - service.cups
- service.cups-browsed - service.cups-browsed
- service.tinyproxy - service.tinyproxy
- service.tracker - service.tracker
- service.evolution-data-server - service.evolution-data-server
- enable: - set:
- service.shutdownle # editorconfig-checker-disable
- menu-items: "calibre-ebook-edit.desktop calibre-ebook-viewer.desktop calibre-gui.desktop calibre-lrfviewer.desktop chromium.desktop gpicview.desktop mpv.desktop org.xfce.mousepad.desktop vlc.desktop xpdf.desktop qubes-run-terminal.desktop qubes-start.desktop" # noqa: 204
# editorconfig-checker-enable
{%- endload %} {%- endload %}
{{ load(defaults) }} {{ load(defaults) }}

View File

@ -29,6 +29,7 @@ include:
- gpicview - gpicview
- mousepad - mousepad
- mpv - mpv
- yt-dlp
- vlc - vlc
- xpdf - xpdf
- man-db - man-db