Giter VIP home page Giter VIP logo

lice-js's Introduction

==== lice-js

A javascript port of lice originally by jcarbaugh

Lice generates license files. No more hunting down licenses from other projects.

Installation

npm install lice-js

or:

git clone [email protected]:licenses/lice-js.git
cd lice-js
(sudo)npm link

Overview

Generate a BSD-3 license, the default:

$ licejs
Copyright (c) 2013, Jeremy Carbaugh

All rights reserved.

Redistribution and use in source and binary forms, with or without modification,
...

Generate an MIT license:

$ licejs mit
The MIT License (MIT)
Copyright (c) 2013 Jeremy Carbaugh

Permission is hereby granted, free of charge, to any person obtaining a copy
...

Generate an apache license header , specifying the year and organization to be used:

 $ licejs gpl3 -y 2013 -o "aplomb bomb inc" -p "mySuperProjectName" --header
mySuperProjectName
Copyright (C) 2013  aplomb bomb inc

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
...

##Defaults

If no arguments are provided for available variables, the following will be used:

Variable Default
owner / organization git user.name
year current year
project current working directory
license type bsd3

You can change any of these by using --config in the cli:

licejs --config.organization "The Interesing Co."

then if you want an MIT license for example:

$ licejs mit
The MIT License (MIT)
Copyright (c) 2013 The Interesing Co.

Permission is hereby granted, free of charge, to any person obtaining a copy
...

The Cli will check the config file first. Then if no value is found for a particular key it will get the values specified in table above.

I want XXXXXXXXX license in here!

Great! Is it a license that is commonly used? If so, open an issue or, if you are feeling generous, fork and submit a pull request in the license-templates repo.

Usage

Usage: licejs [-h]
licejs [-l]
licejs [ -o [OWNER] -p [PROJECT] -y [YEAR] ] [license] [--header]
licejs [--config[.key <VALUE>]]

Options:
  -h, --help          show this help menu                                                                                     
  -l, --list          list all available license templates                                                                    
  -o, --organization  the organisation/owner that holds the copy[right,left]
  -p, --project       the name of the project
  -y, --year          copyright year 
  --config            set default values: usage --config.key value
  	available:[year], [project], [licenseType], [organisation]
  --header            just get the license header
  

TODO:

  • Error handling.
  • Unit testing.
  • Include license-templates as submodule.
  • include --vars option to list template variables.
  • suggestions?

Changelog

0.2

  • npm installable release

0.1

  • Initial release

lice-js's People

Contributors

hyubs avatar jarofghosts avatar pombredanne avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.