Update README.md #83
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: Snapshot | |
on: | |
push: | |
branches: [ "main" ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout project | |
uses: actions/checkout@v3 | |
- name: Setup Java JDK and Maven | |
uses: actions/setup-java@v3 | |
with: | |
distribution: 'temurin' | |
java-version: '8' | |
server-id: ossrh | |
server-username: MAVEN_USERNAME | |
server-password: MAVEN_PASSWORD | |
gpg-private-key: ${{ secrets.GPG_SECRET }} | |
gpg-passphrase: MAVEN_GPG_PASSPHRASE | |
- name: Configure Git user | |
run: | | |
git config user.email "[email protected]" | |
git config user.name "GitHub Actions" | |
- name: Cache local Maven repository | |
uses: actions/cache@v3 | |
with: | |
path: ~/.m2/repository | |
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | |
restore-keys: | | |
${{ runner.os }}-maven- | |
- name: Publish Snaphot package | |
run: | | |
mvn -B deploy -P deploy -Dmaven.test.skip --file starlight/pom.xml --no-transfer-progress | |
mvn -B deploy -P deploy -Dmaven.test.skip --file spring-cloud-starter-baidu-starlight/pom.xml --no-transfer-progress | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
MAVEN_USERNAME: ${{ secrets.OSSRH_USER }} | |
MAVEN_PASSWORD: ${{ secrets.OSSRH_PASSWD }} | |
MAVEN_GPG_PASSPHRASE: ${{ secrets.GPG_PASSWD }} |