termux / termux-language-server

🛠️ A language server for some specific bash scripts
https://termux-language-server.readthedocs.io/
GNU General Public License v3.0
84 stars 8 forks source link

Add SPDX `LicenseRef-.*` for PKGBUILD's license #24

Open txtsd opened 6 days ago

txtsd commented 6 days ago

Which means SPDX license expressions, and LicenseRef-* for custom licenses, are possible.

Reference: https://spdx.github.io/spdx-spec/v3.0.1/annexes/spdx-license-expressions/#composite-license-expressions https://spdx.org/licenses/exceptions-index.html

Freed-Wu commented 6 days ago

https://github.com/termux/termux-language-server/issues/19#issuecomment-2199886707

It should support SPDX. I heard LicenseRef-* firstly. Sounds like all string match LicenseRef-.* are legal?

txtsd commented 6 days ago

Correct!

txtsd commented 6 days ago

But also SPDX expressions like MIT OR GPL-3.0-or-later WITH GPL-3.0-linking-source-exception are valid.

EDIT: along with parentheses

Freed-Wu commented 6 days ago

SPDX expression looks a little complex. Now this project just use regex to match some legal string.