Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cli: Provide an init command #48

Open
5 tasks
marionebl opened this issue Jul 19, 2017 · 4 comments
Open
5 tasks

cli: Provide an init command #48

marionebl opened this issue Jul 19, 2017 · 4 comments

Comments

@marionebl
Copy link
Contributor

marionebl commented Jul 19, 2017

As seen in #47 setup currently easily allows for errors in documentation and frustration for users. Add an commitlint init [--extends] command. It should

  • create a new commitlint.config.js file if needed, prefer package.json if available

  • ensure @commitlint/cli

    • install/update @commitlint/cli as needed
  • add configs provided via --extends to module.exports.extends

    • default to @commitlint/config-conventional
    • support multiple --extends
    • check if values are available if npm ids
    • install/update @commitlint/config-* as needed
    • disable via --no-config
  • ensure husky

    • ensure presence of commitmsg run-script
    • disable via --no-husky
  • add @commitlint/travis-cli to .travis.yml if file is found and not in scripts

    • install/update @commitlint/travis-cli as needed
    • disable via --no-travis
  • optional: respect .editorconfig? overkill

@marionebl
Copy link
Contributor Author

Another reason: #52

@jlegrone
Copy link
Contributor

jlegrone commented Dec 1, 2017

I wrote create-semantic-module to help address this setup problem. After jlegrone/create-semantic-module#9 is closed all of your bullet points will be covered with the exception of respecting .editorconfig. 😄

@marionebl
Copy link
Contributor Author

@jlegrone create-semantic-module looks really useful! One of the things I'd like to achieve with init is requiring no prompts by default, is that possible when using yeoman under the hood?

@marionebl marionebl changed the title Provide an init command cli: Provide an init command Dec 7, 2017
@jlegrone
Copy link
Contributor

@marionebl yes! Sorry I meant to reply sooner, I'll be adding a few more issues to the repo to track these as todos. I also plan to add an option to disable creating a .yo-rc.json file since that would probably be an undesirable side-effect when not running in an "interactive" mode.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants