offsetpath field in meta files was absolute; should be relative to workspace

This commit is contained in:
Dan Hawkins 2019-02-26 18:07:16 +00:00
commit c8fa1243fd

View file

@ -563,6 +563,13 @@ class MetaInfo extends GISJsonSerialised {
pathRelative = mypath pathRelative = mypath
script.echo("Path relative is unchanged: ${pathRelative}") script.echo("Path relative is unchanged: ${pathRelative}")
} }
// Strip leading / if any
pathRelative = pathRelative.replaceAll("^/+", "")
// Strip leading \ if any
pathRelative = pathRelative.replaceAll("^\\+", "")
script.echo("Path relative is ${pathRelative}")
return pathRelative return pathRelative
} }