Skip to content

Commit

Permalink
Merge pull request #614 from openworm/development
Browse files Browse the repository at this point in the history
Release 0.3.6
  • Loading branch information
tarelli authored Jun 6, 2017
2 parents 87b3df7 + dff91b7 commit f1642fb
Show file tree
Hide file tree
Showing 184 changed files with 11,525 additions and 6,443 deletions.
3 changes: 2 additions & 1 deletion .project
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,14 @@
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jem.workbench.JavaEMFNature</nature>
<nature>org.springframework.ide.eclipse.core.springnature</nature>
<nature>org.eclipse.m2e.core.maven2Nature</nature>
<nature>org.eclipse.virgo.ide.facet.core.bundlenature</nature>
<nature>org.eclipse.wst.common.modulecore.ModuleCoreNature</nature>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>org.eclipse.wst.common.project.facet.core.nature</nature>
<nature>com.aptana.ruby.core.rubynature</nature>
<nature>org.python.pydev.pythonNature</nature>
<nature>org.eclipse.virgo.ide.facet.core.bundlenature</nature>
</natures>
</projectDescription>
7 changes: 4 additions & 3 deletions .settings/org.eclipse.wst.common.component
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
<wb-module deploy-name="org.geppetto.frontend">
<wb-resource deploy-path="/" source-path="/target/m2e-wtp/web-resources"/>
<wb-resource deploy-path="/" source-path="/src/main/webapp" tag="defaultRootSource"/>
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/java"/>
<wb-resource deploy-path="/js/" source-path="/src/main/webapp/js"/>
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/resources"/>
<wb-resource deploy-path="/font/" source-path="/src/main/webapp/fonts"/>
<property name="java-output-path" value="/org.geppetto.frontend/bin"/>
<wb-resource deploy-path="/" source-path="/WebContent" tag="defaultRootSource"/>
<wb-resource deploy-path="/" source-path="/target/m2e-wtp/web-resources"/>
<wb-resource deploy-path="/" source-path="/src/main/webapp"/>
<property name="context-root" value="org.geppetto.frontend"/>
<property name="component.exclusion.patterns" value="WEB-INF/classes/lib/*.jar,WEB-INF/lib/*.jar,node_modules/**,node/**"/>
<property name="java-output-path" value="/org.geppetto.frontend/target/classes"/>
</wb-module>
</project-modules>
4 changes: 2 additions & 2 deletions .settings/org.eclipse.wst.common.project.facet.core.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
<faceted-project>
<runtime name="Virgo Runtime"/>
<fixed facet="wst.jsdt.web"/>
<installed facet="jst.web" version="2.5"/>
<installed facet="org.eclipse.virgo.server.bundle" version="1.0"/>
<installed facet="wst.jsdt.web" version="1.0"/>
<installed facet="osgi.bundle" version="4.2"/>
<installed facet="java" version="1.7"/>
<installed facet="org.eclipse.virgo.server.bundle" version="1.0"/>
<installed facet="jst.web" version="2.5"/>
</faceted-project>
20 changes: 5 additions & 15 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.geppetto</groupId>
<artifactId>frontend</artifactId>
<version>0.3.5</version>
<version>0.3.6</version>
<name>Geppetto Frontend</name>
<packaging>war</packaging>
<properties>
Expand Down Expand Up @@ -74,7 +74,7 @@
<contextPath>org.geppetto.frontend</contextPath>
<useSsl>false</useSsl>
<embedded>false</embedded>
<embedderURL>none</embedderURL>
<embedderURL>/</embedderURL>
</properties>
<activation>
<activeByDefault>true</activeByDefault>
Expand Down Expand Up @@ -115,7 +115,7 @@
</goals>
<phase>generate-resources</phase>
<configuration>
<arguments>run build-dev -- --contextPath=org.geppetto.frontend --useSsl=false --embedded=false --embedderURL=/</arguments>
<arguments>run build-dev -- --contextPath=${contextPath} --useSsl=${useSsl} --embedded=${embedded} --embedderURL=${embedderURL}</arguments>
</configuration>
</execution>
</executions>
Expand Down Expand Up @@ -352,6 +352,7 @@
<artifactId>maven-war-plugin</artifactId>
<version>2.3</version>
<configuration>
<warSourceExcludes>node_modules/**</warSourceExcludes>
<packagingExcludes>WEB-INF/classes/lib/*.jar, WEB-INF/lib/*.jar, node_modules/**, node/**</packagingExcludes>
<warName>org.geppetto.frontend</warName>
<archive>
Expand Down Expand Up @@ -392,19 +393,8 @@
<configuration>
<recursive>true</recursive>
<directoryRoots>
<directoryRoot>${basedir}/src/main/webapp/js/geppetto-objects</directoryRoot>
<directoryRoot>${basedir}/src/main/webapp/js/components/widgets</directoryRoot>
<directoryRoot>${basedir}/src/main/webapp/js/model</directoryRoot>
<directoryRoot>${basedir}/src/main/webapp/js/3d_visualization</directoryRoot>
<directoryRoot>${basedir}/src/main/webapp/js/</directoryRoot>
</directoryRoots>
<sourceFiles>
<sourceFile>src/main/webapp/js/GEPPETTO.Console.js</sourceFile>
<sourceFile>src/main/webapp/js/GEPPETTO.FE.js</sourceFile>
<sourceFile>src/main/webapp/js/GEPPETTO.JSEditor.js</sourceFile>
<sourceFile>src/main/webapp/js/GEPPETTO.Main.js</sourceFile>
<sourceFile>src/main/webapp/js/GEPPETTO.MenuManager.js</sourceFile>
<sourceFile>src/main/webapp/js/GEPPETTO.ScriptRunner.js</sourceFile>
</sourceFiles>
<outputDirectory>${basedir}/src/main/webapp/jsdocs</outputDirectory>
</configuration>
<executions>
Expand Down
28 changes: 24 additions & 4 deletions src/main/java/org/geppetto/frontend/controllers/Application.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.net.URL;
import java.util.Scanner;

import javax.servlet.http.Cookie;
import javax.servlet.http.HttpServletRequest;
Expand Down Expand Up @@ -39,9 +41,8 @@ public class Application

private static Log logger = LogFactory.getLog(Application.class);

@RequestMapping(value = "/geppetto", method = RequestMethod.GET)
public String geppetto(HttpServletRequest req)
{

private String getGeppetto(HttpServletRequest req, String page){
try
{
IAuthService authService = AuthServiceCreator.getService();
Expand Down Expand Up @@ -99,9 +100,26 @@ else if(geppettoManager.getUser() == null)
{
logger.error("Error while retrieving an authentication service", e);
}
return "redirect:http://geppetto.org";
return "redirect:http://geppetto.org";
}

@RequestMapping(value = "/geppetto", method = RequestMethod.GET)
public String geppetto(HttpServletRequest req, Model model)
{
return getGeppetto(req, "");
}

@RequestMapping(value = "/**", method = RequestMethod.GET)
public String geppettoExtension(HttpServletRequest req, Model model)
{
String path = "/build/static" + req.getServletPath() + ".html";
if (Application.class.getResource(path) != null){
InputStream content = Application.class.getResourceAsStream(path);
model.addAttribute("content", new String(new Scanner(content, "UTF-8").useDelimiter("\\A").next()));
}
return getGeppetto(req, "");
}

@RequestMapping(value = "/geppettotestingprojects", method = RequestMethod.GET)
public @ResponseBody Test getTestingProjects(@RequestParam String url) throws IOException
{
Expand Down Expand Up @@ -149,5 +167,7 @@ public String dashboard()
{
return "dashboard";
}



}
Loading

0 comments on commit f1642fb

Please sign in to comment.