Enter the terminal, select an empty directory, and execute the following command to download xworker.jar.
$ curl https://www.xworker.org/files/xworker.jar
Use the following command to execute xworker.jar and automatically download XWorker after execution.
$ java -jar xworker.jar
Executing the script below will create a link to dml.sh for /usr/bin and associate file *.dml to dml.sh.
$ ./setupenv.sh
The following script will update the XWorker to the latest version.
$ ./update.sh
XWorker will index the model to the database, and usually update the index automatically when you download and update the XWorker, and if you want to manually update the index, the following command can be executed.
$ ./upidx.sh
Open Finider, find Automator and open it in the application.
Select the application.
Find Shell script running on the left side, double-click to the right.
As above:
After the setup is completed, save it as an application.
Save swthloworld.dm as swthloworld.dml, select open mode, and select other.
Remember to open the hook in this way.
After setting up, open the application, or double click SwtHelloWorld.dml. If the following window is opened, the file association is successful.
With the above file association method model running, there is no console, and the output of the console can not be viewed. If you know how to set up, please contact us.
Modify the dml.conf.sh script to remove the annotation ‘JAVA_OPTS="-XstartOnFirstThread"’of this line.
# JAVA_OPTS="-XstartOnFirstThread"
XWorker uses SWT to write the interface. If you have problems with SWT, please refer to https://www.eclipse.org/swt/faq.php.
If you need to modify the startup parameters of xworker, you can edit the dml.conf.sh file.
The web server started by xworker is HTTP by default. If you need to switch to HTTPS, you can run thingexplorer.sh first, open and close the interface, and then modify the projects/_local/ things/_local /xworker/config/globalconfig.dml file in xwork directory.
If the GlobalConfig.dml format is properties, then two lines of swebSSL and true, and modify http://localhost: 9001 to HTTPS://localhost: 9001:
@ swebSSL true ...... webUrl https://localhost:9001
If the GlobalConfig.dml format is XML, add the webSSL attribute and modify the value of the webUrl attribute to HTTPS://localhost: 9001:
<?xml version="1.0" encoding="utf-8"?> <GlobalConfg name="GlobalConfg" descriptors="xworker.ide.config.decriptors.GlobalConfig" webSSL="true" webUrl="https://localhost:9001/" webDebug="false" .../>
The certificate is in xworker directory, enter xworker installation directory in the terminal, and execute the following command to import the certificate.
sudo security add-trusted-cert -d -r trustRoot -k /Library/Keychains/System.keychain config/jetty/cert.crt
Copyright © 2007-2019 XWorker.org 版权所有 沪ICP备08000575号