CLI tool to run multiple npm-scripts in a madly comfortable way.
(c) Madrun
🐊Putout plugin adds ability to fix issues with Madrun config file.
npm i putout @putout/plugin-madrun -D
- ✅ add-cut-env;
- ✅ add-fix-lint;
- ✅ add-function;
- ✅ add-run;
- ✅ call-run;
- ✅ convert-args-to-scripts;
- ✅ convert-cut-env-to-run;
- ✅ convert-lint-lib;
- ✅ convert-nyc-to-c8
- ✅ convert-run-argument;
- ✅ convert-run-to-cut-env;
- ✅ convert-to-async;
- ✅ declare;
- ✅ remove-check-duplicates-from-test;
- ✅ remove-putout;
- ✅ remove-useless-array-in-run;
- ✅ remove-useless-string-conversion;
- ✅ rename-eslint-to-putout;
- ✅ rename-series-to-run;
- ✅ set-lint-dot;
- ✅ set-report-lcov;
{
"rules": {
"madrun/add-function": "on",
"madrun/add-fix-lint": "on",
"madrun/add-run": "on",
"madrun/add-cut-env": "on",
"madrun/call-run": "on",
"madrun/convert-run-argument": "on",
"madrun/convert-args-to-scripts": "on",
"madrun/convert-run-to-cut-env": "on",
"madrun/convert-cut-env-to-run": "on",
"madrun/rename-series-to-run": "on",
"madrun/rename-eslint-to-putout": "on",
"madrun/set-lint-dot": "on",
"madrun/convert-to-async": "on",
"madrun/convert-nyc-to-c8": "on",
"madrun/set-report-lcov": "on",
"madrun/remove-check-duplicates-from-test": "on",
"madrun/remove-useless-array-in-run": "on",
"madrun/remove-useless-string-conversion": "on"
}
}
module.exports = {
hello: 'world',
};
module.exports = {
hello: () => 'world',
};
const {run} = require('madrun');
module.exports = {
lint: 'putout lib test',
};
const {run} = require('madrun');
module.exports = {
'lint': 'putout lib test',
'fix:lint': run('lint', '--fix'),
};
module.exports = {
lint: 'putout lib test',
};
const {run} = require('madrun');
module.exports = {
lint: 'putout lib test',
};
export default {
'test': () => [env, 'test:only'],
'test:only': () => [env, 'npm test'],
};
import {cutEnv} from 'madrun';
export default {
'test': async () => [testEnv, await cutEnv('test:only')],
'test:only': () => [env, 'npm test'],
};
module.exports = {
hello: () => run(['a']),
};
module.exports = {
hello: () => run('a'),
};
Check out in 🐊Putout Editor.
export default {
build: () => 'tsup',
wisdom: () => run('build', 'test', 'test:dts'),
};
export default {
build: () => 'tsup',
wisdom: () => run(['build', 'test', 'test:dts']),
};
export default {
'test': () => [env, 'npm test'],
'test:only': () => 'npm test',
'coverage': async () => [env, await run('test')],
'coverage:only': async () => [env, await run('test:only')],
};
export default {
'test': () => [env, 'npm test'],
'test:only': () => 'npm test',
'coverage': async () => [env, await cutEnv('test')],
'coverage:only': async () => [env, await run('test:only')],
};
export default {
'test': () => [env, 'npm test'],
'test:only': () => 'npm test',
'coverage': async () => [env, await cutEnv('test')],
'coverage:only': async () => [env, await cutEnv('test:only')],
};
export default {
'test': () => [env, 'npm test'],
'test:only': () => 'npm test',
'coverage': async () => [env, await cutEnv('test')],
'coverage:only': async () => [env, await run('test:only')],
};
module.exports = {
lint: 'eslint lib test --ignore test/fixture',
};
module.exports = {
lint: 'putout lib test',
};
module.exports = {
lint: 'putout lib test',
};
module.exports = {
lint: 'putout .',
};
module.exports = {
lint: () => String(run('hello')),
};
module.exports = {
lint: async () => String(await run('hello')),
};
export default {
coverage: () => 'nyc npm test',
report: () => `nyc report --reporter=text-lcov | coveralls`,
};
export default {
coverage: () => 'c8 npm test',
report: 'c8 report --reporter=lcov',
};
export default {
report: () => `c8 report --reporter=text-lcov | coveralls || true`,
};
export default {
report: 'c8 report --reporter=lcov',
};
export default {
test: () => 'tape -d *.js',
};
export default {
test: () => 'tape *.js',
};
Checkout in 🐊Putout Editor.
export default {
time: async () => await run(['lint:fresh', '-f time']),
};
export default {
time: async () => await run('lint:fresh', '-f time'),
};
Checkout in 🐊Putout Editor.
export default {
time: async () => [testEnv, String(await cutEnv('test:raw'))],
};
export default {
time: async () => [testEnv, await cutEnv('test:raw')],
};
export default {
coverage: async () => [env, `c8 ${await cutEnv('test')}`],
};
import {cutEnv} from 'madrun';
export default {
coverage: async () => [env, `c8 ${await cutEnv('test')}`],
};
MIT