Giter Site home page Giter Site logo
Generate photo

generate Goto Github PK

repos: 59.0 gists: 0.0

Name: Generate

Type: Organization

Bio: A new command line tool and developer framework for scaffolding out GitHub projects. A more powerful, composable, functional alternative to Yeoman.

Command line tool and developer framework for scaffolding out new GitHub projects. Generate offers the robustness and configurability of Yeoman, the expressiveness and simplicity of Slush, and more powerful flow control and composability than either.

generate

NPM version NPM monthly downloads Build Status

You might also be interested in update.

Table of contents

(TOC generated by verb using markdown-toc)

Why use Generate?

Why use Generate?

There are other project scaffolders out there, why should you spend your time learning to use Generate?

Generate offers the robustness, power and configurability of Yeoman, with the expressiveness and simplicity of slush and gulp. See the following links if you're interested in a more detailed comparison:

Features

Features

  • advanced flow control: through the use of generators (not es2015 generators), sub-generators, and tasks
  • render templates: use templates to create new files, or replace existing files
  • any engine: use any template engine to render templates, including handlebars, lodash, swig and pug, and anything supported by consolidate. This is useful for generating templates from templates.
  • data: automatically gather data from the user's environment for rendering templates, to populate "hints" in user prompts or for rendering templates, etc.
  • prompts: It's easy to create custom prompts and use the answers for: context for rendering templates, settings options, determining file names, directory structure, and anything else that requires user feedback.
  • macros: create a completely custom generator from the command line using macros.
  • front-matter: use yaml front matter in templates to define settings or defaults on a file-by-file basis
  • smart plugins: Update is built on base, so any "smart" plugin from the Base ecosystem can be used
  • config store: persist configuration settings, global defaults, project-specific defaults, answers to prompts, and so on.
  • streams: full support for gulp and assemble plugins
  • vinyl: files and templates are vinyl files.
  • much more!
Developer toolkit

Developer toolkit

Generate is part of a suite of developer tools that share a common foundation. Any of these tools may be used standalone or together:

  • generate: (you are here) scaffold out new projects
  • assemble: build system for web projects
  • verb: documentation system for code projects
  • update: automate updates of any kind in code projects

All of these applications are built on top of base and templates, which provides a number of benefits, including:

  • similar API/CLI - Learn one, and you will know them all
  • common plugins - create a plugin for one, it will be usable by the others
  • cross-compatible - they can run one another (for example, assemble can run verb to generate markdown documentation, then use that to create an HTML website)

Command line usage

Generate may be installed locally or globally. However, if you wish to run any globally installed generators, Generate's CLI must be installed globally as well.

Install Generate

Install generate globally using npm:

$ npm install --global generate

This adds the gen command to your system path, allowing it to be run from anywhere.

Install a generator

If you'd like to see how generators work, install generate-example:

$ npm install --global generate-example

Then run the example generator with the following command:

$ gen example

Visit the generate-example project for additional steps and guidance.

Next steps

Command line arguments

The syntax for running generators is:

$ gen generator:task
  • generator one or more space-separated generator names
  • task - (optional) one or more comma-separated task names

Examples

# run generate-project's "default" task
$ gen project
# run generate-project's "license" task
$ gen project:license
# run generate-project's "package" task
$ gen project:package

generator.js

If a generator.js is in the current working directory, Generate's CLI will attempt to load it and execute any tasks you've specified at the command line.

Examples

Generators

generators are plugins that can be run by command line or using Generate's API.

Discovering generators

  • Find generators to install by searching npm for packages with the keyword generategenerator
  • Visit Generate's GitHub org to see the generators maintained by the core team

Discovering plugins

Plugins from any applications built on base should work with Generate (and can be used in your generator):

  • base: find base plugins on npm using the baseplugin keyword
  • assemble: find assemble plugins on npm using the assembleplugin keyword
  • generate: find generate plugins on npm using the generateplugin keyword
  • templates: find templates plugins on npm using the templatesplugin keyword
  • update: find update plugins on npm using the updateplugin keyword
  • verb: find verb plugins on npm using the verbplugin keyword

Authoring generators

Visit the documentation for generators to learn how to use, author and publish generators.

More information

About

