Skip to content

msmikesm/npm-package-creator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 

Repository files navigation

npm-package-creator

Complex npm package creator (bash).

About

The Package Wizard will create a repository for you on the chosen platform (GitHub, GitLab or Bitbucket). It allows you to choose the right configuration (Webpack+babel, Babel, Node) for your target. It will carry out the whole process of installation and configuration of tools according to good practices.

Getting Started

The script is designed for Linux and Mac users.

First we have to grant permission to the script.
In the directory where we downloaded the script:

$ chmod +x package-creator.sh

Then we can run it:

$ ./package-creator.sh

Or we can add the script to the PATH
Follow these steps:

$ sudo mv package-creator.sh /usr/local/bin
$ sudo touch ~/.bash_aliases
$ sudo sh -c "echo \"alias package-creator='/usr/local/bin/package-creator.sh'\" > ~/.bash_aliases"
$ source ~/.bash_aliases

And just type wherever you want to create a new package:

$ package-creator

Running

The script will guide you through the whole installation process, from initialization of the repository on the chosen platform to installation and project configuration.

You can choose from 3 platforms:

and 3 tool configurations:

You can create packages for any framework, like:

After creating a new project, you have ready-made commands:

  • to build production package
    $ npm run build
  • run tests
    $ npm run test
  • lint code
    $ npm run lint
  • format code
    $ npm run format
  • publish package
    $ npm run publish
  • prepare new version of package and publish it
    $ npm version patch && npm publish

for more commands (for specific configuration), see package.json

Tools used

and more needed plugins and configurations.

Author

Michal Siemienowicz

If I helped you, you can help me with my work. 🍻

License

This project is licensed under the MIT License - see the LICENSE.md file for details.