Skip to main content

A utility for safely making updates to XML configuration files.

Project description

xml-safe-mod

A small utility for safely making updates to XML configuration files.

It aims to give a safer alternative to using sed when updating XML configuration files, both by avoiding leaking secrets and by making the updates themselves safe and atomic.

Usage

# In-place update
echo '{"secret1": "password1"}' | xml-safe-mod --src /etc/daemon/config.xml --in-place --set secret1 ./xpath/expression
# Use a template file to generate another file
echo '{"secret1": "password1"}' | xml-safe-mod --src /etc/daemon/config.xml.in --dest /etc/daemon/config.xml --owner daemon --group daemon --perms 600 --set secret1 ./xpath/expression

It would support the ElementTree subset of XPath.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

xml_safe_mod-0.1.0-py3-none-any.whl (4.0 kB view details)

Uploaded Python 3

File details

Details for the file xml_safe_mod-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: xml_safe_mod-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 4.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.2

File hashes

Hashes for xml_safe_mod-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 23bc4980b85ae49404856c66a05a700663b9d253e385d6e68509a0b62c48dbbf
MD5 f27bd7e8c43fc559f3fbff085cb40cfa
BLAKE2b-256 2ddec7ce5fa85175dc4aad5ac5d4ca0628ea6b9ee6d33debd88db0f7a1f062ae

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page