Skip to content

Commit

Permalink
chore(scripts): improves scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
rafamel committed May 15, 2019
1 parent 49d5faf commit 7080443
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions kpo.scripts.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// prettier-ignore
const { series, parallel, ensure, line, json, log, confirm, rm, remove, copy, kpo, silent } = require('kpo');
const { series, parallel, ensure, line, json, log, confirm, rm, remove, kpo, silent } = require('kpo');
const path = require('path');
const bump = require('conventional-recommended-bump');
const { promisify } = require('util');
Expand All @@ -21,7 +21,7 @@ module.exports.scripts = {
build: {
default: kpo`validate build.force`,
force: series.env('kpo build.pack build.types', { NODE_ENV: 'production' }),
$pack: [ensure`./pkg`, 'pack build', copy(['.npmignore'], './pkg')].concat(
$pack: [ensure`./pkg`, 'pack build'].concat(
vars.node && [
line`babel src --out-dir ./pkg/dist-node
--extensions ${vars.dotExt} --source-maps inline`,
Expand Down Expand Up @@ -52,8 +52,10 @@ module.exports.scripts = {
});
}),
release: [
series('npm publish --dry-run', { cwd: './pkg' }),
confirm({ no: Error() }),
series('npm publish', { cwd: './pkg' }),
['git push', 'git push --tags']
series(['git push', 'git push --tags'], { args: [] })
],
watch: {
default: 'onchange ./src --initial --kill -- kpo watch.task',
Expand Down

0 comments on commit 7080443

Please sign in to comment.