Inject some more variables into metadata
This commit is contained in:
parent
043c400d5d
commit
daadbd5773
2 changed files with 6 additions and 2 deletions
2
build.sh
2
build.sh
|
@ -8,7 +8,7 @@ SCRIPTPATH=`dirname $SCRIPT`
|
|||
ADDITIONAL_ARGS=${@:2}
|
||||
|
||||
INPUT_FILE=`realpath $1`
|
||||
INPUT_DIR=`dirname $INPUT_FILE`
|
||||
export INPUT_DIR=`dirname $INPUT_FILE`
|
||||
METADATA_FILE="$INPUT_DIR/metadata.yaml"
|
||||
export OUTPUT_FILE="$PWD/output.pdf"
|
||||
|
||||
|
|
|
@ -19,7 +19,11 @@ end
|
|||
|
||||
return {
|
||||
{
|
||||
Meta = getVars
|
||||
Meta = function (meta)
|
||||
meta = getVars(meta)
|
||||
meta['outputFile'] = os.getenv("OUTPUT_FILE")
|
||||
meta['inputDir'] = os.getenv("INPUT_DIR")
|
||||
end
|
||||
},
|
||||
{
|
||||
Str = function (el)
|
||||
|
|
Reference in a new issue