User Tools

Site Tools


eclipse_setup

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
eclipse_setup [2021/02/09 07:03]
lnarmour
eclipse_setup [2022/09/15 05:23] (current)
lnarmour
Line 1: Line 1:
-AlphaZ has been only tested on Linux 64 bits and MacOs. There are several options that can be used to get a working eclipse instance with AlphaZ installed.+AlphaZ has been only tested on 64 bit Linux and MacOS. There are several options that can be used to get a working eclipse instance with AlphaZ installed.
  
 ===== Option 1 - Eclipse Setup on CS Department Machines ===== ===== Option 1 - Eclipse Setup on CS Department Machines =====
-You must be a CSU student with access to the CS machines to do this. The eclipse environment with all necessary plug-ins is available in the AlphaZ project directory. The following script will start the eclipse with AlphaZ installed.\\+You must be a CSU student with access to the CS deparment machines to do this. An eclipse environment with all necessary plug-ins is available in the AlphaZ project directory. Run the following in a bash terminal to add the AlphaZ project directory to your path:
 <code bash> <code bash>
-#!/bin/bash+echo 'export PATH=/s/chopin/h/proj/AlphaZ/bin:$PATH' >> ~/.bashrc 
 +source ~/.bashrc 
 +</code>
  
-#Path to the eclipse -- should NOT be changed +Then launch Eclipse with the following command
-export ECLIPSE_HOME=/s/chopin/e/proj/AlphaZ/BinTree/eclipse-alphaz-bundle/eclipse/ +<code bash> 
-#Path to the java used -- should NOT be changed +eclipse.alphaz
-export JAVA_HOME=/usr/local/java64/bin/ +
-export PATH=${JAVA_HOME}:${PATH} +
- +
-${ECLIPSE_HOME}/eclipse $* -configuration ~/.eclipse_alphaz_config -vmargs -d64 -Xms256m -Xmx1024m &+
 </code> </code>
-Save the above script as ''eclipse.custom'' on your home directory (say as ~/eclipse.custom) and run it (don't forget to give execute permission to the script). 
  
 +===== Option 2 - Eclipse Setup using Local Install =====
 +Alternatively, you can install eclipse on your own machine and manually install the AlphaZ plugins directly.
 +See the README in the AlphaZ git repo: \\
 +https://mustang.cs.colostate.edu:3000/melange/AlphaZ
  
-===== Option 2 - Eclipse Setup using Docker ===== +Note that this link is not public and is only accessible from the CSU network (you either need to be physically on campus or connected to the VPN).
-If you don't have access to the CSU machines or would rather run eclipse locally on your own machine, then you can use the following docker container: \\ +
-https://hub.docker.com/repository/docker/narmour/alphaz-user-image+
  
-See the following for additional information if you want to use this option: \\ 
-https://github.com/lnarmour/alphaz-user-image 
- 
-===== Option 3 - Eclipse Setup using Local Install ===== 
-If you don't want to use docker, then you can use this option to install eclipse on your own machine and manually install the AlphaZ plugins directly. 
- 
-  - AlphaZ requires Java 8 or later and a Unix system (Linux or Mac OSX). If Java 8 is not installed on your machine, install Java from http://www.oracle.com/technetwork/java/javase/downloads/index-jsp-138363.html.  
-  - Download Eclipse (2019-03 Release) from https://www.eclipse.org/downloads/packages/release 
-  - Launch Eclipse 
-  - Go to Help -> Install New Software 
-  - In "Work with" text box, copy/paste the following URL: https://www.cs.colostate.edu/AlphaZ/update-sites/2019_03-master. 
-  - You should see the item for "AlphaZ". 
-  - Install "AlphaZ". 
-  - Hit next until Eclipse start installing the bundle. 
-  - Restart Eclipse. 
- 
-If you met some problems while using AlphaZ, please refer to the common pitfall section. We described some common problems that users met, and provided possible solutions.\\ 
  
 =====Checking out Sample Project====== =====Checking out Sample Project======
-To get started with AlphaZ, a Java plug-in project with examples can be checked out from our repository.+To get started with AlphaZ, a Java plug-in project with examples can be checked out from our repository. From Eclipse, do the following: 
 +  - ''File'' > ''Import...'' > ''Git''> ''Projects from Git'' > click ''Next'' > ''Clone URI'' > click ''Next'' 
 +  - In the ''URI:'' field, specify ''https://mustang.cs.colostate.edu:3000/melange/AlphaZ'' > click ''Next'' and follow the prompts with defaults until you reach the "Import Projects" step 
 +  - Click ''Deselect All'' > select the ''edu.csu.melange.alphabets.examples'' project from the list > click ''Finish'' 
 +  
 +If you see certificate (SSL) warnings, ignore them.
  
-  * Select ''"File->New->Other"'' from the menu and select ''"Checkout Projects from SVN"'' 
-  * Select ''"Create a new repository location"'' and click ''"Next"'' 
-  * Use ''http://www.cs.colostate.edu/AlphaZsvn/Development'' as the URL and click ''"Next"'' 
-  * Select ''"Alphabets"'' and click ''"Finish"'' 
-  *  
 ===What's Inside=== ===What's Inside===
-Inside the ''Alphabets'' project, you will find two directories''AlphabetsExamples'' and ''CommandScripts''. Alphabets is the programming language for programming in equations (with extension .ab), and CompilerScripts (.cs) are script files to use the scripting interface of AlphaZ.+Inside the ''edu.csu.melange.alphabets.examples'' project, you will find four directories''AlphabetsExamples'', ''CodeGenTutorial'', ''CommandScripts'' and ''ValidationTutorial''. Alphabets is the programming language for programming in equations (with extension .ab), and CompilerScripts (.cs) are script files to use the scripting interface of AlphaZ.
  
-Try running ''BasicScript.cs'' in the ''CommandScripts'' directory to make sure that the system is working on your machine.+Try running ''BasicScript.cs'' in the ''CommandScripts'' directory to make sure that the system is working on your machine (right click ''BasicScript.cs'' > ''Run as'' > ''Compiler Script'').
  
 ''ReadAlphabets'' loads .ab files and parses it to get a ''Program'' object. ''ReadAlphabets'' loads .ab files and parses it to get a ''Program'' object.
Line 61: Line 43:
  
 ===== Common Pitfalls=== ===== Common Pitfalls===
- 
- 
-You may have some error connecting to the repository through eclipse 
-  * When you run a *.cs file, if you see an error containing "com.google.common" then try again after removing "com.google.guava_21.0.0.v20170206-1425.jar" file from Eclipse/plugins directory. 
-  * When your connection gets lost while trying to connect: 
-     * Go to ''"Preferences→Team→SVN"'' and change the SVN interface to ''"SVNKit(Pure Java)"'' and try again. 
-     * The default SVN interface uses JNI bindings and it may not work depending on the machine. Pure Java version should. 
  
 Check the following if something does not work Check the following if something does not work
eclipse_setup.1612879412.txt.gz · Last modified: 2021/02/09 07:03 by lnarmour