Skip to content

Merge pull request #3 from Ecdcaeb/———— #122

Merge pull request #3 from Ecdcaeb/————

Merge pull request #3 from Ecdcaeb/———— #122

Workflow file for this run

# This workflow will build and upload test artifact
# Simple workflow with ignoring condition to prevent unneccessary build
# To download artifact check on job task
name: Build Test Artifact
on:
push:
pull_request:
jobs:
build:
name: Build and Test For example
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Cache Gradle
uses: actions/cache@v3
with:
path: ~/.npm
~/.gradle/
~/build/
key: ${{hashFiles('build.gradle') }}-${{hashFiles('gradle.properties') }}
restore-keys: |
${{hashFiles('build.gradle') }}-${{hashFiles('gradle.properties') }}
- name: Grant Execute Permission for gradlew
run: chmod +x gradlew
- name: Change Mod version
run: sed -i "s/mod_version.*=.*/mod_version = test/g" modmetadata.properties
- name: Setup Java
uses: actions/setup-java@v3
with:
java-version: '21'
distribution: 'zulu'
cache: gradle
- name: Build
uses: gradle/gradle-build-action@v2
with:
arguments: build --info --stacktrace
- name: Upload Build Artifacts
uses: actions/upload-artifact@v4
with:
name: example-1.12.2
path: build/libs