Skip to content

Commit d73ece4

Browse files
committed
ST6RI-178 Added base path and branch ID to messages for %load.
1 parent 6fa6377 commit d73ece4

1 file changed

Lines changed: 6 additions & 5 deletions

File tree

org.omg.sysml.interactive/src/org/omg/sysml/interactive/SysMLInteractive.java

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@
7373
import org.omg.sysml.lang.sysml.util.SysMLLibraryUtil;
7474
import org.omg.sysml.plantuml.SysML2PlantUMLLinkProvider;
7575
import org.omg.sysml.plantuml.SysML2PlantUMLSvc;
76-
import org.omg.sysml.util.NamespaceUtil;
7776
import org.omg.sysml.util.SysMLUtil;
7877
import org.omg.sysml.util.TypeUtil;
7978
import org.omg.sysml.util.repository.EObjectUUIDTracker;
@@ -375,7 +374,7 @@ else if (matchStyle(styles, "JSON")) {
375374
else if (styles.isEmpty() || matchStyle(styles, "TREE")){
376375
return SysMLInteractiveUtil.formatTree(element);
377376
} else {
378-
return "ERROR:Invalid style. Possible styles: TREE and JSON";
377+
return "ERROR:Invalid style. Possible styles: TREE and JSON\n";
379378
}
380379
} catch (Exception e) {
381380
return SysMLInteractiveUtil.formatException(e);
@@ -474,11 +473,11 @@ public String load(Map<String, String> parameters) {
474473
}
475474

476475
if (parameters.containsKey(PROJECT_ID_KEY) && parameters.containsKey(PROJECT_NAME_KEY)) {
477-
return "ERROR:Name and id cannot be provided at the same time.";
476+
return "ERROR:Project name and id cannot be provided at the same time\n";
478477
}
479478

480479
if (parameters.containsKey(BRANCH_ID_KEY) && parameters.containsKey(BRANCH_NAME_KEY)) {
481-
return "ERROR:Branch name and branch id cannot be provided at the same time";
480+
return "ERROR:Branch name and id cannot be provided at the same time\n";
482481
}
483482

484483
final ProjectRepository repository = new ProjectRepository(apiBasePath);
@@ -519,7 +518,9 @@ private String load(RemoteBranch branch) {
519518
return "ERROR:Branch doesn't exist\n";
520519
}
521520

522-
System.out.println("Selected branch " + branch.getName());
521+
System.out.println("API base path: " + apiBasePath);
522+
System.out.println();
523+
System.out.println("Selected branch " + branch.getName() + " (" + branch.getRemoteId().toString() + ")");
523524

524525
if (!tracker.isLibraryTracked()) {
525526
System.out.println("Caching library UUIDs...");

0 commit comments

Comments
 (0)