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

fix: build issue with single publish #79

Merged
merged 1 commit into from
Aug 30, 2022
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
11 changes: 9 additions & 2 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,18 @@ jobs:
GPG_SIGNING_KEY: ${{ secrets.GPG_SIGNING_KEY }}

# Release Please has already incremented versions and published tags, so we just need to publish.
# Our maven config will only publish versions that do not already exist.
- name: Maven Verify Deploy
if: ${{ steps.release.outputs.releases_created }}
# The nexus-staging-maven-plugin doesn't follow maven conventions. It stages all the projects with the last submodule: https://help.sonatype.com/repomanager2/staging-releases/configuring-your-project-for-deployment
# This means there's no way to skip publishing of a particular module in a multi-module build, so we iterate over each module and publish them individually,
# letting exists-maven-plugin skip the nexus-staging-maven-plugin's entire deploy goal if the artifact exists.
run: |
mvn --batch-mode --settings release/m2-settings.xml verify deploy
mvn verify
modules=($(mvn help:evaluate -Dexpression=project.modules | grep -v "^\[" | grep -v "<\/*strings>" | sed 's/<\/*string>//g' | sed 's/[[:space:]]//'))
for module in "${modules[@]}"
do
mvn --batch-mode --projects $module --settings release/m2-settings.xml clean deploy
done
env:
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
5 changes: 0 additions & 5 deletions hooks/open-telemetry/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,6 @@
</developer>
</developers>

<properties>
<!-- override no-deploy rule from parent -->
<maven.deploy.skip>false</maven.deploy.skip>
</properties>

<dependencies>
<!-- we inherent dev.openfeature.javasdk and the test dependencies from the parent pom -->
</dependencies>
Expand Down
4 changes: 1 addition & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@
</scm>

<properties>
<!-- skip deploy in parent (need to override this in submodules) -->
<maven.deploy.skip>true</maven.deploy.skip>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>${maven.compiler.source}</maven.compiler.target>
<junit.jupiter.version>5.8.1</junit.jupiter.version>
Expand Down Expand Up @@ -250,7 +248,7 @@
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<phase>deploy</phase>
<goals>
<goal>sign</goal>
</goals>
Expand Down
5 changes: 0 additions & 5 deletions providers/flagd/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,6 @@
</developer>
</developers>

<properties>
<!-- override no-deploy rule from parent -->
<maven.deploy.skip>false</maven.deploy.skip>
</properties>

<dependencies>
<!-- we inherent dev.openfeature.javasdk and the test dependencies from the parent pom -->
</dependencies>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public FlagdProvider() {
}

/**
* A test method...
* A test method.
*
* @return {boolean}
*/
Expand Down