headroom-0.1.2.0: License Header Manager
Copyright(c) 2019-2020 Vaclav Svejcar
LicenseBSD-3
Maintainervaclav.svejcar@gmail.com
Stabilityexperimental
PortabilityPOSIX
Safe HaskellNone
LanguageHaskell2010

Headroom.License

Description

This module provides data types and functions for representing various opensource licenses, for which this application can generate Jinja templates. As the template text itself of given license may differ based on target programming language (i.e. syntax for comments is different), each License is represented by the LicenseType and FileType.

Synopsis

Documentation

data License Source #

License (specified by LicenseType and FileType)

Instances

Instances details
Eq License Source # 
Instance details

Defined in Headroom.License

Methods

(==) :: License -> License -> Bool #

(/=) :: License -> License -> Bool #

Show License Source # 
Instance details

Defined in Headroom.License

data LicenseType Source #

Type of the license.

Constructors

Apache2

Apache License, version 2.0

BSD3

BSD-3 license

GPL2

GNU GPL v.2 license

GPL3

GNU GPL v.3 license

MIT

MIT license

Instances

Instances details
Bounded LicenseType Source # 
Instance details

Defined in Headroom.License

Enum LicenseType Source # 
Instance details

Defined in Headroom.License

Eq LicenseType Source # 
Instance details

Defined in Headroom.License

Ord LicenseType Source # 
Instance details

Defined in Headroom.License

Read LicenseType Source # 
Instance details

Defined in Headroom.License

Show LicenseType Source # 
Instance details

Defined in Headroom.License

parseLicense Source #

Arguments

:: Text

raw string representation

-> Maybe License

parsed License

Parses License from the raw string representation, formatted as licenseType:fileType.

>>> parseLicense "bsd3:haskell"
Just (License BSD3 Haskell)