Related projects

  • assemble: Get the rocks out of your socks! Assemble makes you fast at creating web projects… more | homepage
  • base: Framework for rapidly creating high quality node.js applications, using plugins like building blocks | homepage
  • update: Be scalable! Update is a new, open source developer framework and CLI for automating updates… more | homepage
  • verb: Documentation generator for GitHub projects. Verb is extremely powerful, easy to use, and is used… more | homepage

Community

Are you using Generate in your project? Have you published a generator and want to share your project with the world?

Here are some suggestions!

  • If you get like Generate and want to tweet about it, please feel free to mention @generatejs or use the #generatejs hashtag
  • Show your love by starring Generate and generate
  • Get implementation help on StackOverflow (please use the generatejs tag in questions)
  • Gitter Discuss Generate with us on Gitter
  • If you publish an generator, thank you! To make your project as discoverable as possible, please add the keyword generategenerator to package.json.

Contributing

Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.

Please read the contributing guide for advice on opening issues, pull requests, and coding standards.

Running tests

Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:

$ npm install && npm test

Author

Jon Schlinkert

License

Copyright © 2017, Jon Schlinkert. Released under the MIT License.


This file was generated by verb-generate-readme, v0.6.0, on June 02, 2017.

Generate's Projects

.github icon .github

Default community health files for Generate.

best-practices icon best-practices

Advice on creating effective generators and getting the most out of Generate.

common-questions icon common-questions

An object of questions commonly used by project generators or when initializing projects. Questions can be overridden, updated or extended.

generate icon generate

A new command line tool and developer framework for scaffolding out GitHub projects. Generate offers the robustness and configurability of Yeoman, the expressiveness and simplicity of Slush, and more powerful flow control and composability than either.

generate-appveyor icon generate-appveyor

Generate an appveyor.yml file to the cwd or specified directory. Install globally and run with generate's CLI, or use as a component in your own generator.

generate-ask icon generate-ask

Adds user prompts to your generator for getting data that is commonly for rendering templates, like author name, project name, etc.

generate-assemble icon generate-assemble

Generate a starter assemble project for a site, blog, assemble plugin, middleware, helper, or template.

generate-boilerplate icon generate-boilerplate

Scaffold out complete projects using declarative boilerplate configurations. This generator can be globally installed and run from the command line, or used as a plugin inside other generators.

generate-cname icon generate-cname

Generate the CNAME file for a web project. Is this necessary? No, not at all. A CNAME file is one line and takes a couple seconds to create. The point of this micro-generator is to automate the creation of the CNAME file based on configuration settings, as a small part of a larger build.

generate-coc icon generate-coc

Generate a CODE_OF_CONDUCT.md file for a project (Contributor Covenant Code of Conduct). Use from the command line when Generate's CLI is installed globally, or use as a plugin or sub-generator in your own generator.

generate-collections icon generate-collections

Add the docs, includes, badges, and layouts collections, along with a few generic defaults to your generator.

generate-contributing icon generate-contributing

Generate a contributing.md file for a project. Can also be used as a building block to add this functionality to another generator.

generate-data icon generate-data

Generate plugin that gathers data from the user's environment to pre-populate data for hints.

generate-defaults icon generate-defaults

Generator that can be used by other "generate" generators to set common default settings.

generate-dest icon generate-dest

`Generate` generator that prompts the user for the destination directory to use. Can be used as a sub-generator or plugin in your generator.

generate-editorconfig icon generate-editorconfig

Generate a `.editorconfig` file from the command line, or use as a sub-generator or plugin in your own generator.

generate-engine icon generate-engine

Generate a new consolidate-style engine project, with starter code and unit tests.

generate-eslint icon generate-eslint

Generate a `.eslintrc.json` or `.eslintignore` file as part of a larger build workflow. This generator can be used as a sub-generator or plugin inside other generators.

generate-git icon generate-git

Generator for initializing a git repository and adding first commit.

generate-gitattributes icon generate-gitattributes

Generate a .gitattributes file from the command line when Generate's CLI is installed globally, or use as a plugin or sub-generator in your own generator.

generate-gitignore icon generate-gitignore

Generate a .gitignore file from the command line when Generate's CLI is installed globally, or use as a plugin or sub-generator in your own generator.

generate-gulp icon generate-gulp

Generate a node.js project with a gulpfile or starter gulp plugin.

generate-gulpfile icon generate-gulpfile

Generate a gulpfile.js from the command line if Generate is installed globally, or use this as a plugin or sub-generator in your own generator to make it a continuous part of the build workflow when scaffolding out a new project.

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.