chore(): update deps

This commit is contained in:
Manu Mtz.-Almeida
2018-07-29 01:44:45 +02:00
parent 7813acc86f
commit b69098a77d
7 changed files with 40 additions and 45 deletions

View File

@@ -3,7 +3,7 @@ const path = require('path');
const execa = require('execa');
const Listr = require('listr');
const semver = require('semver');
const chalk = require('chalk');
const tc = require('turbocolor');
const rootDir = path.join(__dirname, '../');
@@ -132,7 +132,7 @@ function preparePackage(tasks, package, version) {
// Add project tasks
tasks.push({
title: `Prepare ${chalk.bold(pkg.name)}`,
title: `Prepare ${tc.bold(pkg.name)}`,
task: () => new Listr(projectTasks)
});
}

View File

@@ -2,7 +2,7 @@
* Deploy script adopted from https://github.com/sindresorhus/np
* MIT License (c) Sindre Sorhus (sindresorhus.com)
*/
const chalk = require('chalk');
const tc = require('turbocolor');
const execa = require('execa');
const inquirer = require('inquirer');
const Listr = require('listr');
@@ -30,7 +30,7 @@ async function main() {
console.log(` npm run release\n`);
} catch(err) {
console.log('\n', chalk.red(err), '\n');
console.log('\n', tc.red(err), '\n');
process.exit(1);
}
}
@@ -80,7 +80,7 @@ async function askVersion() {
type: 'confirm',
name: 'confirm',
message: answers => {
return `Will bump from ${chalk.cyan(oldVersion)} to ${chalk.cyan(answers.version)}. Continue?`;
return `Will bump from ${tc.cyan(oldVersion)} to ${tc.cyan(answers.version)}. Continue?`;
}
}
];
@@ -125,7 +125,7 @@ async function preparePackages(packages, version) {
function validateGit(tasks, version) {
tasks.push(
{
title: `Validate git tag ${chalk.dim(`(v${version})`)}`,
title: `Validate git tag ${tc.dim(`(v${version})`)}`,
task: () => execa('git', ['fetch'])
.then(() => {
return execa.stdout('npm', ['config', 'get', 'tag-version-prefix']);
@@ -161,7 +161,7 @@ function updatePackageVersion(tasks, package, version) {
tasks.push(
{
title: `${pkg.name}: update package.json ${chalk.dim(`(${version})`)}`,
title: `${pkg.name}: update package.json ${tc.dim(`(${version})`)}`,
task: async () => {
await execa('npm', ['version', version], { cwd: projectRoot });
}
@@ -207,17 +207,17 @@ function prettyVersionDiff(oldVersion, inc) {
for (let i = 0; i < newVersion.length; i++) {
if ((newVersion[i] !== oldVersion[i] && !firstVersionChange)) {
output.push(`${chalk.dim.cyan(newVersion[i])}`);
output.push(`${tc.dim.cyan(newVersion[i])}`);
firstVersionChange = true;
} else if (newVersion[i].indexOf('-') >= 1) {
let preVersion = [];
preVersion = newVersion[i].split('-');
output.push(`${chalk.dim.cyan(`${preVersion[0]}-${preVersion[1]}`)}`);
output.push(`${tc.dim.cyan(`${preVersion[0]}-${preVersion[1]}`)}`);
} else {
output.push(chalk.reset.dim(newVersion[i]));
output.push(tc.reset.dim(newVersion[i]));
}
}
return output.join(chalk.reset.dim('.'));
return output.join(tc.reset.dim('.'));
}
main();

View File

@@ -2,7 +2,7 @@
* Deploy script adopted from https://github.com/sindresorhus/np
* MIT License (c) Sindre Sorhus (sindresorhus.com)
*/
const chalk = require('chalk');
const tc = require('turbocolor');
const execa = require('execa');
const Listr = require('listr');
const octokit = require('@octokit/rest')()
@@ -34,7 +34,7 @@ async function main() {
console.log(`\nionic ${version} published!! 🎉\n`);
} catch (err) {
console.log('\n', chalk.red(err), '\n');
console.log('\n', tc.red(err), '\n');
process.exit(1);
}
}
@@ -75,7 +75,7 @@ function publishGit(tasks, version, changelog) {
tasks.push(
{
title: `Tag latest commit ${chalk.dim(`(${tag})`)}`,
title: `Tag latest commit ${tc.dim(`(${tag})`)}`,
task: () => execa('git', ['tag', `${tag}`], { cwd: common.rootDir })
},
{