Skip to content

Commit

Permalink
Merge pull request #366 from xenit-eu/DEVEM-535-h
Browse files Browse the repository at this point in the history
DEVEM-535 replace gradle env and fix publishing url
  • Loading branch information
todorinskiz authored Sep 7, 2023
2 parents 304b132 + 2fa479f commit 553b7e5
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 22 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,10 @@ name: CI
on:
push:
workflow_dispatch:
schedule:
- cron: '7 0 * * SUN'
env:
ORG_GRADLE_PROJECT_alfresco_nexus_username: ${{ secrets.ALFRESCO_NEXUS_USERNAME }}
ORG_GRADLE_PROJECT_alfresco_nexus_password: ${{ secrets.ALFRESCO_NEXUS_PASSWORD }}

GRADLE_OPTS: >-
-Dorg.gradle.project.org.alfresco.maven.nexus.username=${{ secrets.ALFRESCO_NEXUS_USERNAME }}
-Dorg.gradle.project.org.alfresco.maven.nexus.password=${{ secrets.ALFRESCO_NEXUS_PASSWORD }}
jobs:
test:
runs-on: ubuntu-latest
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Version template:
-->
# Dynamic Extensions For Alfresco Changelog

## [4.0.0] - 2023-07-18
## [3.1.0] - 2023-07-18

### Added

Expand Down
15 changes: 1 addition & 14 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -24,29 +24,16 @@ sonarqube {
}
}

def copyPropertyValueIfExists(sourcePropertyName, targetPropertyName) {
if (project.hasProperty(sourcePropertyName)) {
project.ext[targetPropertyName] = project.property(sourcePropertyName)
}
}

allprojects {
group = 'eu.xenit.de'
version = '3.0.0'
version = '3.1.0'

boolean isRelease = ci.branch?.startsWith("release")
if (!isRelease) {
version += "-SNAPSHOT"
}

// It is not possible to set properties with a dot via GitHub Actions env variables, therefore we introduce support
// for a non-dotted-equivalent
copyPropertyValueIfExists('alfresco_nexus_username', 'org.alfresco.maven.nexus.username')
copyPropertyValueIfExists('alfresco_nexus_password', 'org.alfresco.maven.nexus.password')
copyPropertyValueIfExists('xenit_docker_registry_url', 'eu.xenit.docker.registry.url')
copyPropertyValueIfExists('xenit_docker_registry_username', 'eu.xenit.docker.registry.username')
copyPropertyValueIfExists('xenit_docker_registry_password', 'eu.xenit.docker.registry.password')

project.pluginManager.withPlugin('java-base') {
project.sourceCompatibility = 1.8
}
Expand Down
4 changes: 2 additions & 2 deletions publish.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ publishing {

repositories {
maven {
def releasesRepoUrl = "https://oss.sonatype.org/service/local/staging/deploy/maven2/"
def snapshotsRepoUrl = "https://oss.sonatype.org/content/repositories/snapshots/"
def releasesRepoUrl = "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/"
def snapshotsRepoUrl = "https://s01.oss.sonatype.org/content/repositories/snapshots/"
url = version.endsWith('SNAPSHOT') ? snapshotsRepoUrl : releasesRepoUrl

credentials {
Expand Down

0 comments on commit 553b7e5

Please sign in to comment.