Skip to content
This repository was archived by the owner on Feb 16, 2025. It is now read-only.

Commit 9535140

Browse files
committed
doc: Write xfconf storage tutorial section
1 parent cf2702a commit 9535140

File tree

2 files changed

+59
-0
lines changed

2 files changed

+59
-0
lines changed

doc/tutorials/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ already somehow integrated with Elektra.
5353
- [Encrypt Configuration](crypto.md)
5454
- [Install Configuration Files](install-config-files.md)
5555
- [Write a specification for dockerd](dockerd-specification.md)
56+
- [Configure Xfconf Applications](xfconf.md)
5657

5758
## Elektra Developers
5859

doc/tutorials/xfconf.md

+58
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
# Using Xfconf with Elektra
2+
3+
Elektra provides the ability to work hand in hand with Xfconf.
4+
Depending on what you want, you can use Elektra in different ways.
5+
6+
## Altering Existing Xfconf Settings
7+
8+
Elektra provides an Xfconf storage plugin that allows you to change all the configuration settings made by Xfconf.
9+
10+
To access the properties which are owned by Xfconf, the appropriate channel must be mounted.
11+
Some known channel names are
12+
13+
- **Thunar**: thunar
14+
- **Xfwm**: xfwm4
15+
- **Xfce Panel**: xfce4-panel
16+
17+
Assuming that the properties of Thunar are to be changed, the following command can be used to mount the channel.
18+
19+
```shell
20+
kdb mount -R noresolver none /sw/xfce4/thunar xfconf channel=thunar
21+
```
22+
23+
**Warning**: The following operations will cause permanent changes to your system, please handle with care.
24+
25+
Thunar should now be ready to be configured by Elektra.
26+
For example, the following command can be used to use single clicks instead of double clicks.
27+
28+
```shell
29+
# Setting the value to `false` beforehand
30+
xfconf-query -c thunar -p /misc-single-click -s false -t bool -n
31+
32+
kdb set /sw/xfce4/thunar/misc-single-click TRUE
33+
#> Set string to "TRUE"
34+
#> Using name dir:/sw/xfce4/thunar/misc-single-click
35+
```
36+
37+
The result can then be verified using both Elektra and `xfconf-query`.
38+
39+
```shell
40+
kdb get /sw/xfce4/thunar/misc-single-click
41+
#> TRUE
42+
43+
xfconf-query -c thunar -p /misc-single-click
44+
#> true
45+
```
46+
47+
Using a text editor, you can also view the changes in the
48+
file `${XDG_CONFIG_HOME:-$HOME/.config}/xfce4/xfconf/xfce-perchannel-xml/thunar.xml`.
49+
50+
When you are finished configuring the Xfce component, you should unmount the corresponding channel with the following command.
51+
52+
```shell
53+
kdb umount /sw/xfce4/thunar/
54+
```
55+
56+
## Replacing Xfconf with Elektra
57+
58+
## Data-Types Used in Xfconf

0 commit comments

Comments
 (0)