-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (37 loc) · 1.06 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: Build Mod
on:
push:
branches:
- "*"
- "*/*"
- "!api"
- "!update"
tags:
- "v*"
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Generate build number
uses: Team-Fruit/build-number@v2
with:
token: ${{secrets.github_token}}
- name: Set up JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Build with Gradle
env:
GRADLE_OPTS: -Dorg.gradle.daemon=false
TRAVIS: true
CURSEFORGE_TOKEN: ${{secrets.curseforge_token}}
GH_TOKEN: ${{secrets.github_token}}
BINTRAY_USER: ${{secrets.bintray_user}}
BINTRAY_KEY: ${{secrets.bintray_key}}
run: |
export TRAVIS_TAG=$(bash -c "if [[ ${GITHUB_REF} == refs/tags/* ]] ; then echo ${GITHUB_REF##*/} ; else echo ; fi")
export TRAVIS_BUILD_NUMBER=${BUILD_NUMBER}
chmod a+x ./gradlew
./gradlew clean setupCIWorkspace --continue
./gradlew build githubRelease curseforge bintrayUpload publish --continue