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

feature: Publish to OSSRH / MavenCentral #47

Closed
wants to merge 8 commits into from

Conversation

wba2hi
Copy link
Contributor

@wba2hi wba2hi commented Nov 27, 2023

Closes: #46

Closes: eclipse-kuksa#46
Signed-off-by: Andre Weber <andre.weber3@etas.com>
@wba2hi
Copy link
Contributor Author

wba2hi commented Nov 27, 2023

Comment on lines +33 to +36
ORG_GPG_PASSPHRASE: ${{ secrets.ORG_GPG_PASSPHRASE }}
ORG_GPG_PRIVATE_KEY: ${{ secrets.ORG_GPG_PRIVATE_KEY }}
ORG_OSSRH_PASSWORD: ${{ secrets.ORG_OSSRH_PASSWORD }}
ORG_OSSRH_USERNAME: ${{ secrets.ORG_OSSRH_USERNAME }}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

To be honest I have no clue, what happens with our fork once this branch is merged.
Since we don't have these secrets in the Bosch Global Organisation the workflow might start failing when this workflow is executed "locally" on our Bosch Global fork?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Due to this, it's also quite hard to test this in any other way than simply merging it and checking if it succeeds?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

}
}

gradle.taskGraph.whenReady {
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we rewrite this more like this so it does not loop through all the tasks even if it already found the correct task?
Maybe also add some println for information that the signing is disabled here :)

gradle.taskGraph.whenReady {
    tasks.withType(Sign::class) {
        
        val publishToMavenLocalTask = allTasks.find { "publishToMavenLocal" in it.name }
        var isPublishingToMavenLocal = publishToMavenLocalTask != null

        onlyIf { !isPublishingToMavenLocal }
    }
}

@wba2hi wba2hi closed this Nov 29, 2023
@wba2hi wba2hi deleted the feature-46 branch November 29, 2023 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Publish to OSSRH / MavenCentral
2 participants