This software is licensed under the GNU Lesser General Public License. See the files LICENSE and LICENSE-GPL.
The project provides a configuration file for the Eclipse Installer which eases the creation of reproducible development environments.
-
Download the Eclipse Installer from
https://www.eclipse.org/downloads/packages/installer
. -
Clone our GitHub repository from the URL below.
-
Open Eclipse Installer and switch to Advanced mode:
-
In the product list, select "Eclipse Modeling Tools" with Product Version: 2024-03.
-
In the Projects window, to the right of the text box, click the "+" to the add the Sysml2 project as user project. In the dialog, choose Catalog: Github Projects and browse the file system to select the setup file from the local git repository.
-
e.g.
file:/C:/git/sysml/SysML-v2-Pilot-Implementation/org.omg.sysml.installer/SysML2.setup
-
Note: If you have installed the SysML v2 Pilot Implementation previously, this may already be pre-selected.
-
-
Select SysML2 in the Projects list:
-
On the next page, update the following variables, then press Next.
-
Git clone location rule: Select "Located in specific absolute folder location" and browse to the directory for the SysML git repository.
-
Root install folder: Change this if you wish the installation to be under a specific folder.
-
Workspace location rule: Change this if you wish to place the workspace at a specific location.
-
-
On the Confirmation page, press Finish.
-
(Optional) For PlantUML visualization, GraphViz is needed. Visit https://www.graphviz.org/download/ and download the appropriate package for your environment.
-
In the menu of Window > Preferences > PlantUML in Eclipse environment, you may set up the path to GraphViz executable if Eclipse cannot automatically find it. For detail, visit https://plantuml.com/en/eclipse
-
-
Install Eclipse 2024-03 (4.25) and Xtext.
-
Install the “Eclipse Modeling Tools” package.
-
To install Xtext, select Help > Install New Software, use the update site URL given below, and install “Xtext Complete SDK” (under General Purpose Tools).
-
(Optional) For PlantUML visualization, you need to install PlantUML-Eclipse with SysMLv2 extensions from the update site of
https://github.com/himi/p2-update-puml-sysmlv2/raw/main/updates
with Help > Install New Software.
-
-
Clone our GitHub repository from the URL below.
-
Import projects from the repository into your Eclipse workspace. This should include at least the projects:
-
org.omg.sysml
-
org.omg.kerml.expressions.xtext
-
org.omg.kerml.expressions.xtext.ide
-
org.omg.kerml.expressions.xtext.ui
-
org.kerml.xtext
-
org.kerml.xtext.ide
-
org.kerml.xtext.ui
-
org.sysml.xtext
-
org.sysml.xtext.ide
-
org.sysml.xtext.ui
-
Note:
-
Gradle is used to build project
org.omg.sysml.jupyter
. -
Maven is used to perform a coordinated build of all projects (including packaging the SysML Interactive JAR file that is used by
org.omg.sysml.jupyter
). -
To build the repository, invoke
mvn clean package
from the baseSysML-v2-Pilot-Implementation
directory. -
If you have M2Eclipse installed (with the Tycho Project Configurators connector), it can also launch a Maven build in Eclipse using the launch configuration in
SysML-v2-Pilot-Implementation/launch
.
-
Find the file
org.omg.kerml.expressions.xtext/src/org.omg.kerml.expressions.xtext/KerMLExpressions.xtext
, right click on it, and select Run As > Generate Xtext Artifacts, to execute the Xtext generator. Repeat withorg.omg.kerml.xtext/src/org.omg.kerml.xtext/KerML.xtext
andorg.omg.sysml.xtext/src/org.omg.sysml.xtext/SysML.xtext
. -
Once the generation is complete, right click on project
org.omg.sysml
, and select Run As > Eclipse Application. This should launch a new runtime Eclipse instance. -
Add the SysML-v2-Pilot-Implementation Git repository (already cloned previously) to the runtime Eclipse instance.
-
Turn off Project > Build Automatically.
-
Import the projects
kerml
,sysml
andsysml.library
into the runtime Eclipse workspace. (See the following section if you wish to create additional projects.) -
Execute Project > Clean with the following settings:
-
Clean all projects: Not selected
-
sysml.library
: Selected -
Start a build immediately: Selected
-
Build only the selected projects: Selected
-
-
Repeat Project > Clean as above for
kerml
andsysml
.-
Important: Be sure to first build only
sysml.library
before buildingkerml
orsysml
.
-
-
Double clicking on any
.kerml
or.sysml
file will open it in the generated Xtext KerML or SysML editor. -
(Optional) To show SysML diagrams, in Window > Show View > Other… menu, you can enable PlantUML view.
-
Open the New project wizard by selecting File > New > Project… menu item.
-
Select General/Project.
-
Give the project its expected name (and location if necessary), then press Next.
-
On the Project References page, check the
sysml.library
project. This step tells Eclipse which other projects should be visible for resolving cross-references. -
Right-click the new project and select Configure > Convert to an Xtext project. This step sets up the indexing infrastructure necessary for resolving references between different files.
-
Create any text files with
.kerml
or.sysml
extensions to start working with a new file.
Note: Adding the project references to an existing project can be done in the project Properties dialog available from the popup menu on the project in the Project References page.
Note: If the Xtext setup (step 5) is missing, opening the KerML or SysML editor shows a dialog asking to convert the project to an Xtext project. Accepting this has the same results as manually selecting the menu item on the project.
Set up a Java code template as follows:
-
Window > Preferences (Mac-OS: Eclipse > Preferences)
-
Java > Code Style > Code Templates
-
Code > New Java files > Edit
-
Prepend (insert above the existing content) the following and modify the second line:
/** * SysML 2 Pilot Implementation * Copyright (C) 2020 California Institute of Technology ("Caltech") * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public License * along with this program. If not, see <https://www.gnu.org/licenses/>. * * @license LGPL-3.0-or-later <http://spdx.org/licenses/LGPL-3.0-or-later> */
-
Apply > OK
-
When modifying existing code created by someone in a different organization, add a new copyright line, without changing anything else in the header.
-
When modifying existing code for the first time in a new year, add the year as the latest year in the appropriate copy right line. (E.g., in 2021, "Copyright © 2020" becomes "Copyright © 2020-2021" and in 2022 it becomes "Copyright © 2020-2022".)