The configuration files are located in the publisher install path, under the folder "launch".
Note: If the installer (.exe) is used to install Publisher for Rhapsody, the folder "launch" is located in C:\ProgramData\Publisher4Rhapsody\%PUB_VERSION%\launch
,
otherwise, the folder "launch" is located in the same folder than the "publisher.exe" file.
Note: %PUB_VERSION%
corresponds to the Publisher Version, for example, 3.3.0
.
The provided MD2RhpSilent.bat file do the following actions:
To configure the MD2RhpSilent batch file - when installer has been used to install Publisher for Rhapsody :
REM The path to the folder level that contains the publisher.exe file
SET PUBLISHER_INSTALL_PATH=C:\Program Files\Publisher4Rhapsody\%PUB_VERSION%
REM The path to the Publisher properties
SET PUBLISHER_DATA_PATH=C:\ProgramData\Publisher4Rhapsody\%PUB_VERSION%\
REM The path to the folder level that contains the rhapsody.exe file
SET RHP_PATH=C:\Program Files\IBM\Rhapsody\10.0.1\
REM Define whether Rhapsody interface (UI) must be displayed or not.
SET HIDE_RHAPSODY_UI=false
REM Define the maximum amout of time to wait when starting Rhapsody.
SET START_RHAPSODY_TIMEOUT=120
REM The absolute path of the MagicDraw file that will be published.
SET MDZIP_PATH=%~1
REM The path of the new Rhapsody project folder. Note: If the folder already exists, the publication will not be completed to avoid the loss of data.
SET RHP_PROJECT_PATH=%~2
REM The name of the new Rhapsody project.
SET RHP_PROJECT_NAME=%~3
cd /d %PUBLISHER_INSTALL_PATH%
publisher.exe -headless -nosplash -launch "%PUBLISHER_DATA_PATH%\launch\MD2RhpSilent.main.launch" -args[0] "%RHP_PATH%" -args[1] "%HIDE_RHAPSODY_UI%" -args[2] "%START_RHAPSODY_TIMEOUT%" -args[3] "%RHP_PROJECT_PATH%" -args[4] "%RHP_PROJECT_NAME%" -args[5] "%MDZIP_PATH%" -silent
cd /d %PUBLISHER_DATA_PATH%\launch
PUBLISHER_INSTALL_PATH
, PUBLISHER_DATA_PATH
or RHP_PATH
are set as expected and update values as needed.
MDZIP_PATH
, RHP_PROJECT_PATH
and RHP_PROJECT_NAME
are declared as parameters of this script. If needed, they can be hard coded following the comment just above.
To configure the MD2RhpSilent batch file - when installer has not been used to install Publisher for Rhapsody :
REM The path to the folder level that contains the publisher.exe file
SET PUBLISHER_INSTALL_PATH=<current_publisher_path>
REM The path to the Publisher properties
SET PUBLISHER_DATA_PATH=<current_publisher_data_path>
REM The path to the folder level that contains the rhapsody.exe file
SET RHP_PATH=<rhapsody_path>
REM Define whether Rhapsody interface (UI) must be displayed or not.
SET HIDE_RHAPSODY_UI=false
REM Define the maximum amout of time (in second) to wait when starting Rhapsody.
SET START_RHAPSODY_TIMEOUT=120
REM The absolute path of the MagicDraw file that will be published.
SET MDZIP_PATH=%~1
REM The path of the new Rhapsody project folder. Note: If the folder already exists, the publication will not be completed to avoid the loss of data.
SET RHP_PROJECT_PATH=%~2
REM The name of the new Rhapsody project.
SET RHP_PROJECT_NAME=%~3
cd %PUBLISHER_INSTALL_PATH%
publisher.exe -headless -nosplash -launch "%PUBLISHER_DATA_PATH%\launch\MD2RhpSilent.main.launch" -args[0] "%RHP_PATH%" -args[1] "%HIDE_RHAPSODY_UI%" -args[2] "%START_RHAPSODY_TIMEOUT%" -args[3] "%RHP_PROJECT_PATH%" -args[4] "%RHP_PROJECT_NAME%" -args[5] "%MDZIP_PATH%" -silent
cd %PUBLISHER_DATA_PATH%\launch
SET PUBLISHER_INSTALL_PATH=C:\Program Files\Publisher4Rhapsody\%PUB_VERSION%
SET PUBLISHER_DATA_PATH=C:\ProgramData\Publisher4Rhapsody\%PUB_VERSION%
SET RHP_PATH=C:\Program Files\IBM\Rhapsody\10.0.1\
To run the script, you have by default to give it three parameters:
To test the modifications you can run the launch configuration from the publisher. Follow these steps:
true
if the Rhapsody interface (UI) must be displayed, false
otherwise.