Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
a3e33a3
modified: maven-settings.xml
c-dilks Mar 28, 2025
1c20331
modified: maven-settings.xml
c-dilks Mar 28, 2025
9cf04b3
modified: build-coatjava.sh
c-dilks Mar 28, 2025
816273a
new file: bumpo.sh
c-dilks Mar 28, 2025
ad8cae0
build: deleted `common-tools/parent/pom.xml` since it is unused
c-dilks Mar 28, 2025
e6277ce
refactor: delete `common-tools/build.sh` and `common-tools/README.md`…
c-dilks Mar 28, 2025
72fc9a2
build!: combine `common-tools/coat-lib` POM with `common-tools` POM
c-dilks Mar 28, 2025
a4d3a9d
fix: replace `version-bump.sh`
c-dilks Mar 28, 2025
1850902
fix: revert maven-settings.xml
c-dilks Mar 28, 2025
c6ad125
build: all POMs should be at 12.0.0
c-dilks Mar 28, 2025
44448f5
feat: `version-bump` makes a new git branch and commits
c-dilks Mar 28, 2025
d69f08e
style: better printout
c-dilks Mar 28, 2025
a2da2f5
Merge remote-tracking branch 'origin/development' into one-version-num
c-dilks Mar 28, 2025
ecf902c
fix: ignore `jdtls` files
c-dilks Mar 28, 2025
4e0c897
build: make clean-build be optional
c-dilks Mar 28, 2025
9aba908
fix: restore `coat-lib` shade deps
c-dilks Mar 29, 2025
dc857e5
test: script for dumping jar contents
c-dilks Mar 29, 2025
740e42f
Merge remote-tracking branch 'origin/development' into one-version-num
c-dilks Mar 31, 2025
73747d6
fix: re-bump to 12.0.1t
c-dilks Mar 31, 2025
2660230
fix: remove FIXME comment
c-dilks Mar 31, 2025
3d89de3
fix: bump `install-clara` version
c-dilks Mar 31, 2025
b90416b
fix: version bump should bump shade dependencies too
c-dilks Mar 31, 2025
2b11618
fix: remove test script
c-dilks Mar 31, 2025
c4b712b
fix: be more careful with `rm`-ing `coatjava`
c-dilks Mar 31, 2025
16fb075
fix: unbound `new_branch`
c-dilks Mar 31, 2025
5a570d5
fix: clarify printout
c-dilks Mar 31, 2025
38eac69
Merge branch 'development' into one-version-num
c-dilks Apr 7, 2025
c9be9d2
Merge remote-tracking branch 'origin/development' into one-version-num
c-dilks May 5, 2025
9d59e4e
fix: sync version numbers
c-dilks May 5, 2025
9b4da9a
fix: `install-clara` version check of `coatjava` should allow `/.*t$/`
c-dilks May 6, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 34 additions & 25 deletions build-coatjava.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ set -e
set -u
set -o pipefail

