Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- nodeLicenseToNixpkgs :: Text -> LicensesBySpdxId -> NExpr
- data LicensesBySpdxId
Conversion Logic
nodeLicenseToNixpkgs :: Text -> LicensesBySpdxId -> NExpr Source #
Implements the logic for converting from an (optional)
package.json
license
field to a nixpkgs meta.license
set. Since support for multiple licenses is poor in nixpkgs
at the moment, we don't attempt to convert SPDX expressions
like (ISC OR GPL-3.0-only)
.
See https://docs.npmjs.com/files/package.json#license for
details on npm's license
field.
License Lookup Table
data LicensesBySpdxId Source #
Lookup table from SPDX identifier (as Text
) to NixpkgsLicense
.
Instances
Eq LicensesBySpdxId Source # | |
Defined in Distribution.Nixpkgs.Nodejs.License (==) :: LicensesBySpdxId -> LicensesBySpdxId -> Bool # (/=) :: LicensesBySpdxId -> LicensesBySpdxId -> Bool # | |
Show LicensesBySpdxId Source # | |
Defined in Distribution.Nixpkgs.Nodejs.License showsPrec :: Int -> LicensesBySpdxId -> ShowS # show :: LicensesBySpdxId -> String # showList :: [LicensesBySpdxId] -> ShowS # | |
Semigroup LicensesBySpdxId Source # | |
Defined in Distribution.Nixpkgs.Nodejs.License (<>) :: LicensesBySpdxId -> LicensesBySpdxId -> LicensesBySpdxId # sconcat :: NonEmpty LicensesBySpdxId -> LicensesBySpdxId # stimes :: Integral b => b -> LicensesBySpdxId -> LicensesBySpdxId # | |
Monoid LicensesBySpdxId Source # | |
Defined in Distribution.Nixpkgs.Nodejs.License | |
FromJSON LicensesBySpdxId Source # | |
Defined in Distribution.Nixpkgs.Nodejs.License parseJSON :: Value -> Parser LicensesBySpdxId # parseJSONList :: Value -> Parser [LicensesBySpdxId] # |