@@ -5,17 +5,16 @@ const updateNotifier = require('update-notifier');
5
5
const meow = require ( 'meow' ) ;
6
6
const mobicon = require ( 'mobicon' ) ;
7
7
const logSymbols = require ( 'log-symbols' ) ;
8
- const chalk = require ( 'chalk' ) ;
9
8
10
9
const cli = meow ( `
11
10
Usage
12
11
$ mobicon <file>
13
12
14
13
Options
15
- -p , --platform Platform to generate icons for
16
- -b , --background Color of the icon background if the icon is transparant [Default: white]
17
- -r , --contentRatio Logo-icon ratio [Default: 1]
18
- -o , --out Output directory [Default: cwd]
14
+ --platform , -p Platform to generate icons for
15
+ --background , -b Color of the icon background if the icon is transparant [Default: white]
16
+ --contentRatio , -r Logo-icon ratio [Default: 1]
17
+ --out , -o Output directory [Default: cwd]
19
18
20
19
Examples
21
20
$ mobicon icon.png -p=android
@@ -69,9 +68,14 @@ Promise.all(platforms.map(platform => {
69
68
dest = path . join ( dest , platform ) ;
70
69
}
71
70
72
- return mobicon ( cli . input [ 0 ] , { platform, dest, background : cli . flags . background , contentRatio : cli . flags . contentRatio } ) ;
71
+ return mobicon ( cli . input [ 0 ] , {
72
+ platform,
73
+ dest,
74
+ background : cli . flags . background ,
75
+ contentRatio : cli . flags . contentRatio
76
+ } ) ;
73
77
} ) ) . then ( ( ) => {
74
78
console . log ( ` ${ logSymbols . success } success` ) ;
75
79
} ) . catch ( error => {
76
- console . log ( ` ${ logSymbols . error } ${ chalk . bold . red ( 'error' ) } ${ error . message } ` ) ;
80
+ console . log ( ` ${ logSymbols . error } ${ error . message } ` ) ;
77
81
} ) ;
0 commit comments