Skip to content

set up 2.5.x branch (#205) #12

set up 2.5.x branch (#205)

set up 2.5.x branch (#205) #12

Workflow file for this run

name: Publish Draft Release
# copied from Dafny repo
on:
workflow_dispatch:
push:
tags:
- 'v*'
env:
CARGO_TERM_COLOR: always
jobs:
run-tests:
name: Rust project - latest
runs-on: ubuntu-latest
strategy:
matrix:
toolchain:
- stable
steps:
- name: Checkout cedar-java
uses: actions/checkout@v3
- name: Checkout cedar
uses: actions/checkout@v3
with:
repository: cedar-policy/cedar
ref: main
path: ./cedar
- name: rustup
run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
- name: cargo fmt
working-directory: ./CedarJavaFFI
run: cargo fmt --all --check
- name: cargo rustc
working-directory: ./CedarJavaFFI
run: RUSTFLAGS="-F unsafe-code" cargo build --verbose
- name: cargo test
working-directory: ./CedarJavaFFI
run: cargo test --verbose
- name: Build CedarJava
working-directory: ./CedarJava
shell: bash
run: bash config.sh && ./gradlew build
get-version:
runs-on: ubuntu-22.04
steps:
- id: get-version
uses: battila7/get-version-action@v2
- run: echo ${{ steps.get-version.outputs.version }}
- run: echo ${{ steps.get-version.outputs.version-without-v }}
outputs:
version: ${{ steps.get-version.outputs.version-without-v }}
publish-release:
needs: [run-tests, get-version]
permissions:
contents: write
uses: ./.github/workflows/publish_release_reusable.yml
with:
name: ${{ needs.get-version.outputs.version }}
sha: ${{ github.sha }}
tag_name: ${{ github.ref }}
draft: true
# We can probably automate pulling this out of RELEASE_NOTES.md in the future
release_notes: ""