Skip to content

Commit

Permalink
handle positional arguments (without word splitting)
Browse files Browse the repository at this point in the history
  • Loading branch information
gmella committed Sep 20, 2024
1 parent db305bf commit 25f4c14
Show file tree
Hide file tree
Showing 32 changed files with 40 additions and 36 deletions.
2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_AppLauncher-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ REM
# set main class:
CLASS=fr.jmmc.smprun.AppLauncher

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_AppLauncher-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# set main class:
export CLASS=fr.jmmc.smprun.AppLauncher

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_Aspro2-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ REM SET JAVA_OPTS=-Djmal.bb=false
REM set main class:
SET CLASS=fr.jmmc.aspro.Aspro2

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_Aspro2-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# set main class:
export CLASS=fr.jmmc.aspro.Aspro2

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_LITpro-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ REM
REM set main class:
SET CLASS=fr.jmmc.mf.LITpro

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_LITpro-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# set main class:
export CLASS=fr.jmmc.mf.LITpro

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_OIFitsExplorer-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ REM
REM set main class:
SET CLASS=fr.jmmc.oiexplorer.OIFitsExplorer

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_OIFitsExplorer-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# set main class:
export CLASS=fr.jmmc.oiexplorer.OIFitsExplorer

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_OIFitsProcessor.bat
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ REM SET JAVA_OPTS=-Djmal.bb=false
REM set main class:
SET CLASS=fr.jmmc.oitools.OIFitsProcessor

CALL run_jmmc.bat
CALL run_jmmc.bat %*
2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_OIFitsProcessor.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# set main class:
export CLASS=fr.jmmc.oitools.OIFitsProcessor

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_OImaging-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ REM SET JAVA_OPTS="-DRemoteExecutionMode.local=false"
REM set main class:
SET CLASS=fr.jmmc.oimaging.OImaging

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_OImaging-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# set main class:
export CLASS=fr.jmmc.oimaging.OImaging

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_SearchCal-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ REM
REM set main class:
SET CLASS=fr.jmmc.sclgui.SearchCal

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/bin/run_SearchCal-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# set main class:
export CLASS=fr.jmmc.sclgui.SearchCal

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

5 changes: 3 additions & 2 deletions jmmc-tools/bin/run_jmmc.bat
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,13 @@ CALL env.bat
echo "JAVA_OPTS: '%JAVA_OPTS%'"
echo "JAVA_TUNING: '%JAVA_TUNING%'"

SET CMD=java %JAVA_TUNING% %JAVA_OPTS% -cp %DIR%\jmmc-tools-TRUNK-jar-with-dependencies.jar %CLASS% %*
SET CMD=java %JAVA_TUNING% %JAVA_OPTS% -cp %DIR%\jmmc-tools-TRUNK-jar-with-dependencies.jar %CLASS%

echo "CMD: %CMD%"
echo "ARGS: %*"

echo "------------------------------------------------------------------------------"
%CMD%
%CMD% %*
echo "------------------------------------------------------------------------------"

REM --- EoF ---
Expand Down
5 changes: 3 additions & 2 deletions jmmc-tools/bin/run_jmmc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,13 @@ source ./env.sh
echo "JAVA_OPTS: '${JAVA_OPTS}'"
echo "JAVA_TUNING: '${JAVA_TUNING}'"

CMD="java ${JAVA_TUNING} ${JAVA_OPTS} -cp ${DIR}/jmmc-tools-TRUNK-jar-with-dependencies.jar ${CLASS} $@"
CMD="java ${JAVA_TUNING} ${JAVA_OPTS} -cp ${DIR}/jmmc-tools-TRUNK-jar-with-dependencies.jar ${CLASS}"

# echo "CMD: ${CMD}"
# echo "ARGS: ${@}"

echo "------------------------------------------------------------------------------"
$CMD
$CMD "${@}"
echo "------------------------------------------------------------------------------"

