Skip to content

Commit

Permalink
bat / sh scripts rewritten
Browse files Browse the repository at this point in the history
  • Loading branch information
bourgesl committed Sep 19, 2024
1 parent 93d66e9 commit 7eb484a
Show file tree
Hide file tree
Showing 40 changed files with 442 additions and 404 deletions.
22 changes: 22 additions & 0 deletions jmmc-tools/bin/env.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
@ECHO OFF

REM Windows batch file
REM
REM Set general JVM settings
REM

REM Set location of all-in-one jar file:
SET DIR=.

REM Add JVM options (heap):
SET JAVA_OPTS=-Xms1024m -Xmx4096m %JAVA_OPTS%

REM Define custom JDK (optional):
REM SET JAVA_HOME=C:\jdk8u352-b08
REM SET PATH=%JAVA_HOME%\bin\;%PATH%

echo "Java version:"
java -version

REM --- EoF ---

22 changes: 22 additions & 0 deletions jmmc-tools/bin/env.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/bash

# Unix script file
#
# Set general JVM settings
#

# Set location of all-in-one jar file:
export DIR=.

# Add JVM options (heap):
export JAVA_OPTS="-Xms1024m -Xmx4096m ${JAVA_OPTS}"

# Define custom JDK (optional):
# export JAVA_HOME=~/jdk8u352-b08
# export PATH=${JAVA_HOME}/bin/:$PATH

echo "Java version:"
java -version

# --- EoF ---

12 changes: 12 additions & 0 deletions jmmc-tools/bin/run_AppLauncher-gui.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
@ECHO OFF

REM Windows batch file
REM
REM Run AppLauncher
REM

# set main class:
CLASS=fr.jmmc.smprun.AppLauncher

CALL run_jmmc.bat

22 changes: 6 additions & 16 deletions jmmc-tools/bin/run_AppLauncher-gui.sh
Original file line number Diff line number Diff line change
@@ -1,25 +1,15 @@
#!/bin/bash

# Unix script file
#
# GUI AppLauncher
# Run AppLauncher
#


# set main class:
CLASS=fr.jmmc.smprun.AppLauncher

DIR="."

# --- template-start ---
# jdk17+: add "--illegal-access=permit"
JAVA_OPTS="-Xms512m -Xmx4g $JAVA_OPTS"

echo "Java version:"
java -version

echo "JAVA_OPTS: '$JAVA_OPTS'"
echo "JAVA_TUNING: '$JAVA_TUNING'"
export CLASS=fr.jmmc.smprun.AppLauncher

java $JAVA_TUNING $JAVA_OPTS -cp "$DIR/jmmc-tools-TRUNK-jar-with-dependencies.jar" $CLASS "$@"
bash run_jmmc.sh

# --- template-end ---
# --- EoF ---

22 changes: 5 additions & 17 deletions jmmc-tools/bin/run_Aspro2-gui.bat
Original file line number Diff line number Diff line change
@@ -1,27 +1,15 @@
@ECHO OFF

REM Windows batch file
REM
REM GUI Aspro2
REM Run Aspro2
REM

REM enable/disable BB models :
REM SET JAVA_OPTS="-Djmal.bb=false"
REM SET JAVA_OPTS=-Djmal.bb=false

REM set main class:
SET CLASS=fr.jmmc.aspro.Aspro2

SET DIR="."

REM --- template-start ---
REM jdk17+: add "--illegal-access=permit"
SET JAVA_OPTS="-Xms512m -Xmx4g %JAVA_OPTS%"

echo "Java version:"
java -version

echo "JAVA_OPTS: '%JAVA_OPTS%'"
echo "JAVA_TUNING: '%JAVA_TUNING%'"

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

REM --- template-end ---
CALL run_jmmc.bat

24 changes: 7 additions & 17 deletions jmmc-tools/bin/run_Aspro2-gui.sh
Original file line number Diff line number Diff line change
@@ -1,27 +1,17 @@
#!/bin/bash

# Unix script file
#
# GUI Aspro2
# Run Aspro2
#

