Skip to content

Commit

Permalink
publish pre-release OCK
Browse files Browse the repository at this point in the history
  • Loading branch information
MaryaSharf committed Dec 21, 2023
1 parent fbca730 commit 17b3d33
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/create_publish_artifacts.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
name: Build and Package
on:
pull_request:
paths:
- '.github/workflows/create_release.yml'
schedule:
- cron: '0 0 * * *' # Runs the workflow at midnight every day
# Allows you to run this workflow manually from the Actions tab
Expand Down Expand Up @@ -61,3 +64,38 @@ jobs:
with:
name: riscv-build
path: ock_build.tar.gz

ock_nightly:
name: OCK Nightly Build Upload
runs-on: ubuntu-22.04
needs: [run_riscv_m1_nightly_package]

steps:
- name: Download artifacts
uses: actions/download-artifact@v3
with:
name: riscv-build
path: ock_build.tar.gz

- name: Compute tag
id: tag
run: |
if [ "${{ github.event_name == 'schedule' }}" == "true" ]; then
echo "TAG=$(date +'%Y-%m-%d')" >> "$GITHUB_OUTPUT"
else
# TODO: Use date of the commit?
echo "TAG=$(date +'%Y-%m-%d')-${GITHUB_SHA::7}" >> "$GITHUB_OUTPUT"
fi
- name: Create Nightly OCK pre-release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
files:
$(pwd)/ock_build.tar.gz
tag_name: nightly-${{ steps.tag.outputs.TAG }}
name: OCK daily ${{ steps.tag.outputs.TAG }}
prerelease: true
body: "Daily build ${{ steps.tag.outputs.TAG }}"
target_commitish: ${{ github.sha }}

0 comments on commit 17b3d33

Please sign in to comment.