community.general.xfconf module – Edit XFCE4 Configurations
Note
This module is part of the community.general collection (version 4.8.3).
You might already have this collection installed if you are using the ansible
package.
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install community.general
.
To use it in a playbook, specify: community.general.xfconf
.
Synopsis
This module allows for the manipulation of Xfce 4 Configuration with the help of xfconf-query. Please see the xfconf-query(1) man pages for more details.
Parameters
Parameter |
Comments |
---|---|
A Xfconf preference channel is a top-level tree key, inside of the Xfconf repository that corresponds to the location for which all application properties/keys are stored. See man xfconf-query(1) |
|
The value This option will be deprecated in a future version, and eventually be removed. Choices:
|
|
Force array even if only one element Choices:
|
|
A Xfce preference key is an element in the Xfconf repository that corresponds to an application preference. See man xfconf-query(1) |
|
The action to take upon the property/value. State Choices:
|
|
Preference properties typically have simple values such as strings, integers, or lists of strings and integers. This is ignored if the state is “get”. For array mode, use a list of values. See man xfconf-query(1) |
|
The type of value being set. This is ignored if the state is “get”. When providing more than one value_type, the length of the list must be equal to the length of value. If only one value_type is provided, but value contains more than on element, that value_type will be applied to all elements of value. If the property being set is an array and it can possibly have ony one element in the array, then force_array=true must be used to ensure that Support for Choices:
|
See Also
See also
- C(xfconf-query) man page
Manual page of the
xfconf-query
tool at the XFCE documentation site.- xfconf - Configuration Storage System
XFCE documentation for the Xfconf configuration system.
Examples
- name: Change the DPI to "192"
xfconf:
channel: "xsettings"
property: "/Xft/DPI"
value_type: "int"
value: "192"
- name: Set workspace names (4)
xfconf:
channel: xfwm4
property: /general/workspace_names
value_type: string
value: ['Main', 'Work1', 'Work2', 'Tmp']
- name: Set workspace names (1)
xfconf:
channel: xfwm4
property: /general/workspace_names
value_type: string
value: ['Main']
force_array: true
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
The channel specified in the module parameters Returned: success Sample: “xsettings” |
|
The value of the preference key before executing the module ( This is a string or a list of strings. Returned: success Sample: “\”96\” or [\”red\”, \”blue\”, \”green\”]” |
|
The property specified in the module parameters Returned: success Sample: “/Xft/DPI” |
|
The value of the preference key after executing the module. Either a single string value or a list of strings for array types. This is a string or a list of strings. Returned: success Sample: “\”192\” or [\”orange\”, \”yellow\”, \”violet\”]” |
|
The type of the value that was changed ( This is a string or a list of strings. Returned: success Sample: “\”int\” or [\”str\”, \”str\”, \”str\”]” |
Authors
Joseph Benden (@jbenden)
Alexei Znamensky (@russoz)
Collection links
Issue Tracker Repository (Sources) Submit a bug report Request a feature Communication