From 386147471020c12b5060c9f47cd92f98161f8733 Mon Sep 17 00:00:00 2001 From: Frieder Schlesier Date: Tue, 13 Sep 2016 10:34:33 +0200 Subject: [PATCH] add ant and java --- .dockerfunc | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/.dockerfunc b/.dockerfunc index 2cf555e..4b40dba 100755 --- a/.dockerfunc +++ b/.dockerfunc @@ -69,6 +69,18 @@ android-studio() { #exit 0; } +ant() { + local args=$@ + local cur_dir=$(pwd) + local targetmount=$(basename $cur_dir) + + docker run -it --rm \ + -v $(pwd):/src/$targetmount \ + -w /src/$targetmount \ + fschl/ant \ + "$args" +} + bro() { docker run -it --rm \ fschl/bropages \ @@ -182,6 +194,25 @@ inkscape() { exit 0; } +java() { + local args=$@ + local cur_dir=$(pwd) + local PROJECT=$(basename $cur_dir) + + del_stopped java_$PROJECT + + docker run -it \ + --name="java_$PROJECT" \ + -v $(pwd):/src/$PROJECT \ + -w /src/$PROJECT \ + -v /tmp/.X11-unix:/tmp/.X11-unix \ + -e DISPLAY=unix$DISPLAY \ + --net=host \ + openjdk:8 \ + bash -c "$args" + +} + latex() { del_stopped latex