@@ -119,7 +119,7 @@ def ensureLocalMavenRepo(self):
119
119
self .fail ("'org.graalvm.maven.downloader.repository' is not defined" )
120
120
121
121
def clearCache (self ):
122
- command = [JBANG_CMD , "cache" , "clear" ]
122
+ command = [JBANG_CMD , "cache" , "--verbose" , " clear" ]
123
123
out , result = run_cmd (command )
124
124
125
125
def getCatalogFile (self ):
@@ -163,19 +163,13 @@ def addLocalMavenRepo(self, file):
163
163
164
164
def registerCatalog (self , catalog_file ):
165
165
# we need to be sure that the current dir is not dir, where is the catalog defined
166
-
167
- # find if the catalog is not registered
168
- command = [JBANG_CMD , "catalog" , "list" ]
166
+ command = [JBANG_CMD , "catalog" , "remove" , "--verbose" , CATALOG_ALIAS ]
169
167
out , result = run_cmd (command , cwd = WORK_DIR )
170
- if result == 0 :
171
- if CATALOG_ALIAS not in out :
172
- # registering our catalog
173
- command = [JBANG_CMD , "catalog" , "add" , "--name" , CATALOG_ALIAS , catalog_file ]
174
- out , result = run_cmd (command , cwd = WORK_DIR )
175
- if result != 0 :
176
- self .fail (f"Problem during registering catalog: { out } " )
177
- else :
178
- self .fail (f"Problem during registering catalog: { out } " )
168
+
169
+ command = [JBANG_CMD , "catalog" , "add" , "--verbose" , "--name" , CATALOG_ALIAS , catalog_file ]
170
+ out , result = run_cmd (command , cwd = WORK_DIR )
171
+ if result != 0 :
172
+ self .fail (f"Problem during registering catalog: { out } " )
179
173
180
174
def prepare_hello_example (self , work_dir ):
181
175
hello_java_file = os .path .join (work_dir , "hello.java" )
0 commit comments