Skip to main content

Python bindings for cfgcut, the deterministic configuration slicer

Project description

pycfgcut

Python bindings for cfgcut, the deterministic configuration slicer for network engineers.

Installation

pip install pycfgcut

pycfgcut ships prebuilt wheels for CPython 3.9 and newer on Linux and macOS. If a wheel is unavailable for your platform pip falls back to building from source; make sure a compatible Rust toolchain is installed (rustup recommended).

Usage

from pathlib import Path

from pycfgcut import run_cfg

fixture = Path("sample.conf")
result = run_cfg(["interfaces|>>|"], [str(fixture)], anonymize=True, tokens=True)

if result["matched"]:
    print(result["stdout"])

Refer to the cfgcut documentation for matcher semantics, anonymisation behaviour, and CLI parity guarantees.

License

pycfgcut is distributed under the terms of the MIT License. See the top-level LICENSE file in this repository for the full text.

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

pycfgcut-0.3.0.tar.gz (37.7 kB view details)

Uploaded Source

Built Distributions

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

pycfgcut-0.3.0-cp39-abi3-win_amd64.whl (799.1 kB view details)

Uploaded CPython 3.9+Windows x86-64

pycfgcut-0.3.0-cp39-abi3-manylinux_2_34_x86_64.whl (919.7 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.34+ x86-64

pycfgcut-0.3.0-cp39-abi3-macosx_11_0_arm64.whl (787.4 kB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

pycfgcut-0.3.0-cp39-abi3-macosx_10_12_x86_64.whl (845.4 kB view details)

Uploaded CPython 3.9+macOS 10.12+ x86-64

File details

Details for the file pycfgcut-0.3.0.tar.gz.

File metadata

  • Download URL: pycfgcut-0.3.0.tar.gz
  • Upload date:
  • Size: 37.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pycfgcut-0.3.0.tar.gz
Algorithm Hash digest
SHA256 e9e59880d904a5b299aad35d981ae3f99ecd78179706eaeab65898d64b50b30c
MD5 85842908f8560b70091a47820ba43596
BLAKE2b-256 b31ad06c88452cb1ff35dda14709c5c7849c1a151376733239447c92b678871e

See more details on using hashes here.

Provenance

The following attestation bundles were made for pycfgcut-0.3.0.tar.gz:

Publisher: release.yml on bedecarroll/cfgcut

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

File details

Details for the file pycfgcut-0.3.0-cp39-abi3-win_amd64.whl.

File metadata

  • Download URL: pycfgcut-0.3.0-cp39-abi3-win_amd64.whl
  • Upload date:
  • Size: 799.1 kB
  • Tags: CPython 3.9+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pycfgcut-0.3.0-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 f342997e94c892377f177e057dcc387039e8e387281f1934fe25071ee477b49b
MD5 b4724fc37ed44c6d3ffd4a8a185bbadd
BLAKE2b-256 297236089f88b959777dd9a5b77a258c3e680348b1248f4ff64ed6ee91ae8bc9

See more details on using hashes here.

Provenance

The following attestation bundles were made for pycfgcut-0.3.0-cp39-abi3-win_amd64.whl:

Publisher: release.yml on bedecarroll/cfgcut

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

File details

Details for the file pycfgcut-0.3.0-cp39-abi3-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for pycfgcut-0.3.0-cp39-abi3-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 790a3a80857bc664b9b811294b05feb5fd3f9bb9cdca63ccf27ba86040802520
MD5 fc6eab5732107fcb00e03897a1d88b2e
BLAKE2b-256 07be0abfa2ab9555771bc84effd94e57a174bf0c2467d9e9b838c9783aeb3d6f

See more details on using hashes here.

Provenance

The following attestation bundles were made for pycfgcut-0.3.0-cp39-abi3-manylinux_2_34_x86_64.whl:

Publisher: release.yml on bedecarroll/cfgcut

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

File details

Details for the file pycfgcut-0.3.0-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for pycfgcut-0.3.0-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 a12f79b6f82c0275df0b95258f57636c0235bea585cfe926d7f0821c17c574ae
MD5 de9932aa81cfa76f0cb2ad467695da9c
BLAKE2b-256 4696259afda65b60b437a548634c9a94d8a46f7c5176e609f8b216e1d741999e

See more details on using hashes here.

Provenance

The following attestation bundles were made for pycfgcut-0.3.0-cp39-abi3-macosx_11_0_arm64.whl:

Publisher: release.yml on bedecarroll/cfgcut

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

File details

Details for the file pycfgcut-0.3.0-cp39-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for pycfgcut-0.3.0-cp39-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 660b34c6da990e7413db3740a9cbe2f8420a7b41954f68080be88a7707afd2c4
MD5 1f10d7c9dbb8fa89360add4f8970decd
BLAKE2b-256 bc257e004b85b222dba79a92d2819f9f8bf746d3030c7dbc17c69297a23fea78

See more details on using hashes here.

Provenance

The following attestation bundles were made for pycfgcut-0.3.0-cp39-abi3-macosx_10_12_x86_64.whl:

Publisher: release.yml on bedecarroll/cfgcut

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