https://github.com/kyoh86/go-spdx
The package parses SPDX license expression strings describing license terms.
https://github.com/kyoh86/go-spdx
go golang library spdx
Last synced: about 1 year ago
JSON representation
The package parses SPDX license expression strings describing license terms.
- Host: GitHub
- URL: https://github.com/kyoh86/go-spdx
- Owner: kyoh86
- License: mit
- Created: 2017-05-21T09:09:17.000Z (about 9 years ago)
- Default Branch: main
- Last Pushed: 2024-09-07T10:38:25.000Z (almost 2 years ago)
- Last Synced: 2025-03-31T11:35:24.902Z (about 1 year ago)
- Topics: go, golang, library, spdx
- Language: Go
- Size: 2 MB
- Stars: 5
- Watchers: 3
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# go-spdx
The package parses SPDX license expression strings describing license terms
[](https://pkg.go.dev/kyoh86/go-spdx)
[](https://goreportcard.com/report/github.com/kyoh86/go-spdx)
[](https://codecov.io/gh/kyoh86/go-spdx)
[](https://github.com/kyoh86/go-spdx/releases)
## Install
```
go get github.com/kyoh86/go-spdx
```
## Usage
See [example](https://github.com/kyoh86/go-spdx/blob/main/cmd/go-spdx-example/main.go) or [test](https://github.com/kyoh86/go-spdx/blob/main/spdx/parser_test.go)
## Updating licenses
In order to update the licenses_asset.go file with the newest license list from SPDX, execute the following commands:
```
cd spdx
npm install spdx-license-list@latest
make licenses-asset
```
(You should also add a test to spdx/parser_test.go to make sure everything worked as expected.)
# LICENSE
[](http://www.opensource.org/licenses/MIT)
This is distributed under the [MIT License](http://www.opensource.org/licenses/MIT).