Skip to content

Commit

Permalink
fix: add option to print esi-shell version (#100)
Browse files Browse the repository at this point in the history
  • Loading branch information
plexoos authored Jul 12, 2024
1 parent 1ea208e commit 9c15c86
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,13 @@ jobs:
with:
fetch-depth: 0 # Important for Semantic Release to analyze all commits

- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: "lts/*"

- run: npm install semantic-release-replace-plugin -D

- name: Copy external assets
run: cp /home/runner/NVIDIA-OptiX-SDK-7.6.0-linux64-x86_64.sh .

Expand Down
7 changes: 7 additions & 0 deletions .releaserc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ branches:
tagFormat: '${version}' # without this, the tag is prefixed with a 'v'
plugins:
- "@semantic-release/commit-analyzer"
- path: "semantic-release-replace-plugin"
replacements:
- files:
- esi-shell
from: ESI_SHELL_VERSION=.*
to: ESI_SHELL_VERSION=${nextRelease.version}
- "@semantic-release/release-notes-generator"
- "@semantic-release/changelog"
- path: "@semantic-release/npm"
Expand All @@ -17,4 +23,5 @@ plugins:
assets:
- "CHANGELOG.md"
- "package.json"
- "esi-shell"
message: "chore(release): ${nextRelease.version}\n\n${nextRelease.notes}"
5 changes: 5 additions & 0 deletions esi-shell
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ usage() {
echo "OPTIONS:"
echo " -h, --help Print this message"
echo " -t, --tag Specific esi-shell tag to use (Default: $IMAGE_TAG)"
echo " --version Print esi-shell version"
echo ""
echo "COMMAND is a command to execute in the container, leave it empty for interactive shell. For example:"
echo " pwd"
Expand Down Expand Up @@ -110,6 +111,10 @@ do
-h | --help)
usage 0
;;
--version)
echo "${ESI_SHELL_VERSION-}"
exit 0
;;
--)
shift
CONTAINER_OPTIONS="$@"
Expand Down

0 comments on commit 9c15c86

Please sign in to comment.