Skip to content

Latest commit

 

History

History
47 lines (32 loc) · 940 Bytes

.verb.md

File metadata and controls

47 lines (32 loc) · 940 Bytes

Usage

Context and templates

  • package.json is used for context
  • the options object can be used to extend the context (package.json) passed to templates
  • Banner templates are just Lo-Dash/Underscore templates. Anything that works with those libs should work in banner templates.

API

{%= apidocs('index.js') %}

Example usage

Pass a file path to the main export:

const banner = require('add-banner');
console.log(banner('./index.js'));

Results in the string:

/*!
 * banner-cli <https://github.com/jonschlinkert/banner-cli>
 *
 * Copyright (c) 2014-present Jon Schlinkert.
 * Licensed under the MIT license.
 */

module.exports = () => {};

CLI

$ add-banner --help

  Usage: add-banner [options] <pattern>

  Options:

    -h, --help                 output usage information
    -V, --version              output the version number
    -t, --template [filepath]  path to template file