forked from DmitriiShamrikov/mslinks
-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (31 loc) · 1009 Bytes
/
publish.yml
File metadata and controls
38 lines (31 loc) · 1009 Bytes
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
name: Publish
on:
push:
branches: [ main, hotfix , add-publish ]
workflow_dispatch:
jobs:
publish:
if: ${{ github.repository == 'JabRef/mslinks' }}
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Set up JDK
uses: actions/setup-java@v5
with:
distribution: 'temurin' # See 'Supported distributions' for available options
java-version: '17'
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v5
with:
gradle-home-cache-cleanup: true
- name: Build
run: ./gradlew build
- name: Publish to Sonatype (for snapshots) or to Maven Central
run: ./gradlew publish closeAndReleaseStagingRepositories
env:
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
OSSRH_TOKEN: ${{ secrets.OSSRH_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SIGNING_KEY: ${{ secrets.SIGNING_KEY }}
SIGNING_PASSWORD: ${{ secrets.SIGNING_PASSWORD }}