Skip to content

Commit

Permalink
refactor: use chalk instead of colors (#92)
Browse files Browse the repository at this point in the history
  • Loading branch information
zacharygolba committed May 18, 2016
1 parent 786872b commit 71f4593
Show file tree
Hide file tree
Showing 11 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"ansi-regex": "2.0.0",
"babel-runtime": "6.9.0",
"bluebird": "3.4.0",
"colors": "1.1.2",
"chalk": "1.1.3",
"commander": "2.9.0",
"inflection": "1.10.0",
"moment": "2.13.0",
Expand Down
2 changes: 1 addition & 1 deletion src/errors/module-missing.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { red, green } from 'colors/safe';
import { red, green } from 'chalk';

import { line } from '../packages/logger';

Expand Down
2 changes: 1 addition & 1 deletion src/packages/cli/commands/create.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Ora from 'ora';
import { green } from 'colors/safe';
import { green } from 'chalk';

import fs from '../../fs';

Expand Down
2 changes: 1 addition & 1 deletion src/packages/cli/commands/destroy.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { red } from 'colors/safe';
import { red } from 'chalk';
import { pluralize } from 'inflection';

import fs from '../../fs';
Expand Down
2 changes: 1 addition & 1 deletion src/packages/cli/commands/generate.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import moment from 'moment';
import { green } from 'colors/safe';
import { green } from 'chalk';
import { pluralize } from 'inflection';

import fs from '../../fs';
Expand Down
2 changes: 1 addition & 1 deletion src/packages/cli/commands/serve.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import os from 'os';
import cluster from 'cluster';

import { cyan } from 'colors/safe';
import { cyan } from 'chalk';

import Logger from '../../logger';

Expand Down
2 changes: 1 addition & 1 deletion src/packages/database/errors/invalid-driver.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { green, yellow } from 'colors/safe';
import { green, yellow } from 'chalk';

import { VALID_DRIVERS } from '../constants';

Expand Down
2 changes: 1 addition & 1 deletion src/packages/database/errors/migrations-pending.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { green, yellow } from 'colors/safe';
import { green, yellow } from 'chalk';

import { line } from '../../logger';

Expand Down
2 changes: 1 addition & 1 deletion src/packages/logger/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import moment from 'moment';
import { dim, red, yellow } from 'colors/safe';
import { dim, red, yellow } from 'chalk';

import fs from '../fs';

Expand Down
8 changes: 4 additions & 4 deletions src/packages/server/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import http from 'http';
import { parse as parseURL } from 'url';

import colors from 'colors/safe';
import chalk, { cyan } from 'chalk';

import Base from '../base';
import Session from '../session';
Expand Down Expand Up @@ -67,10 +67,10 @@ class Server extends Base {
}

this.logger.log(line`
${colors.cyan(`${method}`)} ${url.pathname} -> Finished after
${cyan(`${method}`)} ${url.pathname} -> Finished after
${new Date().getTime() - startTime.getTime()} ms with
${colors[statusColor].call(null, `${statusCode}`)}
${colors[statusColor].call(null, `${statusMessage}`)}
${chalk[statusColor].call(null, `${statusCode}`)}
${chalk[statusColor].call(null, `${statusMessage}`)}
`);
});
}
Expand Down
2 changes: 1 addition & 1 deletion test/test-app/config/environments/development.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export default {
log: false,
log: true,
domain: 'http://localhost:4000',
sessionKey: 'test-app::development::session',
sessionSecret: '73689ad1adec9d7f055c41de52e415b9678f0ad421579d471038519372b4522e'
Expand Down

0 comments on commit 71f4593

Please sign in to comment.