Skip to content

Commit

Permalink
test publication
Browse files Browse the repository at this point in the history
  • Loading branch information
trdelnk committed Jun 18, 2024
1 parent 47cb47a commit bfb4a83
Showing 1 changed file with 14 additions and 50 deletions.
64 changes: 14 additions & 50 deletions .github/workflows/publish-to-maven.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
name: Publish to Maven Central

on:
workflow_dispatch:
inputs:
version:
description: 'Library release version'
required: true
push:
branches:
- publish-to-maven

env:
NEW_VERSION: ${{ github.event.inputs.version }}
Expand All @@ -21,7 +18,7 @@ jobs:
strategy:
matrix:
include:
- os: macos-latest
# - os: macos-latest
- os: ubuntu-latest
runs-on: ${{ matrix.os }}
steps:
Expand All @@ -30,6 +27,8 @@ jobs:

- name: Setup node
uses: actions/setup-node@v4
with:
node-version: 20

- name: Validate Gradle Wrapper
uses: gradle/actions/wrapper-validation@v3
Expand All @@ -50,11 +49,12 @@ jobs:
~/.konan
key: ${{ runner.os }}-${{ hashFiles('**/.lock') }}

# Нужна ли эта проверка?
- name: Ensure main branch
run: ./.github/sh/validate_publishing_branch.sh

- name: Validate library version update
run: ./.github/sh/validate_version_update.sh "libraryVersion" "$NEW_VERSION"
# - name: Validate library version update
# run: ./.github/sh/validate_version_update.sh "libraryVersion" "$NEW_VERSION"

- name: Validate publishing
run: |
Expand All @@ -63,45 +63,9 @@ jobs:
-xlint \
publishToMavenLocal
# publish:
# env:
# ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.ORG_GRADLE_PROJECT_MAVENCENTRALUSERNAME }}
# ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.ORG_GRADLE_PROJECT_MAVENCENTRALPASSWORD }}
# ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGINMEMORYKEY }}
# ORG_GRADLE_PROJECT_signingInMemoryKeyId: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGINMEMORYKEYID }}
# ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGINMEMORYKEYPASSWORD }}
#
# strategy:
# matrix:
# include:
# - target: publishToMavenLocal
# os: macos-latest
# - target: publishToMavenLocal
# os: ubuntu-latest
# runs-on: ${{ matrix.os }}
#
# steps:
# - name: Checkout
# uses: actions/checkout@v4
#
# - name: Validate Gradle Wrapper
# uses: gradle/wrapper-validation-action@v3
#
# - name: Setup JDK 17
# uses: actions/setup-java@v3
# with:
# java-version: '17'
# distribution: "zulu"
#
# - name: Setup Gradle cache
# uses: actions/cache@v3
# with:
# path: |
# ~/.konan
# key: ${{ runner.os }}-${{ hashFiles('**/.lock') }}
#
# - name: Setup Gradle
# uses: gradle/actions/setup-gradle@v3
#
# - name: Gradle publish
# run: ./gradlew ${{ matrix.target }}
# - name: Publishing
# run: |
# ./gradlew \
# -xtest \
# -xlint \
# publishToMavenLocal

0 comments on commit bfb4a83

Please sign in to comment.