Launch Week Day 1:Rust Support in Socket Is Now Generally Available.Learn More
Socket
Book a DemoInstallSign in
Socket

generator-base

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

generator-base

Generator for creating Yeoman generators that are capable of remembering certain user answers, resulting in a better user experience. Generators come with the basic necessities, including docs.

Source
npmnpm
Version
0.1.0
Version published
Weekly downloads
0
-100%
Maintainers
1
Weekly downloads
 
Created
Source

generator-base NPM version

Kickstart documentation for any project! This is the official Yeoman generator for Base, a zero-configuration markdown documentation generator that is extremely easy to use and extend.

We're just getting started here, we'd love to see pull requests for other types of documentation and for any kind of project!

Getting Started

Install

Install globally with npm:

npm i -g generator-base

Usage

Once installed globally, simply run:

  • yo base to to start a new project
  • yo base:doc [foo] to add a specific document or 'include'.

yo base

Running the generator with yo base will add the following files to your project:

  • .verbrc.md: a markdown-runtime config file for Base. YAML front-matter can be used for config, and the markdown content is used to generate your project's README.md.
  • package.json: with minimal properties defined. However, if this alredy exists base will be added to devDependencies.

Sub-generators

Sub-generators allow you to add a specific file or files to an existing project.

yo base:config

Add a Base config file with:

yo base:config foo

Where foo is one of the following:

  • yo base:config md: adds a .verbrc.md file
  • yo base:config yml: adds a .verbrc.yml file
  • yo base:config basefile: adds a basefile.js file

Pro tips:

  • You can use the default config file, .verbrc.yml, by running just yo base:config.
  • You can add a basefile.js by running just yo base:vf

Learn about Base config files.

yo base:doc

Add a specific document with:

yo base:doc foo.md

Where foo.md is the name of the file you want to add. If the name used matches an actual file in base-readme-includes, then that file will be copied into the docs/ directory of your project.

If the name doesn't match a valid file in base-readme-includes, then a new "starter" document will be created using the given file name.

yo base:boilerplate

Use a boilerplate to kickstart documentation for a project. Boilerplates include a README.tmpl.md template and a few includes, such as install.md, options.md etc.

yo base:boilerplate foo

Where foo is the name of the boilerplate you want to use from base-boilerplates.

Valid yo base:boilerplate arguments are:

  • node: adds generic documentation for a Node.js project
  • helper: adds generic documentation for a Handlebars helper project
  • assembleplugin: adds generic documents for an Assemble plugin
  • gulpplugin: adds generic documents for a gulp plugin
  • gruntplugin: adds generic documents for a Grunt plugin

Pro tip: you can use the default boilerplate, node, by running just yo base:boilerplate.

Visit the docs for adding custom boilerplates.

yo base:data

This subgenerator makes it easy to add data files to extend the context available to your templates (by default Base processes templates using data from your project's package.json, but you can extend the data available to your templates with any JSON or YAML files by specifying them in a data property in .verbrc.yml or .verbrc.yml).

  • yo base:data changelog: adds a CHANGELOG file to the root of your project, formatted as valid YAML.

yo base:readme

Add a readme template to docs/README.tmpl.md by running yo base:readme.

Generator options

Command: -s | --skip-install

Skips the automatic execution of bower and npm after scaffolding has finished.

Command: -w | --skip-welcome-message

Skips the Yeoman welcome message.

Author

Jon Schlinkert

License

Copyright (c) 2014 Jon Schlinkert, contributors. Released under the MIT license

This file was generated by base-cli on April 21, 2014.

Keywords

boilerplate

FAQs

Package last updated on 02 May 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts