Skip to content
This repository was archived by the owner on Jul 16, 2023. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,7 @@
/.idea/

/out/
/binary/.cache/
/binary/.cache/

.scriptjava/
libs/
14 changes: 12 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,11 +86,21 @@ Before launching the executable make sure, that there is `javac` in the system P


## Building
The main project has no dependencies, so it's a straight-forward process. However, building from IDE (when project is created from the source code)
won't work, as current functionality requires the project's jar in the execution directory (due to build-in imports & IScript)
The main project has no dependencies, so it's a straight-forward process.

Tests require `Gson` (for json testing)

build with ant :

```bash
git clone https://github.com/noties/ScriptJava.git
cd ScriptJava
ant install
java -jar build/jar/ScriptJava.jar
```

enjoy it~


## License

Expand Down
28 changes: 28 additions & 0 deletions build.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<project default="jar">
<property name="build" location="build"/>
<property name="classesdir" location="${build}/classes"/>
<property name="jardir" location="${build}/jar"/>
<property name="libdir" location="libs"/>
<property name="destjar" location="${jardir}/ScriptJava.jar"/>

<target name="clean">
<delete dir="${build}"/>
<delete dir="${libdir}"/>
</target>
<target name="compile">
<mkdir dir="${classesdir}"/>
<javac srcdir="src" destdir="${classesdir}"/>
</target>
<target name="jar" depends="compile" >
<mkdir dir="${jardir}"/>
<jar destfile="${destjar}" basedir="${classesdir}">
<manifest>
<attribute name="Main-Class" value="scriptjava.Main"/>
</manifest>
</jar>
</target>
<target name="install" depends="jar">
<mkdir dir="${libdir}"/>
<copy file="${destjar}" todir="${libdir}"/>
</target>
</project>