Skip to main content

Change portions of static config files

Project description

Change portions of static config files

PyPI status drain-swamp coverage percentage License
last commit to gauge activity Test suite status Quality check status Documentation
Python versions supported implementations
platforms black
downloads GitHub stars
msftcangoblowme on Mastodon

* Python 3.9 through 3.13, PyPy

New in 1.0.x

integration with drain-swamp-action; all badges; docs to py310;

New in 0.0.x

move snip from package drain-swamp;

Whats a snippet?

Within a configuration, there are times when some bit of text needs to be changed.

The only requirement is the file format should recognize pound symbol # as a comment.

A snippet without an snippet code (id)

before snippet
# @@@ editable
code block
# @@@ end
after snippet

A snippet with an snippet code (id)

before snippet
# @@@ i_am_a_snippet_co
code block
# @@@ end
after snippet

[read more]

What batteries are included?

None

This is a base package. Other authors are encouraged to:

  • not reinvent the wheel

  • avoid packages with snippet implementations, when only just want the base class, Snip

Packages using drain-swamp-snippet-pypi

Acknowledgement

The technique and initial implementation is from Ned Batchelder

Ned Batchelder is also the author of cog which creates content by embedding both Python code and output in the original file.

Check out introduction to cog

Project details


Download files

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

Source Distribution

drain_swamp_snippet-1.0.2.tar.gz (72.5 kB view details)

Uploaded Source

Built Distribution

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

drain_swamp_snippet-1.0.2-py3-none-any.whl (38.4 kB view details)

Uploaded Python 3

File details

Details for the file drain_swamp_snippet-1.0.2.tar.gz.

File metadata

  • Download URL: drain_swamp_snippet-1.0.2.tar.gz
  • Upload date:
  • Size: 72.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for drain_swamp_snippet-1.0.2.tar.gz
Algorithm Hash digest
SHA256 4782b9d62ac5b0628573c366bd30ae9283ed432df0e2cef40bd5c048956715e0
MD5 262a695445986022c69641cce7e9296b
BLAKE2b-256 bb1ece6aa577129cbeec84b3bccb4c46eeda85e77b4309c8880bcaafad67ce56

See more details on using hashes here.

Provenance

The following attestation bundles were made for drain_swamp_snippet-1.0.2.tar.gz:

Publisher: release.yml on msftcangoblowm/drain-swamp-snippet

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file drain_swamp_snippet-1.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for drain_swamp_snippet-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 252b2b04eec9e71720b747a92c5b97a33da42776e9396ad898400ba92d4ca709
MD5 ff9eec7d58acd98eff6b26d4c4e912c4
BLAKE2b-256 0a2d2bf82eb5eaac66637b616a562bf4d7040616c19940fdfd400757ae8ed432

See more details on using hashes here.

Provenance

The following attestation bundles were made for drain_swamp_snippet-1.0.2-py3-none-any.whl:

Publisher: release.yml on msftcangoblowm/drain-swamp-snippet

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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