usage='''build-coatjava.sh [-h] [--help] [--quiet] [--spotbugs] [--nomaps] [--unittests]
usage='''build-coatjava.sh [-h] [--help] [--quiet] [--clean] [--spotbugs] [--nomaps] [--unittests]
- all other arguments will be passed to `mvn`, e.g., -T4 will build with 4 parallel threads'''

quiet="no"
cleanBuild="no"
runSpotBugs="no"
downloadMaps="yes"
runUnitTests="no"
Expand All @@ -20,6 +21,7 @@ do
--nomaps) downloadMaps="no" ;;
--unittests) runUnitTests="yes" ;;
--quiet) quiet="yes" ;;
--clean) cleanBuild="yes" ;;
-h|--help)
echo "$usage"
exit 2
Expand All @@ -28,14 +30,18 @@ do
esac
done

top="$(cd "$(dirname "${BASH_SOURCE[0]}")" &> /dev/null && pwd)"
src_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" &> /dev/null && pwd)"
prefix_dir=$src_dir/coatjava

# working directory should be the source code directory
cd $src_dir

wget='wget'
mvn="mvn --settings $top/maven-settings.xml"
mvn="mvn --settings $src_dir/maven-settings.xml"
if [ "$quiet" == "yes" ]
then
wget='wget --progress=dot:mega'
mvn="mvn -q -B --settings $top/maven-settings.xml"
mvn="mvn -q -B --settings $src_dir/maven-settings.xml"
fi
mvn+=" ${mvnArgs[*]:-}"

Expand Down Expand Up @@ -63,7 +69,7 @@ download () {

# download the default field maps, as defined in libexec/env.sh:
# (and duplicated in etc/services/reconstruction.yaml):
source `dirname $0`/libexec/env.sh
source libexec/env.sh
if [ $downloadMaps == "yes" ]; then
echo 'Retrieving field maps ...'
webDir=https://clasweb.jlab.org/clas12offline/magfield
Expand All @@ -83,24 +89,32 @@ if [ $downloadMaps == "yes" ]; then
cd -
fi

rm -rf coatjava
mkdir -p coatjava
cp -r bin coatjava/
cp -r etc coatjava/
cp -r libexec coatjava/
# always clean the installation prefix
rm -rf $prefix_dir

# clean up any cache copies
if [ $cleanBuild == "yes" ]; then
$mvn clean
echo '''DONE CLEANING.
Now re-run without `--clean` to build.'''
exit
fi

# start new installation tree
mkdir -p $prefix_dir
cp -r bin $prefix_dir/
cp -r etc $prefix_dir/
cp -r libexec $prefix_dir/

# create schema directories for partial reconstruction outputs
which python3 >& /dev/null && python=python3 || python=python
$python etc/bankdefs/util/bankSplit.py coatjava/etc/bankdefs/hipo4 || exit 1
mkdir -p coatjava/lib/clas
mkdir -p coatjava/lib/utils
mkdir -p coatjava/lib/services
$python etc/bankdefs/util/bankSplit.py $prefix_dir/etc/bankdefs/hipo4 || exit 1
mkdir -p $prefix_dir/lib/clas
mkdir -p $prefix_dir/lib/utils
mkdir -p $prefix_dir/lib/services

# FIXME: this is still needed by one of the tests
cp external-dependencies/jclara-4.3-SNAPSHOT.jar coatjava/lib/utils

### clean up any cache copies ###
cd common-tools/coat-lib; $mvn clean; cd -
cp external-dependencies/jclara-4.3-SNAPSHOT.jar $prefix_dir/lib/utils

unset CLAS12DIR
if [ $runUnitTests == "yes" ]; then
Expand All @@ -119,12 +133,7 @@ if [ $runSpotBugs == "yes" ]; then
if [ $? != 0 ] ; then echo "spotbugs failure" ; exit 1 ; fi
fi

cd common-tools/coat-lib
$mvn package
if [ $? != 0 ] ; then echo "mvn package failure" ; exit 1 ; fi
cd -

cp common-tools/coat-lib/target/coat-libs-*-SNAPSHOT.jar coatjava/lib/clas/
cp reconstruction/*/target/clas12detector-*-SNAPSHOT*.jar coatjava/lib/services/
cp common-tools/coat-lib/target/coat-libs-*-SNAPSHOT.jar $prefix_dir/lib/clas/
cp reconstruction/*/target/clas12detector-*-SNAPSHOT*.jar $prefix_dir/lib/services/

echo "COATJAVA SUCCESSFULLY BUILT !"
1 change: 0 additions & 1 deletion common-tools/README.md

This file was deleted.

49 changes: 0 additions & 49 deletions common-tools/build.sh

This file was deleted.

6 changes: 3 additions & 3 deletions common-tools/clas-reco/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,19 @@
<dependency>
<groupId>cnuphys</groupId>
<artifactId>magfield</artifactId>
<version>2.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
</dependency>

<dependency>
<groupId>cnuphys</groupId>
<artifactId>swimmer</artifactId>
<version>2.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
</dependency>

<dependency>
<groupId>cnuphys</groupId>
<artifactId>snr</artifactId>
<version>2.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
</dependency>

<dependency>
Expand Down
2 changes: 1 addition & 1 deletion common-tools/cnuphys/magfield/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>cnuphys</groupId>
<artifactId>magfield</artifactId>
<version>2.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
<packaging>jar</packaging>

<parent>
Expand Down
2 changes: 1 addition & 1 deletion common-tools/cnuphys/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>cnuphys</groupId>
<artifactId>clas12</artifactId>
<version>2.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
<packaging>pom</packaging>
<parent>
<groupId>cnuphys</groupId>
Expand Down
2 changes: 1 addition & 1 deletion common-tools/cnuphys/snr/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>cnuphys</groupId>
<artifactId>snr</artifactId>
<version>2.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
<packaging>jar</packaging>

<parent>
Expand Down
2 changes: 1 addition & 1 deletion common-tools/cnuphys/splot/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>cnuphys</groupId>
<artifactId>splot</artifactId>
<version>2.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
<packaging>jar</packaging>

<parent>
Expand Down
6 changes: 3 additions & 3 deletions common-tools/cnuphys/swimmer/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>cnuphys</groupId>
<artifactId>swimmer</artifactId>
<version>2.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
<packaging>jar</packaging>

<parent>
Expand All @@ -17,13 +17,13 @@
<dependency>
<groupId>cnuphys</groupId>
<artifactId>magfield</artifactId>
<version>2.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
</dependency>

<dependency>
<groupId>cnuphys</groupId>
<artifactId>splot</artifactId>
<version>2.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
</dependency>

<dependency>
Expand Down
23 changes: 11 additions & 12 deletions common-tools/coat-lib/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,19 @@
<version>12.0.6t-SNAPSHOT</version>
<packaging>pom</packaging>

<parent>
<groupId>org.jlab.clas</groupId>
<artifactId>clas12rec</artifactId>
<relativePath>../../parent/pom.xml</relativePath>
<version>12.0.6t-SNAPSHOT</version>
</parent>

<repositories>
<repository>
<id>local-build</id>
<url>https://clasweb.jlab.org/.clas12maven</url>
<id>freehep-repo-public</id>
<url>https://clasweb.jlab.org/.clas12maven/</url>
<!--<url>https://srs.slac.stanford.edu/nexus/content/groups/freehep-maven2-public/</url>-->
</repository>
<repository>
<id>jnp-build</id>
<url>https://clasweb.jlab.org/.jhep/maven</url>
</repository>
<repository>
<id>freehep-repo-public</id>
<url>https://clasweb.jlab.org/.clas12maven/</url>
<!--<url>https://srs.slac.stanford.edu/nexus/content/groups/freehep-maven2-public/</url>-->
</repository>
</repositories>

<dependencies>
Expand Down Expand Up @@ -72,7 +71,7 @@
<artifactId>j4ml-clas12</artifactId>
<version>0.9-SNAPSHOT</version>
</dependency>

<dependency>
<groupId>org.jama</groupId>
<artifactId>jamapack</artifactId>
Expand Down
40 changes: 0 additions & 40 deletions common-tools/parent/pom.xml

This file was deleted.

5 changes: 3 additions & 2 deletions common-tools/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,13 @@
<module>clas-jcsg</module>
<module>clas-detector</module>
<module>cnuphys</module>
<module>clas-reco</module>
<module>clas-reco</module>
<module>swim-tools</module>
<module>clas-analysis</module>
<module>clas-analysis</module>
<module>clas-math</module>
<module>clara-io</module>
<module>clas-tracking</module>
<module>coat-lib</module>
</modules>

</project>
4 changes: 2 additions & 2 deletions install-clara
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Default versions:
grapes=2.17
clara=5.0.2
coatjava=11.1.1
coatjava=12.0.6t

# Abort on any non-zero exit codes:
set -e
Expand Down Expand Up @@ -105,7 +105,7 @@ if compgen -G "$coatjava/lib/clas/coat-libs-*.jar" > /dev/null
then
coatjava=$(cd $coatjava && pwd)
echo -e "\nUsing local COATJAVA installation:\n\t$coatjava"
elif ! [[ "$coatjava" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]
elif ! [[ "$coatjava" =~ ^([0-9]+)\.([0-9]+)\.([0-9]+)t?$ ]] # must be semver, or semver+"t"
then
echo -e "\n\nWARNING: COATJAVA doesn't look like a local installation nor version number: $coatjava"
fi
Expand Down
6 changes: 2 additions & 4 deletions reconstruction/alert/pom.xml
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>org.jlab.clas12.detector</groupId>
<artifactId>clas12detector-alert</artifactId>
<version>1.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
<packaging>jar</packaging>

<parent>
Expand Down
6 changes: 2 additions & 4 deletions reconstruction/band/pom.xml
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>org.jlab.clas12.detector</groupId>
<artifactId>clas12detector-band</artifactId>
<version>1.0-SNAPSHOT</version>
<version>12.0.6t-SNAPSHOT</version>
<packaging>jar</packaging>

<parent>
Expand Down
Loading