File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change 10
10
11
11
'use strict' ;
12
12
13
+ const path = require ( 'path' ) ;
14
+
13
15
const updateNotifier = require ( 'update-notifier' ) ;
14
16
15
17
const packageInfo = require ( '../package.json' ) ;
16
18
const help = require ( './lib/help' ) ;
17
19
const events = require ( './lib/events' ) ;
18
20
const pe = require ( './lib/pattern_exporter' ) ;
21
+ const pm = require ( './lib/plugin_manager' ) ;
19
22
20
23
const defaultConfig = require ( '../patternlab-config.json' ) ;
21
24
@@ -154,7 +157,11 @@ const patternlab_module = function(config) {
154
157
* @returns {void }
155
158
*/
156
159
installplugin : function ( pluginName ) {
157
- patternlab . installPlugin ( pluginName ) ;
160
+ //get the config
161
+ const configPath = path . resolve ( process . cwd ( ) , 'patternlab-config.json' ) ;
162
+ const plugin_manager = new pm ( config , configPath ) ;
163
+
164
+ plugin_manager . install_plugin ( pluginName ) ;
158
165
} ,
159
166
160
167
/**
You can’t perform that action at this time.
0 commit comments