On this page
| Table of Contents | ||
|---|---|---|
|
Publishing Cameo Collaborator documents is the simplest way to present models to stakeholders, sponsors, customers, and engineering teams. Cameo Collaborator documents can be used not only to review model information and provide feedback but also to edit models directly from the web without using a modeling tool.
This chapter explains how to publish documents from the command line, which is useful if you want to publish them periodically, e.g., once a day or during non-business hours to save time.
| Note | ||
|---|---|---|
| ||
|
| Tip | ||
|---|---|---|
| ||
|
| Tip | ||
|---|---|---|
| ||
|
| Info | ||
|---|---|---|
| ||
When you publish a new document with the Administer Resources permission, it inherits Magic Collaboration Studio project permissions. When you update a document, project permissions are not affected. |
Publishing from the command-line interface consists of these steps:
- Publishing from command line#Configuring Configuring publishing options
- Publishing from command line#Publishing a Cameo Collaborator document or scheduling publishing as a background task
Configuring publishing options
Before publishing a project from the command line interface, specify publishing properties by modifying a properties file. You can modify the file for every model you publish or reuse it for several models if you do not need to change the values of publishing properties.
To configure the properties for publishing to Cameo Collaborator
- In the <modeling tool installation directory>/plugins/com.nomagic.collaborator.publisher directory, open for editing the template.properties file.
Read the comments in the file and specify the publishing options.
Publishing a Cameo Collaborator document
To publish a Cameo Collaborator document from the command line interface, you need to execute a specific command outlined below.
To publish a Cameo Collaborator document from the command line interface
- Open the command line interface.
Go to the <modeling tool installation directory>/plugins/com.nomagic.collaborator.publisher directory containing the executive file for model publishing.
Execute the following command:
On Windows
Code Block publish.exe properties=<modeling_tool_installation_directory>\plugins\com.nomagic.collaborator.publisher\template.properties
On OS X or Linux
Code Block ./publish properties=<modeling_tool_installation_directory>/plugins/com.nomagic.collaborator.publisher/template.properties
After completing the steps above, your model is published to Cameo Collaborator. If you want to publish the same model frequently, you do not need to do it manually every time. Instead, schedule publishing as a background task to save time.
| Tip | ||
|---|---|---|
| ||
When publishing, all information is logged to the log file of your modeling tool. If you want the information to be logged to the command line interface, open the <modeling_tool_intallation_directory>\plugins\com.nomagic.collaborator.publisher\publish.properties file and add -verbose to the APP_ARGS line. |
Scheduling to publish a document
If you need to publish your models periodically and/or during non-business hours, you can schedule them to be published automatically. The following procedures describe the scheduling process on Windows and Linux operating systems.
To schedule a publishing task on Windows
- Open the Task Scheduler from the Start menu of your Windows computer and select the option to create a basic task.
- Type the task name, an optional description and click Next.
- Select how often you want the task to reoccur and click Next.
- Specify when you want the task to start and click Next.
To schedule the publishing to start automatically, select the Start a program radio button and click Next.
Click the Browse button, go to the <modeling tool installation directory>/plugins/com.nomagic.collaborator.publisher directory, and open the publish.exe file.
In the Add Arguments (optional) box box, type -properties type properties=<modeling_tool_installation_directory>\plugins\com.nomagic.collaborator.publisher\template.properties and click Next.
- Click Finish.
To schedule a publishing task on Linux
- Connect to the remote server using SSH, or open the terminal directly.
Type the following command to open the crontab file with the default text editor:
# crontab -e
Using the Cron syntax create a cronjob to run the model publishing task once a day at midnight:
0 0 * * * <modeling tool installation directory>/plugins/com.nomagic.collaborator.publisher/publish.sh -properties template.properties
Save the crontab file.
After completing the steps described above, your model is published automatically on a regular basis at a specified time.
Improving publishing performance
You can improve publishing performance by changing environment options in your modeling tool, as described below.
To improve publishing performance
- In the main menu of your modeling tool, select Options > Environment.
- On the left side of the Environment Options dialog, select the Collaboration option group.
- On the right side of the dialog, set the Notify About New Project Versions on the Server option to false.
- On the right side of the dialog, set the Notify About Newer Project Usages option to Never.
- Click OK.
Now Magic Collaboration Studio will use fewer connections when publishing, so the publishing performance will improve.
Changing the highlighted environment options improves publishing performance.
Related pages
Publishing documentsPublishing from graphical user interface

