NONE and NOASSERTION for 'no-license' and 'other'

https://spdx.org/spdx-specification-21-web-version#h.ihv636
This commit is contained in:
Mike Linksvayer 2018-04-25 09:14:19 -07:00
parent f4272076c7
commit d3f7a6cce1
1 changed files with 6 additions and 0 deletions

View File

@ -117,6 +117,12 @@ module Licensee
@meta ||= LicenseMeta.from_yaml(yaml)
end
def spdx_id
return meta.spdx_id if meta.spdx_id
return 'NOASSERTION' if key == 'other'
return 'NONE' if key == 'no-license'
end
# Returns the human-readable license name
def name
title ? title : key.capitalize