Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CAB-6232 publish pws-client to github packages instead of uw artifacory #98

Merged
merged 3 commits into from
Dec 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,16 @@ jobs:
run: ./gradlew build
- name: Deploy artifacts
run: ./gradlew build artifactoryPublish
- name: Publish package to github packages
uses: gradle/gradle-build-action@v2
with:
arguments: publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Slack Notification
if: ${{ failure() }}
uses: rtCamp/action-slack-notify@v2
env:
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
SLACK_TITLE: gws-client Build Alert
SLACK_COLOR: '#ff0000'
SLACK_COLOR: '#ff0000'
15 changes: 13 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ buildscript {
repositories {
jcenter()
maven { url 'https://repo.spring.io/milestone' }
maven { url 'https://repo.spring.io/plugins-release' }
maven { url 'https://repo.spring.io/plugins-snapshot' }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rather than switching to a snapshot release, we could use maven central for pulling release versions of the dependencies.

Spring no longer offers release versions from their own repo.spring.io, it relies on maven central

from https://spring.io/blog/2022/12/14/notice-of-permissions-changes-to-repo-spring-io-january-2023

repo.spring.io is intended for the download of snapshots and milestone artifacts that are not available from Maven Central.

see maven central for release versions:
https://mvnrepository.com/artifact/io.spring.gradle/propdeps-plugin

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you click on a released version, you would see the following note:
Note: this artifact is located at Spring Plugins repository (https://repo.spring.io/plugins-release/)

If you scroll down to the comments section of https://spring.io/blog/2022/12/14/notice-of-permissions-changes-to-repo-spring-io-january-2023, you would notice that other people had trouble getting it from maven central.

maven { url "https://raw.githubusercontent.com/uw-it-edm/edm-artifacts/master" }
maven { url "https://plugins.gradle.org/m2/" }
}
Expand All @@ -16,7 +16,7 @@ buildscript {
classpath "gradle.plugin.com.gorylenko.gradle-git-properties:gradle-git-properties:1.5.2"
classpath("org.jfrog.buildinfo:build-info-extractor-gradle:4.8.1")
classpath("nu.studer:gradle-credentials-plugin:1.0.4")
classpath 'io.spring.gradle:propdeps-plugin:0.0.9.RELEASE'
classpath 'io.spring.gradle:propdeps-plugin:0.0.8-SNAPSHOT'
}
}

Expand Down Expand Up @@ -68,6 +68,17 @@ allprojects {
}

publishing {
repositories {
maven {
name = "GitHubPackages"
url = "https://maven.pkg.github.com/uw-it-edm/pws-client"
credentials {
username = System.getenv("GITHUB_ACTOR") ?: System.getenv("USER")
password = System.getenv("GITHUB_TOKEN") ?: System.getenv("GITHUB_PAT")
}
}
}

publications {
mavenJava(MavenPublication) {
from components.java
Expand Down
Loading