README.md in inspec_tools-1.4.2 vs README.md in inspec_tools-1.7.1

- old
+ new

@@ -1,7 +1,9 @@ # InspecTools +![](https://github.com/mitre/inspec_tools/workflows/inspec_tools/badge.svg) + InspecTools supplies several CLI tools to convert to and from InSpec format. The inspec_tools support the following modules: - generate_map @@ -13,10 +15,11 @@ - inspec2csv - xccdf2inspec - inspec2xccdf - inspec2ckl - pdf2inspec +- xlsx2inspec It also includes an API that can be used in a ruby application. The Ruby API is defined in lib/inspec_tools/inspec.rb # Installation @@ -118,11 +121,11 @@ compliance.min: 81 failed.critical.max: 1 failed.high.max: 1 ``` -#### In-Line Exmamples +#### In-Line Examples ``` {compliance: {min: 90}, failed: {critical: {max: 0}, high: {max: 0}}} ``` ``` @@ -245,59 +248,49 @@ -d --debug : debug run [optional] example: inspec_tools pdf2inspec -p benchmark.pdf -o /path/to/myprofile -f ruby -s true ``` -## version - -Prints out the gem version - +## xlsx2inspec ``` -USAGE: inspec_tools version -``` +Usage: + inspec_tools xlsx2inspec -m, --mapping=MAPPING -p, --control-name-prefix=CONTROL_NAME_PREFIX -x, --xlsx=XLSX -# Development / PR process +Options: + -x, --xlsx=XLSX + -m, --mapping=MAPPING + -p, --control-name-prefix=CONTROL_NAME_PREFIX + -V, [--verbose], [--no-verbose] + -o, [--output=OUTPUT] + # Default: profile + -f, [--format=FORMAT] + # Default: ruby + # Possible values: ruby, hash + -s, [--separate-files], [--no-separate-files] + # Default: true + [--log-level=LOG_LEVEL] # Set the logging level: ["debug", "info", "warn", "error", "fatal"] + [--log-location=LOG_LOCATION] # Location to send diagnostic log messages to. (default: $stdout or Inspec::Log.error) + l, [--log-directory=LOG_DIRECTORY] # Provie log location -This gem was developed using the [CLI Template](https://github.com/tongueroo/cli-template), a generator tool that builds a starter CLI project. +xlsx2inspec translates CIS Benchmarks in XLSX format to Inspec controls using a mapping file -## A complete PR should include 7 core elements: +See examples/xlsx2inspec/mapping.cis.yml for an example mapping file -- A signed PR ( aka `git commit -a -s` ) -- Code for the new functionality -- Updates to the CLI -- New unit tests for the functionality -- Updates to the docs and examples in `README.md` and `./docs/*` -- (if needed) Example / Template files ( `metadata.yml`,`example.yml`, etc ) - - Scripts / Scaffolding code for the Example / Template files ( `generate_map` is an example ) -- Example Output of the new functionality if it produces an artifact +example: bundle exec inspec_tools xlsx2inspec -m examples/xlsx2inspec/mapping.cis.yml -p azure-cis-foundations -x examples/cis.xlsx +``` -1. open an issue on the main inspec_tools website noting the issues your PR will address -2. fork the repo -3. checkout your repo -4. cd to the repo -5. git co -b `<your_branch>` -6. bundle install -7. `hack as you will` -8. test via rake -9. ensure unit tests still function and add unit tests for your new feature -10. add new docs to the `README.md` and to `./docs/examples` -11. update the CLI as needed and add in `usage` example -12. (if needed) create and document any example or templates -13. (if needed) create any supporing scripts -14. (opt) gem build inspec_tools.gemspec -15. (opt) gem install inspec_tools -16. (opt) test via the installed gem -17. git commit -a -s `<your_branch>` -18. Open a PRs aginst the MITRE inspec_tools repo +## version -# Testing +Prints out the gem version -There are a set of unit tests. Run `rake test` to run the tests. +``` +USAGE: inspec_tools version +``` -To release a new version, update the version number in `version.rb` according to the [Semantic Versioning Policy](https://semver.org/). +# `inspec_tools` Development -Then, run `bundle exec rake release` which will create a git tag for the specified version, push git commits and tags, and push the `.gem` file to [github.com](https://github.com/mitre/inspec_tools). +View our [wiki page](https://github.com/mitre/inspec_tools/wiki/Development) for more information on contributing. ### NOTICE © 2018 The MITRE Corporation. @@ -309,6 +302,6 @@ ### NOTICE This software was produced for the U. S. Government under Contract Number HHSM-500-2012-00008I, and is subject to Federal Acquisition Regulation Clause 52.227-14, Rights in Data-General. -No other use other than that granted to the U. S. Government, or to those acting on behalf of the U. S. Government under that Clause is authorized without the express written permission of The MITRE Corporation.DISA STIGs are published by DISA IASE, see: https://iase.disa.mil/Pages/privacy_policy.aspx +No other use other than that granted to the U. S. Government, or to those acting on behalf of the U. S. Government under that Clause is authorized without the express written permission of The MITRE Corporation. DISA STIGs are published by DISA, see: https://public.cyber.mil/privacy-security/