Extract from main 2.11 branch things not specific to 2.11 Part 3 (#1243) #274
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build Main | |
on: | |
push: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
BUILD_EVENT: ${{ github.event_name }} | |
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }} | |
OSSRH_PASSWORD: ${{ secrets.OSSRH_TOKEN }} | |
SIGNING_KEY_ID: ${{ secrets.SIGNING_KEY_ID }} | |
SIGNING_KEY: ${{ secrets.SIGNING_KEY }} | |
SIGNING_PASSWORD: ${{ secrets.SIGNING_PASSWORD }} | |
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
GODEBUG: x509sha1=1 | |
steps: | |
- name: Setup JDK | |
uses: actions/setup-java@v4 | |
with: | |
java-version: '8' | |
distribution: 'temurin' | |
- name: Setup GO | |
uses: actions/setup-go@v5 | |
with: | |
go-version: '1.21.4' | |
- name: Install Nats Server | |
run: | | |
cd $GITHUB_WORKSPACE | |
git clone https://github.com/nats-io/nats-server.git | |
cd nats-server | |
go get | |
go build main.go | |
mkdir -p ~/.local/bin | |
cp main ~/.local/bin/nats-server | |
cd .. | |
rm -rf nats-server | |
nats-server -v | |
- name: Check out code | |
uses: actions/checkout@v4 | |
- name: Build and Test | |
run: chmod +x gradlew && ./gradlew clean test jacocoTestReport coveralls | |
- name: Verify Javadoc | |
run: ./gradlew javadoc | |
- name: Publish Snapshot | |
run: ./gradlew -i publishToSonatype |