Skip to content

Commit

Permalink
Merge pull request #941 from NASA-PDS/issue_935
Browse files Browse the repository at this point in the history
Specify specific maven project.version in the validate execution scripts
  • Loading branch information
jordanpadams authored Jun 18, 2024
2 parents 5de6a69 + bddc84b commit 954dca9
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 18 deletions.
4 changes: 2 additions & 2 deletions src/main/assembly/tar-assembly.xml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ POSSIBILITY OF SUCH DAMAGE.
</excludes>
</fileSet>
<fileSet>
<directory>src/main/resources/bin</directory>
<directory>target/classes/bin</directory>
<outputDirectory>bin</outputDirectory>
<includes>
<include>validate</include>
Expand All @@ -69,7 +69,7 @@ POSSIBILITY OF SUCH DAMAGE.
<lineEnding>keep</lineEnding>
</fileSet>
<fileSet>
<directory>src/main/resources/bin</directory>
<directory>target/classes/bin</directory>
<outputDirectory>bin</outputDirectory>
<includes>
<include>logging.properties</include>
Expand Down
4 changes: 2 additions & 2 deletions src/main/assembly/zip-assembly.xml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ POSSIBILITY OF SUCH DAMAGE.
</excludes>
</fileSet>
<fileSet>
<directory>src/main/resources/bin</directory>
<directory>target/classes/bin</directory>
<outputDirectory>bin</outputDirectory>
<includes>
<include>validate</include>
Expand All @@ -69,7 +69,7 @@ POSSIBILITY OF SUCH DAMAGE.
<lineEnding>keep</lineEnding>
</fileSet>
<fileSet>
<directory>src/main/resources/bin</directory>
<directory>target/classes/bin</directory>
<outputDirectory>bin</outputDirectory>
<includes>
<include>logging.properties</include>
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/bin/validate
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ if [ ! -f ${LIB_DIR}/validate-*.jar ]; then
fi

# Finds the jar file in LIB_DIR and sets it to VALIDATE_JAR.
VALIDATE_JAR=`ls ${LIB_DIR}/validate-*.jar`
VALIDATE_JAR=${LIB_DIR}/validate-@project.version@.jar

# Executes Validate Tool via the executable jar file
# Arguments are passed in to the tool via '$@'
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/bin/validate-refs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ if [ ! -f ${LIB_DIR}/validate-*.jar ]; then
fi

# Finds the jar file in LIB_DIR and sets it to VALIDATE_JAR.
VALIDATE_JAR=`ls ${LIB_DIR}/validate-*.jar`
VALIDATE_JAR=${LIB_DIR}/validate-@project.version@.jar

# Executes Validate Tool via the executable jar file
# Arguments are passed in to the tool via '$@'
Expand Down
9 changes: 3 additions & 6 deletions src/main/resources/bin/validate-refs.bat
Original file line number Diff line number Diff line change
Expand Up @@ -48,16 +48,13 @@ set PARENT_DIR=%SCRIPT_DIR%..
set LIB_DIR=%PARENT_DIR%\lib

:: Check for dependencies.
if exist "%LIB_DIR%\validate-*.jar" (
set VALIDATE_JAR=%LIB_DIR%\validate-*.jar
if exist "%LIB_DIR%\validate-@project.version@.jar" (
set VALIDATE_JAR=%LIB_DIR%\validate-@project.version@.jar
) else (
echo Cannot find VTool jar file in %LIB_DIR%
echo Cannot find VTool jar file ([email protected]@.jar) in %LIB_DIR%
goto END
)

:: Finds the jar file in LIB_DIR and sets it to VALIDATE_JAR
for %%i in ("%LIB_DIR%"\validate-*.jar) do set VALIDATE_JAR=%%i

:: Executes the Validate Tool via the executable jar file
:: The special variable '%*' allows the arguments
:: to be passed into the executable.
Expand Down
9 changes: 3 additions & 6 deletions src/main/resources/bin/validate.bat
Original file line number Diff line number Diff line change
Expand Up @@ -48,16 +48,13 @@ set PARENT_DIR=%SCRIPT_DIR%..
set LIB_DIR=%PARENT_DIR%\lib

:: Check for dependencies.
if exist "%LIB_DIR%\validate-*.jar" (
set VALIDATE_JAR=%LIB_DIR%\validate-*.jar
if exist "%LIB_DIR%\validate-@project.validate@.jar" (
set VALIDATE_JAR=%LIB_DIR%\validate-@project.version@.jar
) else (
echo Cannot find VTool jar file in %LIB_DIR%
echo Cannot find VTool jar file ([email protected]@.jar) in %LIB_DIR%
goto END
)

:: Finds the jar file in LIB_DIR and sets it to VALIDATE_JAR
for %%i in ("%LIB_DIR%"\validate-*.jar) do set VALIDATE_JAR=%%i

:: Executes the Validate Tool via the executable jar file
:: The special variable '%*' allows the arguments
:: to be passed into the executable.
Expand Down

0 comments on commit 954dca9

Please sign in to comment.