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

Add bisq v1 post build plugin #2

Merged
merged 2 commits into from
Jul 25, 2022

Conversation

ghubstan
Copy link
Contributor

Define custom task postBuild in standalone Gradle plugin with ID bisq.post-build.
Task runs at end of importing project's build task to copy startup script and lib dir to root project directory.

Replaces PR #1.

@ghubstan
Copy link
Contributor Author

ghubstan commented Jul 24, 2022

@ripcurlx @alvasw , I copied the task postBuild into a standalone plugin based on the one you (@alvasw) showed me in #1 (comment)

It works in this consuming bisq-pricenode project.

I think the only important diffs are the standalone plugin project has gradlew scripts, so it can be compiled in its own project.

Copy link
Contributor

@bisq-github-admin-3 bisq-github-admin-3 left a comment

Choose a reason for hiding this comment

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

utACK

@bisq-github-admin-3 bisq-github-admin-3 merged commit 2c34836 into bisq-network:main Jul 25, 2022
@alvasw
Copy link

alvasw commented Jul 25, 2022

Looks good, but there's a little mistake. You forgot to add the following snippet in the settings.gradle file:

pluginManagement {
    repositories {
        gradlePluginPortal()
    }
    includeBuild('bisq-gradle')
}

It was also my bad not to remove it in the Proof of Concept.

You can take a look at the Bisq 2 settings.gradle file at
https://github.com/bisq-network/bisq2/blob/660c3ac2bc038d563ea1c14d4a09e3e3d5cd5ae3/settings.gradle#L5

@ghubstan
Copy link
Contributor Author

Looks good, but there's a little mistake. You forgot to add the following snippet in the settings.gradle file:

The consuming project (a different repo) does have the includeBuild: https://github.com/ghubstan/bisq-pricenode/blob/87a1decee7905b496d1db02f0d2d4df27c25adc2/settings.gradle#L3

So I'm a little confused... I think it's OK.

@ghubstan ghubstan deleted the add-post-build-plugin branch July 25, 2022 19:36
ghubstan added a commit to ghubstan/bisq-pricenode that referenced this pull request Jul 25, 2022
Is being replaced by bisq-network's bisq-gradle plugin because PR
bisq-network/bisq-gradle#2 has been merged.
@alvasw
Copy link

alvasw commented Jul 27, 2022

The consuming project (a different repo) does have the includeBuild: https://github.com/ghubstan/bisq-pricenode/blob/87a1decee7905b496d1db02f0d2d4df27c25adc2/settings.gradle#L3

So I'm a little confused... I think it's OK.

You're calling includeBuild(...) [1] on the Settings DSL instead on the PluginManagementSpec DSL [2]. The included project is a plugin and not a regular project.

Yeah, it works, and you don't have to change it. It's up to you.

[1] https://docs.gradle.org/current/dsl/org.gradle.api.initialization.Settings.html#org.gradle.api.initialization.Settings:includeBuild(java.lang.Object)
[2] https://docs.gradle.org/current/dsl/org.gradle.plugin.management.PluginManagementSpec.html#org.gradle.plugin.management.PluginManagementSpec:includeBuild(java.lang.String)

@ghubstan
Copy link
Contributor Author

You're calling includeBuild(...) [1] on the Settings DSL instead on the PluginManagementSpec DSL [2]. The included project is a plugin and not a regular project.

I see. My mistake. I will read about this and change it in another PR.

ghubstan added a commit to ghubstan/bisq-pricenode that referenced this pull request Jul 27, 2022
We're including the `bisq-gradle` plugin build, not a project build,
and we must call `includeBuild('bisq-gradle')` on the `PluginManagementSpec`
DSL, not the `Settings` DSL.

See https://docs.gradle.org/current/javadoc/org/gradle/plugin/management/PluginManagementSpec.html.

Resolves bisq-network/bisq-gradle#2 (comment).
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.

3 participants