Skip to content

Commit

Permalink
Expose SPDX license info in index.json #7
Browse files Browse the repository at this point in the history
    * Expose spdx_license_key, other_spdx_license_keys, and is_exception

Signed-off-by: Jono Yang <[email protected]>
  • Loading branch information
JonoYang committed Jun 2, 2021
1 parent cf386c8 commit 650f6a6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion app.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,12 +74,15 @@ def generate_indexes(output_path):
index = [
{
"license_key": key,
"spdx_license_key": license.spdx_license_key,
"other_spdx_license_keys": license.other_spdx_license_keys,
"is_exception": license.is_exception,
"json": f"{key}.json",
"yml": f"{key}.yml",
"html": f"{key}.html",
"text": f"{key}.LICENSE",
}
for key in licenses.keys()
for key, license in licenses.values()
]
write_file(output_path, "index.json", json.dumps(index))
write_file(output_path, "index.yml", saneyaml.dump(index))
Expand Down

0 comments on commit 650f6a6

Please sign in to comment.