-
-
Notifications
You must be signed in to change notification settings - Fork 3
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
v3 major release #95
Labels
Comments
example shareable config of commands/tasks // the v3 hela
import { hela, shell, exec } from 'hela';
// returns instance of `sade`
const cli = hela()
export const commit = cli
.command('commit')
.describe('All original `git commit` flags are available, plus 3 more - scope, body & footer')
.option('--gpg-sign, -S', 'GPG-sign commits', true)
.option('--signoff, -s', 'Add Signed-off-by line by the committer at the end', true)
.option('--scope, -x', 'Prompt a question for commit scope', false)
.option('--body, -y', 'Prompt a question for commit body', false)
.option('--footer, -w', 'Prompt a question for commit footer', false)
// allows AsyncFunction, Function, String and Array to be passed
// if function, it also can return promise, string or array.
.action('gitcommit');
/**
*
*/
export const test = cli
.command('test')
.describe('Run all tests from test directory')
.option('--coverage, --cov', 'Run with coverage', true)
.option('--check', 'Run checking coverage threshold', true)
.option('--build, -b', 'Run with build step', true)
.action((argv) => shell([ 'echo "start testing.."', 'node test' ]));
/**
*
*/
export const lint = cli
.command('lint <src>')
.describe('Lint and prettify the src and test files')
.option('--fix', 'Auto fixing', true)
.action((src, argv) => {
console.log('lint task', src, argv)
return 'echo "lint task is done"';
}) |
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
resolve-plugins
andplugins-resolver
Working implementation, and illustrative command/task config definition
hela v3:
Latest update. Couple of fixes and rethinkings.
@hela/core
@hela/cli
The text was updated successfully, but these errors were encountered: