Skip to content

Commit

Permalink
add export version to containers
Browse files Browse the repository at this point in the history
  • Loading branch information
SamGuay committed Jul 26, 2024
1 parent 74f749b commit e4b7123
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 3 deletions.
1 change: 1 addition & 0 deletions .github/workflows/publish_doc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ jobs:
dcm2bids -h > docs_helper/help.txt
dcm2bids_helper -h > docs_helper/helper.txt
dcm2bids_scaffold -h > docs_helper/help_scaffold.txt
echo "export VERSION=$(dcm2bids -v | awk '/dcm2bids/ {print $3}')" > docs_helper/version.txt
- name: Set git credentials
run: |
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -139,3 +139,4 @@ tests/data/*
docs_helper/help.txt
docs_helper/help_scaffold.txt
docs_helper/helper.txt
docs_helper/version.txt
10 changes: 8 additions & 2 deletions docs/get-started/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,17 @@ You can install it using [Docker][docker] or [Apptainer/Singularity][apptainer].

=== "Docker"

`docker pull unfmontreal/dcm2bids:${VERSION}`
```
--8<-- "docs_helper/version.txt"
docker pull unfmontreal/dcm2bids:${VERSION}
```

=== "Apptainer/Singularity"

`apptainer pull dcm2bids_${VERSION}.sif docker://unfmontreal/dcm2bids:${VERSION}`
```
--8<-- "docs_helper/version.txt"
apptainer pull dcm2bids.sif docker://unfmontreal/dcm2bids:${VERSION}
```

## Installing binary executables

Expand Down
6 changes: 5 additions & 1 deletion docs/how-to/container.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,19 @@ Before you begin, make sure you have at least one of the following installed:

To start, you can either pull the dcm2bids image from the Docker Hub repository or [build it from the Dockerfile in the repository](https://github.com/UNFmontreal/Dcm2Bids/blob/dev/Dockerfile).:



=== "Docker"

```
--8<-- "docs_helper/version.txt"
docker pull unfmontreal/dcm2bids:${VERSION}
```

=== "Apptainer/Singularity"

```
--8<-- "docs_helper/version.txt"
apptainer pull dcm2bids_${VERSION}.sif docker://unfmontreal/dcm2bids:${VERSION}
```

Expand All @@ -38,7 +42,7 @@ The default command, or the point of entry, for the container is `dcm2bids`. So
=== "Docker"

```
docker run --rm -it unfmontreal/dcm2bids:latest --help
docker run --rm -it unfmontreal/dcm2bids:${VERSION} --help
```

=== "Apptainer/Singularity"
Expand Down

0 comments on commit e4b7123

Please sign in to comment.