CLI Commands
cnspec policy format
Apply style formatting to one or more policy bundle files.
Apply consistent style formatting to one or more policy bundle files. Use this to keep your policy files clean and readable, especially before committing them to version control.
cnspec policy format my-policy.mql.yamlFormat and sort the bundle alphabetically:
cnspec policy format my-policy.mql.yaml --sortOptions
-h, --help help for format
--sort Sort the bundleOptions inherited from parent commands
--api-proxy string Set the proxy for communications with Mondoo Platform API
--auto-update Enable automatic provider installation and update (default true)
--config string Set config file path (default $HOME/.config/mondoo/mondoo.yml)
--log-level string Set the log level: error, warn, info, debug, trace (default "info")
-v, --verbose Enable verbose outputSEE ALSO
- cnspec policy - Manage local and upstream policies