# --- EoF ---
Expand Down
2 changes: 1 addition & 1 deletion jmmc-tools/run_AppLauncher-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ REM
# set main class:
CLASS=fr.jmmc.smprun.AppLauncher

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/run_AppLauncher-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# set main class:
export CLASS=fr.jmmc.smprun.AppLauncher

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/run_Aspro2-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ REM SET JAVA_OPTS=-Djmal.bb=false
REM set main class:
SET CLASS=fr.jmmc.aspro.Aspro2

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/run_Aspro2-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# set main class:
export CLASS=fr.jmmc.aspro.Aspro2

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/run_LITpro-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ REM
REM set main class:
SET CLASS=fr.jmmc.mf.LITpro

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/run_LITpro-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# set main class:
export CLASS=fr.jmmc.mf.LITpro

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/run_OIFitsExplorer-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ REM
REM set main class:
SET CLASS=fr.jmmc.oiexplorer.OIFitsExplorer

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/run_OIFitsExplorer-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# set main class:
export CLASS=fr.jmmc.oiexplorer.OIFitsExplorer

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/run_OIFitsProcessor.bat
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ REM SET JAVA_OPTS=-Djmal.bb=false
REM set main class:
SET CLASS=fr.jmmc.oitools.OIFitsProcessor

CALL run_jmmc.bat
CALL run_jmmc.bat %*
2 changes: 1 addition & 1 deletion jmmc-tools/run_OIFitsProcessor.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# set main class:
export CLASS=fr.jmmc.oitools.OIFitsProcessor

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/run_OImaging-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ REM SET JAVA_OPTS="-DRemoteExecutionMode.local=false"
REM set main class:
SET CLASS=fr.jmmc.oimaging.OImaging

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/run_OImaging-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# set main class:
export CLASS=fr.jmmc.oimaging.OImaging

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

2 changes: 1 addition & 1 deletion jmmc-tools/run_SearchCal-gui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ REM
REM set main class:
SET CLASS=fr.jmmc.sclgui.SearchCal

CALL run_jmmc.bat
CALL run_jmmc.bat %*

2 changes: 1 addition & 1 deletion jmmc-tools/run_SearchCal-gui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# set main class:
export CLASS=fr.jmmc.sclgui.SearchCal

bash run_jmmc.sh
bash run_jmmc.sh "${@}"

# --- EoF ---

5 changes: 3 additions & 2 deletions jmmc-tools/run_jmmc.bat
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,13 @@ CALL env.bat
echo "JAVA_OPTS: '%JAVA_OPTS%'"
echo "JAVA_TUNING: '%JAVA_TUNING%'"

SET CMD=java %JAVA_TUNING% %JAVA_OPTS% -cp %DIR%\jmmc-tools-TRUNK-jar-with-dependencies.jar %CLASS% %*
SET CMD=java %JAVA_TUNING% %JAVA_OPTS% -cp %DIR%\jmmc-tools-TRUNK-jar-with-dependencies.jar %CLASS%

echo "CMD: %CMD%"
echo "ARGS: %*"

echo "------------------------------------------------------------------------------"
%CMD%
%CMD% %*
echo "------------------------------------------------------------------------------"

REM --- EoF ---
Expand Down
5 changes: 3 additions & 2 deletions jmmc-tools/run_jmmc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,13 @@ source ./env.sh
echo "JAVA_OPTS: '${JAVA_OPTS}'"
echo "JAVA_TUNING: '${JAVA_TUNING}'"

CMD="java ${JAVA_TUNING} ${JAVA_OPTS} -cp ${DIR}/jmmc-tools-TRUNK-jar-with-dependencies.jar ${CLASS} $@"
CMD="java ${JAVA_TUNING} ${JAVA_OPTS} -cp ${DIR}/jmmc-tools-TRUNK-jar-with-dependencies.jar ${CLASS}"

# echo "CMD: ${CMD}"
# echo "ARGS: ${@}"

echo "------------------------------------------------------------------------------"
$CMD
$CMD "${@}"
echo "------------------------------------------------------------------------------"

# --- EoF ---
Expand Down

0 comments on commit 25f4c14

Please sign in to comment.