Permalink
Browse files

initial commit

  • Loading branch information...
0 parents commit a386e9412c8645afa2ab6a84c12b3fa444f72e19 @gangeli committed Apr 12, 2011
@@ -0,0 +1,77 @@
+<project name="time" default="dist" basedir=".">
+ <!-- PROPERTIES -->
+ <description>
+ Build file for ${ant.project.name}
+ </description>
+
+ <property name="src" location="src"/>
+ <property name="lib" location="etc"/>
+ <property name="build" location="bin"/>
+ <property name="dist" location="dist"/>
+
+ <path id="classpath.build">
+ <pathelement location="${lib}/postgresql.jar"/>
+ <pathelement location="${lib}/scala-compiler.jar"/>
+ <pathelement location="${lib}/scala-library.jar"/>
+ <pathelement location="${lib}/lib.jar"/>
+ </path>
+
+ <taskdef resource="scala/tools/ant/antlib.xml">
+ <classpath>
+ <pathelement location="${lib}/scala-compiler.jar"/>
+ <pathelement location="${scala-library.jar}"/>
+ </classpath>
+ </taskdef>
+
+ <!-- INIT -->
+ <target name="init">
+ <tstamp/>
+ <mkdir dir="${build}"/>
+ </target>
+
+ <target name="init-scala">
+ <property name="scala-library.jar"
+ value="${lib}/scala-library.jar"/>
+ <path id="scala.classpath">
+ <pathelement location="${scala-library.jar}"/>
+ <pathelement location="${build}"/>
+ </path>
+ </target>
+
+ <!-- BUILD -->
+ <target name="build" depends="init,init-scala"
+ description="Compile all files">
+ <javac srcdir="${src}" destdir="${build}"
+ debug="true" debuglevel="lines, vars, and source"
+ includeantruntime="false">
+ <classpath refid="classpath.build"/>
+ </javac>
+ <scalac srcdir="${src}" destdir="${build}"
+ classpathref="classpath.build">
+ <include name="**/*.scala"/>
+ </scalac>
+ </target>
+
+ <target name="dist" depends="build"
+ description="Package all files">
+ <mkdir dir="${dist}"/>
+ <!--Package Everything-->
+ <jar jarfile="${dist}/${ant.project.name}.jar">
+ <fileset dir="${build}"/>
+ <fileset dir="${src}"/>
+ <!--
+ <zipfileset src="${lib}/postgresql.jar"/>
+ <zipfileset src="${lib}/scala-library.jar"/>
+ <zipfileset src="${lib}/lib.jar"/>
+ -->
+ </jar>
+ </target>
+
+ <!-- CLEAN -->
+ <target name="clean"
+ description="clean up">
+ <delete dir="${build}"/>
+ <delete dir="${dist}"/>
+ </target>
+
+</project>
Binary file not shown.
Binary file not shown.
Binary file not shown.
0 rc
No changes.
32 run
@@ -0,0 +1,32 @@
+#!/usr/bin/ruby
+
+require 'execrunner'
+
+# -- DEPENDENCIES --
+JAVANLP = "#{ENV['JAVANLP_HOME']}/projects/core/classes:#{ENV['JAVANLP_HOME']}/projects/research/classes"
+
+# -- RUN --
+env!(
+ # Program
+ 'java',
+ # Runtime Options
+ o('cp',
+ "dist/time.jar:etc/lib.jar:etc/scala-library.jar:etc/postgresql.jar:#{JAVANLP}"),
+ o('Xrunhprof:cpu=samples'),
+ o('Xmx500M'),
+ o('server'),
+ o('ea'),
+ 'time.Entry',
+
+ run(
+ # -- BOOTSTRAPING --
+ #(exec options)
+# o('logDebug'),
+ o('ignoreClasspath', "\"[#{ENV['JAVANLP_HOME']}/.*,etc/scala-library.jar,etc/postgres.jar]\""),
+ #(logging)
+ o('execDir', 'out'),
+ o('execOutput', '"psql://research@localhost:time<what?why42?"'),
+ #(data)
+ o('execData', '"psql://research@localhost:data<what?why42?"'),
+ nil),
+nil)
@@ -0,0 +1,15 @@
+package time
+
+//(lib)
+import org.goobs.exec.Execution
+import org.goobs.exec.Log._
+
+object Entry {
+ def main(args:Array[String]):Unit = {
+ Execution.exec(new Runnable(){
+ override def run:Unit = {
+ log("Hello World!")
+ }
+ }, args)
+ }
+}

0 comments on commit a386e94

Please sign in to comment.