From 4c428f8fd58f7bbb089b68e6efbe77a100f56cf8 Mon Sep 17 00:00:00 2001 From: dhanshreea Date: Tue, 1 Oct 2024 02:18:49 +0530 Subject: [PATCH] Update DOI in citation file; add version update in citation to release action --- .github/workflows/publish.yaml | 17 +++++++++++++++++ CITATION.cff | 2 +- ersilia/_static_version.py | 2 +- 3 files changed, 19 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index 81f2ff1db..c78eacf72 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -35,6 +35,23 @@ jobs: git config --local user.name "ersilia-bot" git tag -a "v${{ steps.version.outputs.VERSION }}" -m "v${{ steps.version.outputs.VERSION }}" + - name: Update version in CITATION.cff + id: update-citation + env: + VERSION: ${{ steps.version.outputs.VERSION }} + run: | + pip install PyYAML + python -c " + import os + import yaml + with open('CITATION.cff', 'r') as file: + content = file.read() + citation = yaml.safe_load(file) + citation['version'] = os.environ['VERSION'] + with open('CITATION.cff', 'w') as file: + yaml.dump(citation, file) + " + - name: Commit and push changes done to the static version file and pyproject.toml uses: actions-js/push@5a7cbd780d82c0c937b5977586e641b2fd94acc5 # pin@v1.5 with: diff --git a/CITATION.cff b/CITATION.cff index 849066695..2700bee52 100644 --- a/CITATION.cff +++ b/CITATION.cff @@ -12,6 +12,6 @@ authors: orcid: "https://orcid.org/0000-0002-9906-6936" title: "Ersilia Model Hub: a repository of AI/ML models for neglected tropical diseases" version: 1.0.0 -doi: 10.5281/zenodo.7274646 +doi: 10.5281/zenodo.7274645 date-released: 2022-11-02 url: "https://github.com/ersilia-os/ersilia" diff --git a/ersilia/_static_version.py b/ersilia/_static_version.py index ea21bff46..ba70c4821 100644 --- a/ersilia/_static_version.py +++ b/ersilia/_static_version.py @@ -1 +1 @@ -version = "0.1.35" +version = "0.1.36"