TL;DR

https://github.com/3846masa/memi

A smart task-runner for JSer

Write tasks as ES module

Auto-install dependencies!!

Why create a new task-runner?

Inspired by mimorisuzuko/memi (Japanese).

This requires the following:

The new task-runner allows users to write write the tasks in JavaScript; it is difficult for me to write Shell Script and Makefiles.

it is difficult for me to write Shell Script and Makefiles. Can use it anywhere; I would like to avoid putting node_modules or package.json in a non-Node.js working directory.

I would like to avoid putting or in a non-Node.js working directory. Put the dependencies in a directory except npm root -g ; it is not cool to install them globally.

Issues of existing task-runners

Makefile

Shell Script is difficult, e.g. in Windows, it is troubling to install a make command.

npm scripts

I hate to put package.json in a non-Node.js working directory.

gulp

Although dependencies of gulp should be installed globally or locally, I hate to put node_modules in a non-Node.js working directory and to install dependencies to npm root -g .

MEMI, a smart task-runner

First, you define tasks via Memifile.js .

Or, you can use a named exports.

Also, you can write as CommonJS．

Typing memi <taskname> allows you to run the task. For example, if you would like to run a build task, you should type memi build .

Then, MEMI finds up Memifile.js recursively. So MEMI can work on subdirectories.

In the other words, if you want to run MEMI anywhere, you should put Memifile.js in a home directory.

When you pass arguments as memi <taskname> arg1 arg2 ... , the task function receives as function arguments. Also, MEMI allows you to use node modules for CLI (e.g. Inquirer).

It is notable that MEMI will install dependencies automatically! For example, when you write Memifile.js as the above, MEMI installs fs-extra and execa .