compliance-trestle
compliance-trestle copied to clipboard
`trestle author catalog-generate` command has misleading `-n` option documentation and only works for one particular catalog json file
Describe the bug
There are two potential issues regarding the trestle author catalog-generate
command:
- The documentation shows that the
-n
option looks for the name of the catalog model in the trestle workspace. But it, in fact, looks for the sub-directory ofcatalogs/
that contains the catalog JSON file we want to generate markdowns from. - The command only works for the catalog file named specifically
catalog.json
. Any other names would cause an error.
To Reproduce
Steps to reproduce the behavior:
- Initalizae a trestle workspace
- Import a catalog JSON file to the
catalogs/
, and ensure it is NOT namedcatalog.json
- Create a directory
md/
in the root to store the markdowns - Run
trestle author catalog-generate -n catalog -o md/
to reproduce the first issue. - Run
trestle author catalog-generate -n . -o md/
to reproduce the second issue.
Expected behavior
The -n
option documentation should match what it is looking for.
The command should also work on catalog JSON files named other than catalog.json
Screenshots / Logs.
Environment
- OS: [e.g. iOS]
- Python version:
- Installed packages: