Skip to content

Commit 94738d0

Browse files
committed
ST6RI-178 Revised help messages for %load, %projects and %publish.
1 parent 131f3ab commit 94738d0

1 file changed

Lines changed: 18 additions & 12 deletions

File tree

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

Lines changed: 18 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*******************************************************************************
22
* SysML 2 Pilot Implementation
3-
* Copyright (c) 2021 Model Driven Solutions, Inc.
3+
* Copyright (c) 2021, 2025 Model Driven Solutions, Inc.
44
* Copyright (c) 2021 Twingineer LLC
55
* Copyright (c) 2022 Mgnite Inc.
66
*
@@ -42,7 +42,7 @@ public class SysMLInteractiveHelp {
4242
+ "%export\t\tSave a file of the JSON representation of the abstract syntax tree rooted in the named element.\n"
4343
+ "%help\t\tGet a list of available commands or help on a specific command\n"
4444
+ "%list\t\tList loaded library packages or the results of a given query\n"
45-
+ "%load\tLoads a model from the repository and adds it to the Xtext index\n"
45+
+ "%load\t\tLoad a model from the repository\n"
4646
+ "%show\t\tPrint the abstract syntax tree rooted in a named element\n"
4747
+ "%projects\tList projects in the repository\n"
4848
+ "%publish\tPublish to the repository the modele elements rooted in a named element\n"
@@ -79,11 +79,15 @@ public class SysMLInteractiveHelp {
7979
+ " JSON\t\tComplete JSON representation of the tree\n";
8080

8181
private static final String PUBLISH_HELP_STRING =
82-
"Usage: %publish <NAME>\n\n"
82+
"Usage: %publish [-d] [--project=<PROJECT NAME>] [--branch=<BRANCH NAME>] <NAME>\n\n"
8383
+ "Publish the model elements rooted in <NAME> to the repository. <NAME> must be fully qualified.\n"
84-
+ "Use the --project parameter to specify a project to create or update. If not specified, a new project is created with the name of the model element and a timestamp.\n"
85-
+ "Use the -d flag to include derived properties\n"
86-
+ "(Experimental) Use --branch to specify the target branch name. If not specified, the default branch is selected.\n";
84+
+ "Use the -d flag to include derived properties.\n"
85+
+ "If <PROJECT NAME> is given, it is used as the name of the project to create or update.\n"
86+
+ "If <PROJECT NAME> is not given, the (simple) name of the model element is used.\n"
87+
+ " If no project exits with the given name, then a new project with that name is created.\n"
88+
+ " Otherwise, a new project is created with the given name.\n"
89+
+ "If <BRANCH NAME> is given, then the model is written to this branch of the project.\n"
90+
+ "If <BRANCH NAME> is not given, the default branch is used.\n";
8791

8892
private static final String VIZ_HELP_STRING =
8993
"Usage: %viz [--view=<VIEW>] [--style=<STYLE>...] <NAME> [<NAME>...]\n\n"
@@ -123,15 +127,17 @@ public class SysMLInteractiveHelp {
123127
+ "<NAME> must be fully qualified.\n";
124128

125129
private static final String LOAD_HELP_STRING =
126-
"Usage: %load [--branch=<BRANCH_NAME>] [--id=<PROJECT ID] [--name=<NAME>] [<NAME>]\n\n"
127-
+ "Downloads previously published models from the repository. <NAME> must be the full name of the project.\n"
128-
+ "Use --id=<PROJECT ID> to load projects by id. It is not supported to provide both id and name.\n"
129-
+ "(Experimental) Use --branch=<BRANCH_NAME> to select the branch to load from. If not specified, the default branch is used.\n"
130-
+ "Use %projects to view repository contents.\n";
130+
"Usage: %load [--id=<PROJECT ID] [--name=<NAME>] [--branch=<BRANCH_NAME>] [<NAME>]\n\n"
131+
+ "Download previously published models from a project in the repository. <NAME> is the full name of the project.\n"
132+
+ "Named elements of the downloaded models may then be referenced models in the notebook."
133+
+ "(Use %projects to view repository contents.)\n"
134+
+ "If <PROJECT ID> is given, then the project with that UUID is loaded. In this case, the <NAME> must not be given.\n"
135+
+ "If <BRANCH NAME> is given, then the model is loaded from this branch of the project.\n"
136+
+ "If <BRANCH NAME> is not given, the default branch is used.\n";
131137

132138
private static final String PROJECTS_HELP_STRING =
133139
"Usage: %projects\n\n"
134-
+ "Returns the name and identifier from the repository for all publications\n";
140+
+ "Print the name and identifier of all projects in the repository.\n";
135141

136142
public static String getGeneralHelp() {
137143
return GENERAL_HELP_STRING;

0 commit comments

Comments
 (0)