EmbarkStudios / spdx

🆔 Helper crate for SPDX expressions. 🦀

Home Page:http://embark.rs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Use SPDX JSON license list

flukejones opened this issue · comments

Is your feature request related to a problem? Please describe.
I was considering using cargo-deny to help with packaging crates for a distro, which while incredibly helpful, would be made even more so by including the isOsiApproved field available in the SPDX data.

Where this would be helpful is I could make a service on OBS, and set a series of restrictions such as "must be isOsiApproved and in the approved list" or similar. It would help to select a broad range of licenses quickly.

Describe the solution you'd like
Either add this as an additional field in the existing license data, or parse the SPDX (perhaps pub const DATA = include!("licenses.json"); ?). I guess you'd need to weigh up the pros/cons of including a large text file in the binary vs just the required data. Or perhaps use a build.rsto parse it, and spit out anidentifiers.rs` with only the required data.

Agreed, I was going to put that in cargo-deny originally but never did. The current identifiers file is actually copied from the license exprs crate, so yah, would need to generate it in this crate itself to get more info.

Thanks so much for considering this.