Skip to main content

licence_states_an_open_source_codebase

Function licence_states_an_open_source_codebase 

Source
pub fn licence_states_an_open_source_codebase(expression: &str) -> bool
Expand description

Whether one SPDX expression is well formed and states an open-source codebase.

Three conditions, and the trio is the point. The expression must parse, because MIT OR names one licence and no complete offer, and accepting it would land a workflow whose provider’s terms nothing established. Every reader of it must obtain an OSI-approved grant, which makes a disjunction strict and a conjunction permissive. And every identifier in it must be one this release recognizes, either OSI-approved or a Creative Commons term over material that is not code.

The conjunction is the case this answers. A project that offers its source under an OSI-approved licence and its prose under Creative Commons terms declares both in one expression, and the second adds an obligation over prose rather than withdrawing the grant over code.