Skip to content

Commit

Permalink
added --version to CLI (via snakebids.yml) (#210)
Browse files Browse the repository at this point in the history
also updated github actions (will need testing!)
  • Loading branch information
akhanf authored Sep 8, 2022
1 parent 91168f1 commit b3ea65f
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 12 deletions.
8 changes: 0 additions & 8 deletions .bumpversion.cfg

This file was deleted.

14 changes: 11 additions & 3 deletions .github/workflows/bump_version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,21 @@ jobs:
find: 'version = "(?:([0-9]+\.[0-9]+\.[0-9]+.+)|([0-9]+\.[0-9]+\.[0-9]+))"'
replace: 'version = "${{ steps.release-drafter.outputs.name }}-pre.${{ env.NEW_BUMP }}"'

- name: Update version in pipeline_description
- name: Update version in pipeline_description (not actually used)
uses: jacobtomlinson/gha-find-replace@master
with:
include: 'hippunfold/pipeline_description.json'
find: 'version = "(?:([0-9]+\.[0-9]+\.[0-9]+.+)|([0-9]+\.[0-9]+\.[0-9]+))"'
replace: 'version = "${{ steps.release-drafter.outputs.name }}-pre.${{ env.NEW_BUMP }}"'
find: '"Version": "(?:([0-9]+\.[0-9]+\.[0-9]+.+)|([0-9]+\.[0-9]+\.[0-9]+))"'
replace: '"Version": "${{ steps.release-drafter.outputs.name }}-pre.${{ env.NEW_BUMP }}"'

- name: Update version in config/snakebids.yml
uses: jacobtomlinson/gha-find-replace@master
with:
include: 'hippunfold/config/snakebids.yml'
find: 'version: "(?:([0-9]+\.[0-9]+\.[0-9]+.+)|([0-9]+\.[0-9]+\.[0-9]+))"'
replace: 'version: "${{ steps.release-drafter.outputs.name }}-pre.${{ env.NEW_BUMP }}"'


- name: Commit updates
env:
SNAKEBIDS_VERSION: ${{ steps.release-drafter.outputs.name }}-pre.${{ env.NEW_BUMP }}
Expand Down
5 changes: 5 additions & 0 deletions hippunfold/config/snakebids.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,11 @@ parse_args:
participants can be specified with a space separated list.
nargs: '+'

--version:
help: 'Print the version of HippUnfold'
action: version
version: "1.2.0-pre.29"


--modality:
help: 'Type of image to run hippunfold on. Modality prefixed with seg will import an existing (manual) hippocampal tissue segmentation from that space, instead of running neural network (default: %(default)s)'
Expand Down
2 changes: 1 addition & 1 deletion hippunfold/pipeline_description.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"GeneratedBy": [
{
"Name": "hippunfold",
"Version": "0.5.0",
"Version": "1.2.0-pre.29",
"CodeURL": "https://github.com/khanlab/hippunfold",
"Author": "Jordan DeKraker & Ali Khan",
"AuthorEmail": "ali.khan@uwo.ca"
Expand Down

0 comments on commit b3ea65f

Please sign in to comment.