Skip to content

Create draft release when v* (eg v0.1.0) tag is pushed #44

Create draft release when v* (eg v0.1.0) tag is pushed

Create draft release when v* (eg v0.1.0) tag is pushed #44

Workflow file for this run

# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-gradle
name: Java CI with Gradle
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:
env:
artifact_name: ${{ github.event.repository.name }}-${{ env.GITHUB_REF_NAME }}

Check failure on line 14 in .github/workflows/gradle.yml

View workflow run for this annotation

GitHub Actions / Java CI with Gradle

Invalid workflow file

The workflow is not valid. .github/workflows/gradle.yml (Line: 14, Col: 18): Unrecognized named-value: 'env'. Located at position 1 within expression: env.GITHUB_REF_NAME
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
- name: Validate Gradle wrapper
uses: gradle/[email protected]
- name: Build with Gradle
uses: gradle/[email protected]
with:
arguments: build
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
name: ${{ env.artifact_name }}
path: build/libs
retention-days: 7