Skip to content

💻 CLI tool to download Open Source License files

License

Notifications You must be signed in to change notification settings

KevinGimbel/license

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

license

Download open source license files for your project

license is a command line tool which allows you to download open source licenses from osl.kevingimbel.com.

Demo

asciicast

Click the image above to see a demo video on asciinema.org

Install

Binary

Download the binary for your operating system from the release tab and place it somewhere inside your PATH.

Brew

Run the following commands in a terminal to install license via brew.

$ brew tap kevingimbel/tap
$ brew install license

go get

If brew or binary installations do not suite you, you can install license with go get.

$ go get github.com/kevingimbel/license

Note: Go must be installed on the system.

Usage

See license help for a list of all commands.

See license [cmd] --help for more about each command. [cmd] can be any of: get, list, update, or version.

license list

Run license list to see a list of all licenses and their IDs. IDs are used to retrieve a license.

$ license list
Academic Free License v3.0 (id:  AFL-3.0 )
GNU Affero General Public License v3.0 (id:  AGPL-3.0 )
Apache License 2.0 (id:  Apache-2.0 )
Artistic License 2.0 (id:  Artistic-2.0 )

license get [id]

license get downloads the license by ID to a file named LICENSE. Use -f or --format to specify a file format.

Download to a file named LICENSE (no file extension).

$ license get Apache-2.0

To download the license to a file named LICENSE.txt.

$ license get --format txt MIT

license update

Update the local license cache file in $HOME/.license/license.json. The locale cache file is not used as of version 0.1.2!

license version

Display the version of license. Use license version -l to display the Git commit ID and build date.

$ license version
0.1.2