forked from MirrorHub/authlib-injector
Add CircleCI support
This commit is contained in:
parent
0113845209
commit
2f3a656d89
1 changed files with 32 additions and 0 deletions
32
.circleci/config.yml
Normal file
32
.circleci/config.yml
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
version: 2
|
||||||
|
general:
|
||||||
|
branches:
|
||||||
|
only:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
docker:
|
||||||
|
- image: circleci/openjdk:8-jdk
|
||||||
|
working_directory: ~/authlib-injector
|
||||||
|
environment:
|
||||||
|
JVM_OPTS: -Xmx3200m
|
||||||
|
TERM: dumb
|
||||||
|
steps:
|
||||||
|
- checkout
|
||||||
|
- restore_cache:
|
||||||
|
keys:
|
||||||
|
- v1-cache
|
||||||
|
- run: 'git clone --single-branch --branch=toolchain --depth=1 git@github.com:yushijinhun/authlib-injector.yushi.moe ~/tools'
|
||||||
|
- run: 'echo $(( $(~/tools/get-latest-build-number.sh) + 1 )) > ~/build_number && echo "Build Number: $(<~/build_number)"'
|
||||||
|
- run: '~/tools/authlib-injector-deploy.sh --local-repo ~/authlib-injector.yushi.moe update-local-repo'
|
||||||
|
- run: 'AI_BUILD_NUMBER="$(<~/build_number)" gradle dependencies'
|
||||||
|
- run: 'AI_BUILD_NUMBER="$(<~/build_number)" gradle'
|
||||||
|
- store_artifacts:
|
||||||
|
path: ~/authlib-injector/build/libs
|
||||||
|
- run: '~/tools/authlib-injector-deploy.sh upload "$(<~/build_number)" ~/authlib-injector/build/libs/*.jar'
|
||||||
|
- save_cache:
|
||||||
|
paths:
|
||||||
|
- ~/.gradle
|
||||||
|
- ~/authlib-injector.yushi.moe
|
||||||
|
key: v1-cache-{{ epoch }}
|
Loading…
Reference in a new issue