diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml new file mode 100644 index 000000000..68a1db8f2 --- /dev/null +++ b/.github/workflows/pre-commit.yml @@ -0,0 +1,23 @@ +name: pre-commit + +on: [push, pull_request] + +jobs: + pre-commit: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: cvmfs-contrib/github-action-cvmfs@v3.1 + - uses: aidasoft/run-lcg-view@v4 + with: + release-platform: LCG_101/x86_64-centos7-clang12-opt + run: | + export PYTHONPATH=$(python -m site --user-site):$PYTHONPATH + export PATH=/root/.local/bin:$PATH + pip install --upgrade --user pip + pip install pre-commit --user + # Use virtualenv from the LCG release + pip uninstall --yes virtualenv + pre-commit run --show-diff-on-failure \ + --color=always \ + --all-files diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 000000000..23ef8b85a --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,5 @@ +repos: + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v4.5.0 + hooks: + - id: check-xml diff --git a/FCCee/CLD/compact/FCCee_o0_v01/FCCee_o0_v01.xml b/FCCee/CLD/compact/FCCee_o0_v01/FCCee_o0_v01.xml index 452fbb597..07abf8214 100644 --- a/FCCee/CLD/compact/FCCee_o0_v01/FCCee_o0_v01.xml +++ b/FCCee/CLD/compact/FCCee_o0_v01/FCCee_o0_v01.xml @@ -4,32 +4,32 @@ - + The compact format for the FCCee Detector design - + - + - - + + - - + + @@ -40,21 +40,21 @@ - + - + - + - + - + @@ -67,9 +67,9 @@ @@ -81,15 +81,15 @@ - - - + + + - + suggested naming convention: - + main parameters: - + DET_inner_radius : inner radius of tube like envelope ( inscribed cylinder ) DET_outer_radius : outer radius of tube like envelope ( circumscribed cylinder ) DET_half_length : half length along z axis @@ -99,19 +99,19 @@ DET_outer_symmetry : number of sides on the inside ( 0 for tube ) DET_inner_phi0 : optional rotation of the inner polygon ( in r-phi plane ) DET_outer_phi0 : optional rotation of the outer polygon ( in r-phi plane ) - + additional parameters for cutting away volumes/shapes use one of the above with a number appended and/or an extra specifiaction such as cone ( for a cut away cone ) - + DET_inner_radius_1 DET_outer_radius_2 DET_cone_min_z DET_cone_max_z - + - + - + @@ -140,7 +140,7 @@ - + @@ -177,35 +177,35 @@ - + - + - + - + - + - + @@ -213,31 +213,31 @@ - + - + - + - + - + - + - + - + - + - + - + @@ -425,8 +425,7 @@ --> - + - diff --git a/FCCee/IDEA/compact/IDEA_o1_v01/IDEA_o1_v01.xml b/FCCee/IDEA/compact/IDEA_o1_v01/IDEA_o1_v01.xml index 73139600f..a40f6248b 100644 --- a/FCCee/IDEA/compact/IDEA_o1_v01/IDEA_o1_v01.xml +++ b/FCCee/IDEA/compact/IDEA_o1_v01/IDEA_o1_v01.xml @@ -11,7 +11,7 @@ url="no" status="development" version="1.0"> - + One stop shop for a baseline / the latest developments of the FCCee Detector concept. @@ -39,6 +39,6 @@ - + diff --git a/SiD/compact/SiD_o1_v01/BeamPipe.xml b/SiD/compact/SiD_o1_v01/BeamPipe.xml index b6ecd319c..ab5500496 100644 --- a/SiD/compact/SiD_o1_v01/BeamPipe.xml +++ b/SiD/compact/SiD_o1_v01/BeamPipe.xml @@ -1,3 +1,4 @@ + Beampipe @@ -84,5 +85,4 @@ - - + diff --git a/SiD/compact/SiD_o1_v01/HCalBarrel_o1_v03_00.xml b/SiD/compact/SiD_o1_v01/HCalBarrel_o1_v03_00.xml index facb801d3..9ddd7f34b 100644 --- a/SiD/compact/SiD_o1_v01/HCalBarrel_o1_v03_00.xml +++ b/SiD/compact/SiD_o1_v01/HCalBarrel_o1_v03_00.xml @@ -1,8 +1,8 @@ @@ -38,8 +38,9 @@ - + + + diff --git a/SiD/compact/SiD_o1_v01/HCalEndcap_o1_v03_00.xml b/SiD/compact/SiD_o1_v01/HCalEndcap_o1_v03_00.xml index 04948230a..3185b0c34 100644 --- a/SiD/compact/SiD_o1_v01/HCalEndcap_o1_v03_00.xml +++ b/SiD/compact/SiD_o1_v01/HCalEndcap_o1_v03_00.xml @@ -42,7 +42,8 @@ - + + diff --git a/SiD/compact/SiD_o1_v01/Support.xml b/SiD/compact/SiD_o1_v01/Support.xml index 67cb683ca..7b734ccd9 100644 --- a/SiD/compact/SiD_o1_v01/Support.xml +++ b/SiD/compact/SiD_o1_v01/Support.xml @@ -1,3 +1,4 @@ + Double-walled Carbon Fiber support tube @@ -368,3 +369,4 @@ + diff --git a/SiD/compact/SiD_o2_v01/BeamPipe.xml b/SiD/compact/SiD_o2_v01/BeamPipe.xml index b6ecd319c..ab5500496 100644 --- a/SiD/compact/SiD_o2_v01/BeamPipe.xml +++ b/SiD/compact/SiD_o2_v01/BeamPipe.xml @@ -1,3 +1,4 @@ + Beampipe @@ -84,5 +85,4 @@ - - + diff --git a/SiD/compact/SiD_o2_v01/Support.xml b/SiD/compact/SiD_o2_v01/Support.xml index 67cb683ca..7b734ccd9 100644 --- a/SiD/compact/SiD_o2_v01/Support.xml +++ b/SiD/compact/SiD_o2_v01/Support.xml @@ -1,3 +1,4 @@ + Double-walled Carbon Fiber support tube @@ -368,3 +369,4 @@ + diff --git a/SiD/compact/SiD_o2_v02/BeamPipe.xml b/SiD/compact/SiD_o2_v02/BeamPipe.xml index d4046a3a3..ab5500496 100644 --- a/SiD/compact/SiD_o2_v02/BeamPipe.xml +++ b/SiD/compact/SiD_o2_v02/BeamPipe.xml @@ -1,3 +1,4 @@ + Beampipe @@ -84,3 +85,4 @@ + diff --git a/SiD/compact/SiD_o2_v02/Support.xml b/SiD/compact/SiD_o2_v02/Support.xml index 67cb683ca..7b734ccd9 100644 --- a/SiD/compact/SiD_o2_v02/Support.xml +++ b/SiD/compact/SiD_o2_v02/Support.xml @@ -1,3 +1,4 @@ + Double-walled Carbon Fiber support tube @@ -368,3 +369,4 @@ + diff --git a/SiD/compact/SiD_o2_v03/BeamPipe.xml b/SiD/compact/SiD_o2_v03/BeamPipe.xml index d4046a3a3..ab5500496 100644 --- a/SiD/compact/SiD_o2_v03/BeamPipe.xml +++ b/SiD/compact/SiD_o2_v03/BeamPipe.xml @@ -1,3 +1,4 @@ + Beampipe @@ -84,3 +85,4 @@ + diff --git a/SiD/compact/SiD_o2_v03/Support.xml b/SiD/compact/SiD_o2_v03/Support.xml index 67cb683ca..7b734ccd9 100644 --- a/SiD/compact/SiD_o2_v03/Support.xml +++ b/SiD/compact/SiD_o2_v03/Support.xml @@ -1,3 +1,4 @@ + Double-walled Carbon Fiber support tube @@ -368,3 +369,4 @@ + diff --git a/SiD/compact/SiD_o2_v04/Support.xml b/SiD/compact/SiD_o2_v04/Support.xml index 67cb683ca..7b734ccd9 100644 --- a/SiD/compact/SiD_o2_v04/Support.xml +++ b/SiD/compact/SiD_o2_v04/Support.xml @@ -1,3 +1,4 @@ + Double-walled Carbon Fiber support tube @@ -368,3 +369,4 @@ + diff --git a/SiD/compact/SiD_o3_v02/BeamPipe.xml b/SiD/compact/SiD_o3_v02/BeamPipe.xml index d4046a3a3..ab5500496 100644 --- a/SiD/compact/SiD_o3_v02/BeamPipe.xml +++ b/SiD/compact/SiD_o3_v02/BeamPipe.xml @@ -1,3 +1,4 @@ + Beampipe @@ -84,3 +85,4 @@ + diff --git a/SiD/compact/SiD_o3_v02/Support.xml b/SiD/compact/SiD_o3_v02/Support.xml index 67cb683ca..7b734ccd9 100644 --- a/SiD/compact/SiD_o3_v02/Support.xml +++ b/SiD/compact/SiD_o3_v02/Support.xml @@ -1,3 +1,4 @@ + Double-walled Carbon Fiber support tube @@ -368,3 +369,4 @@ + diff --git a/SiD/compact/sidloi3/BeamPipe.xml b/SiD/compact/sidloi3/BeamPipe.xml index 71a42230e..ae07f91d9 100644 --- a/SiD/compact/sidloi3/BeamPipe.xml +++ b/SiD/compact/sidloi3/BeamPipe.xml @@ -1,3 +1,4 @@ + Beampipe Central Be Beampipe @@ -78,6 +79,4 @@ - - - + diff --git a/SiD/compact/sidloi3/EcalEndcap.xml b/SiD/compact/sidloi3/EcalEndcap.xml index 575e2e1fa..3b6beb576 100644 --- a/SiD/compact/sidloi3/EcalEndcap.xml +++ b/SiD/compact/sidloi3/EcalEndcap.xml @@ -1,4 +1,4 @@ - + EM Calorimeter Endcaps @@ -11,7 +11,7 @@ - + diff --git a/SiD/compact/sidloi3/Support.xml b/SiD/compact/sidloi3/Support.xml index 67cb683ca..7b734ccd9 100644 --- a/SiD/compact/sidloi3/Support.xml +++ b/SiD/compact/sidloi3/Support.xml @@ -1,3 +1,4 @@ + Double-walled Carbon Fiber support tube @@ -368,3 +369,4 @@ + diff --git a/example/sequences.xml b/example/sequences.xml index 360038951..4c9e0db4c 100644 --- a/example/sequences.xml +++ b/example/sequences.xml @@ -3,23 +3,23 @@ - - + - + - @@ -84,7 +84,7 @@ may be shared between many sensitive detectors. Alternatively filters may be directly attached to the sensitive detector in question. Attributes are directly passed as properties to the filter action. - + Note: registered global filters MUST be unique. However, not all filters need to registered.... --> @@ -114,7 +114,7 @@ Note: Action sequences exist for each of the various geant4 callback, which are explained in the documentation, such as EventAction, RunAction, etc and the calls after processing the hits of each sensitive detector. - + --> @@ -162,13 +162,13 @@ - + - + @@ -180,7 +180,7 @@ - + @@ -189,8 +189,8 @@ - - + + @@ -210,12 +210,12 @@ - - - - - + + + + + @@ -251,6 +251,6 @@ applyBirksLawFlag="false"/> - +