Skip to main content

A utility for making log files (particularly Terraform logs) more readable and comparable

Project description

readable

Remove 'cruft' from log files to make them easier to read and compare.

Can remove times, dates, hashes and has options to remove a lot of the 'noise' that Terraform generates and tidy up the output.

readable [-h] [--light] [--dark] [--none] [--tidy] [--strip-blank] [--debug] [--out] [--dir DIR] [--aws] [--terraform] [--replace REPLACE] [--verbose] [--minimal] [--non-minimal]
                [files ...]

positional arguments:
  files                 The files to convert (use stdin/stout if no input files are specified)

options:
  -h, --help            show this help message and exit
  --light, -l           Modify colours for a light background (the default)
  --dark, -d            Modify colours for a dark background
  --none, -n            Remove all colour codes
  --tidy, -t            Remove colour codes and stuff that typically occurs in log files causing diffs, but is of no particular interest (e.g. SHA1 values, times, dates)
  --strip-blank, -s     Strip all blank lines
  --debug, -D           Replace colours with debug information
  --out, -o             Output to standard output rather than overwriting input files
  --dir DIR, -O DIR     Store output files in the specified directory (creating it if it doesn't exist)
  --aws, -a             Remove AWS resource IDs
  --terraform, -T       Clean Terraform plan/apply log files
  --replace REPLACE, -R REPLACE
                        Additional regex replacements in the form "REGEX=REPLACEMENT"
  --verbose, -v         Output verbose status
  --minimal, -m         Remove unnecessary data from the file (e.g. Terraform progress updates (Refreshing..., Reading..., etc.))
  --non-minimal, -M     Do not remove unnecessary data from the file (e.g. Terraform progress updates (Refreshing..., Reading..., etc.))

TODO: -A option to enable tidy, aws, terraform, minimal options

TODO: Pick up default options from READABLE_OPTS environment var.

TODO: --not- options to allow defaults in READABLE_OPTS to be overridded

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

skilleter_readable-0.0.1.tar.gz (20.6 kB view details)

Uploaded Source

Built Distribution

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

skilleter_readable-0.0.1-py3-none-any.whl (21.7 kB view details)

Uploaded Python 3

File details

Details for the file skilleter_readable-0.0.1.tar.gz.

File metadata

  • Download URL: skilleter_readable-0.0.1.tar.gz
  • Upload date:
  • Size: 20.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for skilleter_readable-0.0.1.tar.gz
Algorithm Hash digest
SHA256 674f2255ce77b74b52cb92774e3a2c5bf3020dc39a3a6d4e9ec08cb086be4157
MD5 b5815772db583a5b8da466f13213f7ce
BLAKE2b-256 5f2920ea3fe554a379f58828464b5ee55ddf48330b196802034f59a119641d3b

See more details on using hashes here.

File details

Details for the file skilleter_readable-0.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for skilleter_readable-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 2f8a2c02436ba97306fd75d7b34ebaccf79337b67ef06edd23bd02a39c64025e
MD5 599901573a566f1b9fa841ef00f15476
BLAKE2b-256 fdcbb39084423fc2d78d88f88781f09a3b867a684b00122cd2f36879e2f5fed0

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