Git Product home page Git Product logo

generator-license's Introduction

generator-license

Build Status NPM version Coverage Status David Dependencies David Dev Dependencies

Generate LICENSE file for your project using Yeoman.

yo license

Getting started

  • Make sure you have yo installed: npm install -g yo
  • Install the generator: npm install -g generator-license
  • Run: yo license, enter your full name and choose a license

The generator will generate the LICENSE file and fill the license field of the package.json.

Compose with generator license in your own generator

generator-license can be easily embedded into your own generator using Yeoman composability.

First, install generator-license as a dependency of your own generator.

npm install --save generator-license

Then call it from your generator.

this.composeWith(require.resolve('generator-license'), {
  name: 'John Doe', // (optional) Owner's name
  email: '[email protected]', // (optional) Owner's email
  website: 'https://example.com', // (optional) Owner's website
  year: '1945', // (optional) License year (defaults to current year)
  licensePrompt: 'Which license do you want to use?' // (optional) customize license prompt text
  defaultLicense: 'MIT', // (optional) Select a default license
  license: 'MIT', // (optional) Select a license, so no license prompt will happen, in case you want to handle it outside of this generator
});

All the options are optional; the generator will prompt for answers when information is not provided.

Supported licenses

For Creative Commons Licenses (useful for media files, documentation and other creative works) you can use generator-license-cc.

License

MIT License

generator-license's People

Contributors

benjaminvanryseghem avatar christophehurpeau avatar dependabot[bot] avatar ek9 avatar fyrkant avatar greenkeeperio-bot avatar hutson avatar hypercubed avatar jozefizso avatar knpwrs avatar millette avatar razzeee avatar sboudrias avatar

Watchers

 avatar  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.