# enable/disable BB models :
#export JAVA_OPTS="-Djmal.bb=false"
# export JAVA_OPTS=-Djmal.bb=false

# set main class:
CLASS=fr.jmmc.aspro.Aspro2

DIR="."

# --- template-start ---
# jdk17+: add "--illegal-access=permit"
JAVA_OPTS="-Xms512m -Xmx4g $JAVA_OPTS"

echo "Java version:"
java -version

echo "JAVA_OPTS: '$JAVA_OPTS'"
echo "JAVA_TUNING: '$JAVA_TUNING'"
export CLASS=fr.jmmc.aspro.Aspro2

java $JAVA_TUNING $JAVA_OPTS -cp "$DIR/jmmc-tools-TRUNK-jar-with-dependencies.jar" $CLASS "$@"
bash run_jmmc.sh

# --- template-end ---
# --- EoF ---

21 changes: 4 additions & 17 deletions jmmc-tools/bin/run_LITpro-gui.bat
Original file line number Diff line number Diff line change
@@ -1,25 +1,12 @@
@ECHO OFF

REM Windows batch file
REM
REM GUI LITpro
REM Run LITpro
REM


REM set main class:
SET CLASS=fr.jmmc.mf.LITpro

SET DIR="."

REM --- template-start ---
REM jdk17+: add "--illegal-access=permit"
SET JAVA_OPTS="-Xms512m -Xmx4g %JAVA_OPTS%"

echo "Java version:"
java -version

echo "JAVA_OPTS: '%JAVA_OPTS%'"
echo "JAVA_TUNING: '%JAVA_TUNING%'"

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

REM --- template-end ---
CALL run_jmmc.bat

23 changes: 6 additions & 17 deletions jmmc-tools/bin/run_LITpro-gui.sh
Original file line number Diff line number Diff line change
@@ -1,25 +1,14 @@
#!/bin/bash

# Unix script file
#
# GUI LITpro
# Run LITpro
#


# set main class:
CLASS=fr.jmmc.mf.LITpro

DIR="."

# --- template-start ---
# jdk17+: add "--illegal-access=permit"
JAVA_OPTS="-Xms512m -Xmx4g $JAVA_OPTS"

echo "Java version:"
java -version

echo "JAVA_OPTS: '$JAVA_OPTS'"
echo "JAVA_TUNING: '$JAVA_TUNING'"
export CLASS=fr.jmmc.mf.LITpro

java $JAVA_TUNING $JAVA_OPTS -cp "$DIR/jmmc-tools-TRUNK-jar-with-dependencies.jar" $CLASS "$@"
bash run_jmmc.sh

# --- template-end ---
# --- EoF ---

21 changes: 4 additions & 17 deletions jmmc-tools/bin/run_OIFitsExplorer-gui.bat
Original file line number Diff line number Diff line change
@@ -1,25 +1,12 @@
@ECHO OFF

REM Windows batch file
REM
REM GUI OIFitsExplorer
REM Run OIFitsExplorer
REM


REM set main class:
SET CLASS=fr.jmmc.oiexplorer.OIFitsExplorer

SET DIR="."

REM --- template-start ---
REM jdk17+: add "--illegal-access=permit"
SET JAVA_OPTS="-Xms512m -Xmx4g %JAVA_OPTS%"

echo "Java version:"
java -version

echo "JAVA_OPTS: '%JAVA_OPTS%'"
echo "JAVA_TUNING: '%JAVA_TUNING%'"

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

REM --- template-end ---
CALL run_jmmc.bat

23 changes: 6 additions & 17 deletions jmmc-tools/bin/run_OIFitsExplorer-gui.sh
Original file line number Diff line number Diff line change
@@ -1,25 +1,14 @@
#!/bin/bash

# Unix script file
#
# GUI OIFitsExplorer
# Run OIFitsExplorer
#


# set main class:
CLASS=fr.jmmc.oiexplorer.OIFitsExplorer

DIR="."

