Dconf Json
Convert linux gnome config to json and back
To get the gnome .conf file use:
dconf dump / > FILENAME.conf
Example usage to convert conf and store as json file and take json and store as conf file
import dconfjson
dconfjson.json_writer("FILENAME.conf", dest="FILENAME.json")
dconfjson.dconf_writer("FILENAME.json", dest="FILENAME_2.conf")
To load new dconf parameters into gnome use (bash):
dconf load / < FILENAME_2.conf
To get the gnome config out as a python dict use:
import dconfjson
with open(dconf_path, "rb") as fin:
dconf = fin.read().decode("utf-8")
config_dict = dconfjson.dconf_json(dconf)
Without using files
To get the dconf out as dict without using files:
import dconfjson
import subprocess
def dconf_get():
spath = "/org/gnome/terminal/legacy/profiles:/"
cmd = "dconf dump %s /" % spath
tmp = subprocess.Popen( cmd, shell=True, stdout=subprocess.PIPE )
(out, err) = tmp.communicate()
return out
s_out = dconf_get().decode("utf-8")
config_dict = dconfjson.dconf_json(s_out)
Metadata
Release files for dconfjson 0.2.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| dconfjson-0.2.4.tar.gz | 4.0 kB | Without provenance | Details for dconfjson-0.2.4.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| dconfjson-0.2.4-py3-none-any.whl | Python 3 | none | any | Details for dconfjson-0.2.4-py3-none-any.whl |
Total release size: 8.9 kB
Release files / dconfjson-0.2.4.tar.gz
| Download URL | dconfjson-0.2.4.tar.gz |
|---|---|
| Size | 4.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
15e7494641df6b3346e38de02a355d755906672650efee2f28c2012feec9e444
|
|
BLAKE2b-256 checksum How to use checksums |
a9a3294e3a72f7398d083ebecfa6a17a31f92eea0a141a96ece755e3f740a40c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.16
|
Release files / dconfjson-0.2.4-py3-none-any.whl
| Download URL | dconfjson-0.2.4-py3-none-any.whl |
|---|---|
| Size | 4.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8611738919dcfa4af93072304b5604a2c49ab1d75b7c4f73d0bf68f3badc6f94
|
|
BLAKE2b-256 checksum How to use checksums |
f46ade979ef2ea3eab606f89d1e7050d8d7635217b164341321464d114f3f324
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.16
|
Security for dconfjson 0.2.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.