Yelp / detect-secrets

An enterprise friendly way of detecting and preventing secrets in code.
Apache License 2.0
3.82k stars 474 forks source link

Add support for standard input on audit mode #199

Open dgzlopes opened 5 years ago

dgzlopes commented 5 years ago

Supporting standard input on audit mode would make detect-secrets pipe-able and a little more Unix-like. I thought about this while commenting on #198... If I just want to audit the results, being able to pipe scan mode to audit mode and skip saving a temporary baseline would be cool.

detect-secrets scan | detect-secrets audit

Actually, audit mode supports reading a baseline from a file for getting the original_baseline, as seen here: https://github.com/Yelp/detect-secrets/blob/13575ede7f9d6f7cb17ac317a19ec5060c97170b/detect_secrets/core/audit.py#L179

KevinHock commented 5 years ago

This is a great issue, thanks for making this @dgzlopes