-
-
Notifications
You must be signed in to change notification settings - Fork 72
Remove duplicate buttons using xfconf-query #256
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
Open
noskb
wants to merge
1
commit into
QubesOS:main
Choose a base branch
from
noskb:qubes-xfconf
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+13
−1
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
appvm-scripts/etc/xdgautostart/qubes-set-xsettings-xfconf-query.desktop
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| [Desktop Entry] | ||
| Version=1.0 | ||
| Encoding=UTF-8 | ||
| Name=xfconf-query for Xfce-based QubesVM | ||
| Exec=/usr/bin/xfconf-query --channel xsettings --property /Gtk/DecorationLayout --set "" | ||
| Terminal=false | ||
| Type=Application | ||
| OnlyShowIn=X-QUBES; | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1,2 @@ | ||
| etc/X11/Xsession.d/60xfce-desktop | ||
| etc/X11/Xsession.d/60xfce-desktop | ||
| etc/xdg/autostart/qubes-set-xsettings-xfconf-query.desktop |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is assuming that the qube:
xfconf-queryBoth conditions need to be met for this script to be called.
First, can be done with
TryExec=/usr/bin/xfconf-query. Also, I'd rather the path was not hardcoded.Second,
XDG_SESSION_DESKTOP=X-QUBESis present onfedora-43-minimal, which is not the Xfce flavor and doesn't havexfconf-query. So you will need to find another thing to query.Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your review.
Since this won't take effect unless the
qubes-gui-agent-xfceis installed, I think it's reasonable to assume thatxfconf-queryexists. That’s why I didn’t useTryExec=, but I wonder if I’m missing something.agree.
Since minimal template is intended for advanced users, I hadn't considered it.
I expect the same thing is possible by adding
xsettingsdto thequbes-gui-agentpackage dependencies and placing the configuration file in its proper location, but I’m hesitant to add anything by default to minimal template, which is for advanced users who prefer minimizing things…Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For advanced users to configure, doesn't mean things should be broken. I don't know if this breaks systemd somehow if it is configured to handle xdg autostart. But I'd rather that it is not left in a failed state, but skipped.
No need to add the package. It doesn't guarantee that xfce is currently running. Please find a way to know if Xfce is currently running and add that as a check to
TryExec=.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To explain this better, minimal templates don't have everything working by default, I just don't want a failed state by default.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it really needed to check whether Xfce is currently running here?
All environment variables recommended for checking whether XFCE (DE) is currently running are override by
60xfce-desktopincluded in thequbes-gui-agent-xfcepackage, so as I see it, if the package is installed, Xfce is assumed to be running. Furthermore,xfconf-querydoes not fail even if Xfce is not running. But,--setalone will fail if the channel or property does not exist, so adding--createis planned.`)With this change, it should no longer default to a failed state. (for example, even in a unique environment where only
xfconfandqubes-gui-agent-xfcepackages are installed on minimal template)