Skip to content

mili-project-manager/mili

Repository files navigation

logo

Mili

version downloads license dependencies coveralls

简体中文

Projects that derived from the same scaffolding, have evolved over time and become different. Scaffolding lost control of the subsequent development of the project. When we need to improve some of the basic functions of scaffolding(e.g. eslint rules), we need to modify each project, and even have to design a customized solution for some old projects.

Therefore, in order to improve the control ability of scaffolding for the subsequent development of the project,template can modified some files and release new template version, then project can upgrade the template version.

It is useful for team project management.

Usage

Init Project

mkdir my_project
cd my_project

# template in npm
npx mili init npm:@mtpl/code-style
# template in github
npx mili init github:mili-project-manager/mtpl-code-style
# template in private git repository
npx mili init https://github.com/mili-project-manager/mtpl-code-style
# ssh is also support
npx mili init [email protected]:mili-project-manager/mtpl-code-style.git

Upgrade

The upgrade operation is very simple to use. It will upgrade the template to the latest version.

npx run upgrade
This command maybe overwrite your files.

Check Before Commit

With husky, it is easy to verify whether the project file meets the template before commit. Thereby ensuring the specification of the project code.

Run in terminal:

npx mili check --diff --fold

The example stdout:

mili check

Run npx mili upgrade command will auto modify code according to the diff.

Contributing & Development

If there is any doubt, it is very welcome to discuss the issue together. Please read Contributor Covenant Code of Conduct and CONTRIBUTING.