-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
105 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
name: Release | ||
|
||
on: | ||
push: | ||
branches: | ||
- semrel | ||
|
||
jobs: | ||
build-test-release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Define environment variables | ||
run: echo IMAGE_NAME=ghcr.io/$(echo ${{ github.repository }} | tr '[:upper:]' '[:lower:]') >> $GITHUB_ENV | ||
|
||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 # Important for Semantic Release to analyze all commits | ||
|
||
- name: Set up Docker buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Build container | ||
uses: docker/build-push-action@v5 | ||
with: | ||
file: Dockerfile.test | ||
tags: ${{ env.IMAGE_NAME }}:pre-semver | ||
load: true | ||
cache-from: ${{ env.IMAGE_NAME }}:latest | ||
|
||
- name: Run tests | ||
run: docker run ${{ env.IMAGE_NAME }}:pre-semver curl --version | ||
|
||
- name: Semantic release | ||
uses: cycjimmy/semantic-release-action@v4 | ||
id: semantic | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ steps.semantic.outputs.new_release_git_tag }} | ||
|
||
- name: Login to GitHub container registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Build container | ||
uses: docker/build-push-action@v5 | ||
with: | ||
file: Dockerfile.test | ||
tags: | | ||
${{ env.IMAGE_NAME }}:latest | ||
${{ env.IMAGE_NAME }}:${{ steps.semantic.outputs.new_release_version }} | ||
push: true | ||
cache-from: ${{ env.IMAGE_NAME }}:pre-semver |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# See https://semantic-release.gitbook.io/semantic-release/usage/configuration | ||
branches: | ||
- semrel | ||
tagFormat: '${version}' # without this, the tag is prefixed with a 'v' | ||
plugins: | ||
- "@semantic-release/commit-analyzer" | ||
- "@semantic-release/release-notes-generator" | ||
- "@semantic-release/changelog" | ||
- path: "@semantic-release/npm" | ||
npmPublish: false | ||
- path: "@semantic-release/git" | ||
assets: | ||
- "CHANGELOG.md" | ||
- "package.json" | ||
message: "chore(release): ${nextRelease.version}\n\n${nextRelease.notes}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# syntax=docker/dockerfile:latest | ||
|
||
FROM nvcr.io/nvidia/cuda:11.8.0-runtime-ubuntu22.04 | ||
|
||
ARG DEBIAN_FRONTEND=noninteractive | ||
|
||
RUN apt update && apt install -y curl |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
{ | ||
"name": "esi-opticks", | ||
"version": "1.2.0", | ||
"description": "esi shell project", | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/BNLNPPS/esi-opticks.git" | ||
}, | ||
"keywords": [], | ||
"author": "BNL NPPS", | ||
"license": "MIT", | ||
"bugs": { | ||
"url": "https://github.com/BNLNPPS/esi-opticks/issues" | ||
}, | ||
"homepage": "https://github.com/BNLNPPS/esi-opticks#readme", | ||
"devDependencies": { | ||
"@semantic-release/changelog": "^6.0.3", | ||
"@semantic-release/commit-analyzer": "^12.0.0", | ||
"@semantic-release/git": "^10.0.1", | ||
"@semantic-release/release-notes-generator": "^13.0.0", | ||
"semantic-release": "^23.0.8" | ||
} | ||
} |