mirror of
https://github.com/engineer-man/piston.git
synced 2025-04-21 12:36:28 +02:00
pkg(groovy-3.0.7): add compile step (#232)
Co-authored-by: Vargas, Dan <dan.vargas@frostbank.com>
This commit is contained in:
parent
7da1a7dce8
commit
959830c652
4 changed files with 28 additions and 3 deletions
17
packages/groovy/3.0.7/compile
vendored
Normal file
17
packages/groovy/3.0.7/compile
vendored
Normal file
|
@ -0,0 +1,17 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Compile groovy scripts into a separate "classes" directory
|
||||
# NOTE: - Main file MUST be a groovy script
|
||||
# - not supporting object class entry points as of now
|
||||
groovyc -d classes "$@"
|
||||
|
||||
# Create the Manifest and include groovy jars:
|
||||
# NOTE: - main class will be the first file ('.' becomes '_' and without the extension)
|
||||
# - groovy lib jars MUST be in the class path in order to work properly
|
||||
echo "Main-Class: $(sed 's/\./\_/g'<<<${1%.*})
|
||||
Class-Path: $(echo $GROOVY_HOME/lib/*.jar | sed 's/\s/\n /g')
|
||||
|
||||
" > manifest.txt
|
||||
|
||||
# Create the jar from the manifest and classes
|
||||
jar cfm out.jar manifest.txt -C classes .
|
Loading…
Add table
Add a link
Reference in a new issue