Skip to content

Commit

Permalink
Tweak actions for PRs (#217)
Browse files Browse the repository at this point in the history
  • Loading branch information
Technici4n authored Oct 31, 2023
1 parent b893ffd commit 9a8dc60
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/build-prs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,21 @@ on:
- reopened

jobs:
jdk17:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.ref }}
fetch-depth: 1000
fetch-tags: true

# GradleUtils will append the branch name to the version,
# but for that we need a properly checked out branch
- name: Create branch for commit
run:
git switch -C pr-${{ github.event.pull_request.number }}-${{ github.event.pull_request.head.ref }}

- name: Setup JDK 17
uses: actions/setup-java@v2
with:
Expand Down
3 changes: 3 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ changelog {
disableAutomaticPublicationRegistration()
}

// Print version, generally useful to know - also appears on CI
System.out.println("NeoForge version ${gradleutils.version.toString()}")

allprojects {
version gradleutils.version.toString()
group 'net.neoforged'
Expand Down

0 comments on commit 9a8dc60

Please sign in to comment.