UNPKG
chanlog
Version:
latest (1.0.1)
1.0.1
1.0.0
0.0.2
0.0.1
A beautiful tool to make changelog file
chanlog
/
lib
/
utils
/
print-error.js
13 lines
(10 loc)
•
236 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
const
chalk =
require
(
'chalk'
)
module
.
exports
=
function
(
args, msg, opts
) {
if
(!args.
silent
) { opts =
Object
.
assign
({
level
:
'error'
,
color
:
'red'
}, opts)
console
[opts.
level
](chalk[opts.
color
](msg)) } }