ci: build coatjava
and gemc
#39
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Validation | |
on: | |
workflow_dispatch: | |
inputs: | |
event: | |
required: true | |
type: string | |
source: | |
required: true | |
type: string | |
title: | |
required: true | |
type: string | |
source_url: | |
required: false | |
type: string | |
separator: | |
required: false | |
type: string | |
default: "[DISPATCH FROM]" | |
pull_request: | |
push: | |
branches: [ master ] | |
run-name: ${{ inputs.title }} ${{ inputs.separator }} ${{ inputs.source }} ${{ inputs.event }} | |
defaults: | |
run: | |
shell: bash | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
# info | |
############################################################################# | |
dispatch_source_info: | |
runs-on: ubuntu-latest | |
if: github.event_name == 'workflow_dispatch' | |
steps: | |
- name: dispatch summary | |
run: | | |
echo "| | |" >> $GITHUB_STEP_SUMMARY | |
echo "| --- | --- |" >> $GITHUB_STEP_SUMMARY | |
echo "| PR URL | <${{ inputs.source_url }}> |" >> $GITHUB_STEP_SUMMARY | |
echo "| PR Title | ${{ inputs.title }} |" >> $GITHUB_STEP_SUMMARY | |
echo "| | |" >> $GITHUB_STEP_SUMMARY | |
# build | |
############################################################################# | |
build_coatjava: | |
runs-on: ubuntu-latest | |
steps: | |
- name: setup java | |
uses: actions/setup-java@v3 | |
with: | |
java-version: 11 | |
distribution: zulu | |
- name: clone | |
run: git clone https://github.com/JeffersonLab/coatjava.git | |
- name: build | |
run: | | |
cd coatjava | |
./build-coatjava.sh | |
- name: tree | |
run: tree | |
- name: tar | |
run: tar czvf coatjava{.tar.gz,} | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: build | |
retention-days: 1 | |
path: ./*.tar.gz | |
build_gemc: | |
runs-on: ubuntu-latest | |
container: jeffersonlab/gemc:4.4.2-5.1-5.2-5.3-fedora36-cvmfs ##### FIXME: need `latest` tag | |
steps: | |
- name: clone | |
run: git clone https://github.com/gemc/clas12Tags.git | |
- name: build | |
run: | | |
source /app/localSetup.sh | |
cd clas12Tags/source | |
scons -j2 OPT=1 | |
- name: tree | |
run: tree | |
- name: tar | |
run: tar czvf clas12Tags{.tar.gz,} | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: build | |
retention-days: 1 | |
path: ./*.tar.gz | |
# test | |
############################################################################# | |
test: | |
needs: | |
- build_coatjava | |
- build_gemc | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/download-artifact@v3 | |
with: | |
name: build | |
- name: tree | |
run: tree |