# --- template-start ---
# jdk17+: add "--illegal-access=permit"
JAVA_OPTS="-Xms512m -Xmx4g $JAVA_OPTS"

echo "Java version:"
java -version

echo "JAVA_OPTS: '$JAVA_OPTS'"
echo "JAVA_TUNING: '$JAVA_TUNING'"
export CLASS=fr.jmmc.oiexplorer.OIFitsExplorer

java $JAVA_TUNING $JAVA_OPTS -cp "$DIR/jmmc-tools-TRUNK-jar-with-dependencies.jar" $CLASS "$@"
bash run_jmmc.sh

# --- template-end ---
# --- EoF ---

14 changes: 14 additions & 0 deletions jmmc-tools/bin/run_OIFitsProcessor.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
@ECHO OFF

REM Windows batch file
REM
REM Run Aspro2
REM

REM enable/disable BB models :
REM SET JAVA_OPTS=-Djmal.bb=false

REM set main class:
SET CLASS=fr.jmmc.aspro.Aspro2

CALL run_jmmc.bat
23 changes: 6 additions & 17 deletions jmmc-tools/bin/run_OIFitsProcessor.sh
Original file line number Diff line number Diff line change
@@ -1,25 +1,14 @@
#!/bin/bash

# Unix script file
#
# CLI OIFitsProcessor
# Run OIFitsProcessor CLI
#


# set main class:
CLASS=fr.jmmc.oitools.OIFitsProcessor

DIR="."

# --- template-start ---
# jdk17+: add "--illegal-access=permit"
JAVA_OPTS="-Xms512m -Xmx4g $JAVA_OPTS"

echo "Java version:"
java -version

echo "JAVA_OPTS: '$JAVA_OPTS'"
echo "JAVA_TUNING: '$JAVA_TUNING'"
export CLASS=fr.jmmc.oitools.OIFitsProcessor

java $JAVA_TUNING $JAVA_OPTS -cp "$DIR/jmmc-tools-TRUNK-jar-with-dependencies.jar" $CLASS "$@"
bash run_jmmc.sh

# --- template-end ---
# --- EoF ---

20 changes: 4 additions & 16 deletions jmmc-tools/bin/run_OImaging-gui.bat
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
@ECHO OFF

REM Windows batch file
REM
REM GUI OImaging
REM Run OImaging GUI
REM

REM enable/disable using local docker image:
Expand All @@ -9,19 +11,5 @@ REM SET JAVA_OPTS="-DRemoteExecutionMode.local=false"
REM set main class:
SET CLASS=fr.jmmc.oimaging.OImaging

SET DIR="."

REM --- template-start ---
REM jdk17+: add "--illegal-access=permit"
SET JAVA_OPTS="-Xms512m -Xmx4g %JAVA_OPTS%"

echo "Java version:"
java -version

echo "JAVA_OPTS: '%JAVA_OPTS%'"
echo "JAVA_TUNING: '%JAVA_TUNING%'"

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

REM --- template-end ---
CALL run_jmmc.bat

22 changes: 5 additions & 17 deletions jmmc-tools/bin/run_OImaging-gui.sh
Original file line number Diff line number Diff line change
@@ -1,27 +1,15 @@
#!/bin/bash
#
# GUI OImaging
# Run OImaging
#

# enable/disable using local docker image:
#export JAVA_OPTS="-DRemoteExecutionMode.local=false"
# export JAVA_OPTS="-DRemoteExecutionMode.local=false"

# set main class:
CLASS=fr.jmmc.oimaging.OImaging
export CLASS=fr.jmmc.oimaging.OImaging

DIR="."
bash run_jmmc.sh

# --- template-start ---
# jdk17+: add "--illegal-access=permit"
JAVA_OPTS="-Xms512m -Xmx4g $JAVA_OPTS"

echo "Java version:"
java -version

echo "JAVA_OPTS: '$JAVA_OPTS'"
echo "JAVA_TUNING: '$JAVA_TUNING'"

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

# --- template-end ---
# --- EoF ---

Loading

0 comments on commit 7eb484a

Please sign in to comment.