Skip to main content
# amani

#About

Amani is a way to patch configuration files.

#Install

pip install amani

#Usage

constants.py

class A:

a = 1
b = []
c = [1, 3, 5]

DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'maps',
'USER': 'root',
'PASSWORD': '',
'HOST': '',
'PORT': '3306',
}
}

try:
import amani
g = globals()
amani.patch(__file__, g)
except:
pass


patch_constants.py

PATCHES = [
["A", "a", 2],
["A", "b", ["test"]],
["A", "c", 1, 2**32],
["DATABASES", "default", "USER", "username"],
["DATABASES", "default", "PASSWORD", "pass-WORD"]
]

Download files

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

Source Distribution

amani-0.0.2.tar.gz (2.0 kB view details)

Uploaded Source

File details

Details for the file amani-0.0.2.tar.gz.

File metadata

  • Download URL: amani-0.0.2.tar.gz
  • Upload date:
  • Size: 2.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for amani-0.0.2.tar.gz
Algorithm Hash digest
SHA256 63f1a6acf74dbbcb52212950f2abb2e353ce19987c093af2201f227661dc0e8e
MD5 74fde7f45890ae2a5c78f94546892bff
BLAKE2b-256 64d39129a0e13b34b0b698110a86671c9504e3e8aa7ebb148ada5205484a2837

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.0.2 This release

1 file

0.0.1

1 file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page