Skip to content
Snippets Groups Projects
Commit 95a508c5 authored by Gervaise Henry's avatar Gervaise Henry :cowboy:
Browse files

Change to pulling badges

parent 68a7c89c
Branches
Tags
1 merge request!58Develop
Pipeline #8713 failed with stages
in 1 minute and 21 seconds
......@@ -25,7 +25,9 @@ build_bages:
- ./get-updated-badge-info.sh
artifacts:
paths:
- badges.json
- release.svg
- pipeline.svg
- nextflow.svg
when: always
expire_in: 3 months
......
#!/bin/bash
echo "collecting stats for badges"
commits=`git rev-list --all --count`
latest_release_tag=$(git describe --tags `git rev-list --tags --max-count=1`)
current_pipeline_version=$(cat ./workflow/nextflow.config | grep -o version.* | grep -oP "(?<=').*(?=')")
current_nextflow_version=$(cat ./workflow/nextflow.config | grep -o nextflowVersion.* | grep -oP "(?<=').*(?=')")
echo "{\"commits\":\"$commits\", \"release_tag\":\"$latest_release_tag\", \"pipeline\":\"$current_pipeline_version\", \"nextflow\":\"$current_nextflow_version\"}" > badges.json
\ No newline at end of file
echo "collecting badges"
curl --request GET https://img.shields.io/badge/Latest%20Release-${latest_release_tag}-green?style=plastic > release.svg
curl --request GET https://img.shields.io/badge/Pipeline%20Version-${current_pipeline_version}-green?style=plastic > pipeline.svg
curl --request GET https://img.shields.io/badge/Nextflow%20Version-${current_nextflow_version}-green?style=plastic > nextflow.svg
\ No newline at end of file
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment