mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-13 00:31:14 +00:00
Merge 42d51a1067
into 2df3d909fa
This commit is contained in:
commit
2e850d32fc
57
.github/workflows/codemeta.yaml
vendored
Normal file
57
.github/workflows/codemeta.yaml
vendored
Normal file
|
@ -0,0 +1,57 @@
|
||||||
|
name: codemeta
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
paths:
|
||||||
|
- codemeta.json
|
||||||
|
- .github/workflows/codemeta.yaml
|
||||||
|
tags:
|
||||||
|
- 'v*'
|
||||||
|
pull_request:
|
||||||
|
paths:
|
||||||
|
- codemeta.json
|
||||||
|
- .github/workflows/codemeta.yaml
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
generate:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: ghcr.io/fairrootgroup/fairmq-dev/fedora-38:latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 150
|
||||||
|
fetch-tags: true
|
||||||
|
- run: "git config --system --add safe.directory $GITHUB_WORKSPACE"
|
||||||
|
- name: configure
|
||||||
|
run: "cmake -G Ninja -S $GITHUB_WORKSPACE -B build"
|
||||||
|
- name: generate codemeta.json
|
||||||
|
run: cmake --build build --target codemeta
|
||||||
|
- name: print result
|
||||||
|
run: cat build/codemeta.json
|
||||||
|
- uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: codemeta.json
|
||||||
|
path: build/codemeta.json
|
||||||
|
validate:
|
||||||
|
needs: generate
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: gitlab-registry.in2p3.fr/escape2020/wp3/eossr:v1.0
|
||||||
|
steps:
|
||||||
|
- uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: codemeta.json
|
||||||
|
- name: validate codemeta
|
||||||
|
run: eossr-metadata-validator codemeta.json
|
||||||
|
publish:
|
||||||
|
needs: validate
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: github.event_name == 'push' && contains(github.ref, 'refs/tags/')
|
||||||
|
steps:
|
||||||
|
- uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: codemeta.json
|
||||||
|
- uses: svenstaro/upload-release-action@v2
|
||||||
|
with:
|
||||||
|
file: codemeta.json
|
21
.github/workflows/codemeta_validate.yaml
vendored
21
.github/workflows/codemeta_validate.yaml
vendored
|
@ -1,21 +0,0 @@
|
||||||
name: validate codemeta
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
paths:
|
|
||||||
- codemeta.json
|
|
||||||
- .github/workflows/codemeta_validate.yaml
|
|
||||||
pull_request:
|
|
||||||
paths:
|
|
||||||
- codemeta.json
|
|
||||||
- .github/workflows/codemeta_validate.yaml
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
container:
|
|
||||||
image: gitlab-registry.in2p3.fr/escape2020/wp3/eossr:v1.0
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v3
|
|
||||||
- name: validate codemeta
|
|
||||||
run: eossr-metadata-validator codemeta.json
|
|
|
@ -72,6 +72,11 @@ endif()
|
||||||
if(BUILD_TIDY_TOOL)
|
if(BUILD_TIDY_TOOL)
|
||||||
add_subdirectory(fairmq/tidy)
|
add_subdirectory(fairmq/tidy)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
add_custom_target(codemeta
|
||||||
|
python3 ${CMAKE_SOURCE_DIR}/meta_update.py --outdir ${CMAKE_BINARY_DIR} --set-version ${PROJECT_VERSION}
|
||||||
|
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
|
||||||
|
VERBATIM USES_TERMINAL)
|
||||||
################################################################################
|
################################################################################
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -139,6 +139,7 @@ def main():
|
||||||
parser = ArgumentParser(description='Update codemeta.json and '
|
parser = ArgumentParser(description='Update codemeta.json and '
|
||||||
'.zenodo.json')
|
'.zenodo.json')
|
||||||
parser.add_argument('--set-version', dest='newversion')
|
parser.add_argument('--set-version', dest='newversion')
|
||||||
|
parser.add_argument('--outdir', dest='outdir')
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
|
|
||||||
for manipulator in (CodeMetaManipulator(), ZenodoManipulator()):
|
for manipulator in (CodeMetaManipulator(), ZenodoManipulator()):
|
||||||
|
@ -150,7 +151,10 @@ def main():
|
||||||
if args.newversion is not None:
|
if args.newversion is not None:
|
||||||
manipulator.version(args.newversion)
|
manipulator.version(args.newversion)
|
||||||
manipulator.update_authors()
|
manipulator.update_authors()
|
||||||
manipulator.save()
|
filename = None
|
||||||
|
if args.outdir is not None:
|
||||||
|
filename = f'{args.outdir}/{manipulator.default_filename}'
|
||||||
|
manipulator.save(filename)
|
||||||
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
|
|
|
@ -6,7 +6,7 @@ LABEL org.opencontainers.image.description "FairMQ development environment"
|
||||||
RUN dnf -y update
|
RUN dnf -y update
|
||||||
# https://git.gsi.de/SDE/packages/builder
|
# https://git.gsi.de/SDE/packages/builder
|
||||||
RUN dnf -y install https://alfa-ci.gsi.de/packages/rpm/fedora-$VERSION-x86_64/fairsoft-release-dev.rpm
|
RUN dnf -y install https://alfa-ci.gsi.de/packages/rpm/fedora-$VERSION-x86_64/fairsoft-release-dev.rpm
|
||||||
RUN dnf -y install clang cli11-devel ninja-build 'dnf-command(builddep)' libasan liblsan libtsan libubsan clang-tools-extra
|
RUN dnf -y install clang cli11-devel ninja-build 'dnf-command(builddep)' libasan liblsan libtsan libubsan clang-tools-extra python3
|
||||||
RUN dnf -y builddep fairmq
|
RUN dnf -y builddep fairmq
|
||||||
RUN dnf -y clean all
|
RUN dnf -y clean all
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user