File tree 3 files changed +11
-8
lines changed
3 files changed +11
-8
lines changed Original file line number Diff line number Diff line change @@ -40,9 +40,9 @@ program
40
40
. option ( '-c, --clear [serve/dist]' )
41
41
. option ( '-cr, --create [serve/dist]' )
42
42
. parse ( process . argv ) ;
43
-
43
+ const options = program . opts ( ) ;
44
44
for ( const commandName in commands ) {
45
- if ( commands . hasOwnProperty ( commandName ) && program [ commandName ] ) {
46
- commands [ commandName ] ( program [ commandName ] ) ;
45
+ if ( commands . hasOwnProperty ( commandName ) && options [ commandName ] ) {
46
+ commands [ commandName ] ( options [ commandName ] ) ;
47
47
}
48
48
}
Original file line number Diff line number Diff line change @@ -73,8 +73,9 @@ const commands = {
73
73
removePlugin : function ( pluginName ) {
74
74
try {
75
75
const pluginsPath = dirParamToPath ( 'plugins' )
76
- const pluginPathInRepo = path . join ( pluginsPath , pluginName )
77
-
76
+ const pluginDirName = path . dirname ( pluginsObj . filter ( ele => ele . key === pluginName ) [ 0 ] . metadataFile ) . replace ( './' , '' )
77
+ const pluginPathInRepo = path . join ( pluginsPath , pluginDirName )
78
+
78
79
if ( fse . existsSync ( pluginPathInRepo ) ) {
79
80
rimraf . sync ( pluginPathInRepo )
80
81
fse . writeFileSync (
@@ -116,10 +117,10 @@ program
116
117
. option ( '-ap, --addPlugin []' )
117
118
. option ( '-rp, --removePlugin []' )
118
119
. parse ( process . argv )
119
-
120
+ const options = program . opts ( ) ;
120
121
for ( const commandName in commands ) {
121
122
// eslint-disable-next-line no-prototype-builtins
122
- if ( commands . hasOwnProperty ( commandName ) && program [ commandName ] ) {
123
- commands [ commandName ] ( program [ commandName ] )
123
+ if ( commands . hasOwnProperty ( commandName ) && options [ commandName ] ) {
124
+ commands [ commandName ] ( options [ commandName ] )
124
125
}
125
126
}
Original file line number Diff line number Diff line change @@ -49,3 +49,5 @@ To add/remove Admin UI, on vm execute -
49
49
50
50
2. Execute
51
51
`python3 /opt/jans/jans-setup/static/scripts/admin_ui_plugin.py`
52
+
53
+ The available plugins can be downloaded from https://jenkins.gluu.org/npm/admin_ui/<git-branch-name>
You can’t perform that action at this time.
0 commit comments