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

Bind generate wrappers task to Gradle build #34

Closed
xaviarias opened this issue Jan 9, 2020 · 1 comment
Closed

Bind generate wrappers task to Gradle build #34

xaviarias opened this issue Jan 9, 2020 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@xaviarias
Copy link
Contributor

The Gradle task generateCorDappWrappers should be run automatically when running the build task.

Users should not be required to be aware of the task unless they want to call it explicitly.

@xaviarias xaviarias self-assigned this Jan 9, 2020
@xaviarias xaviarias added the bug Something isn't working label Jan 9, 2020
@xaviarias
Copy link
Contributor Author

xaviarias commented Jan 9, 2020

This is related to a similar issue in web3j-gradle-plugin. The proposed solution would be to add a Gradle snippet to make compileKotlin depend on generateCorDappWrappers:

compileKotlin {
    kotlinOptions.jvmTarget = '1.8'
    dependsOn 'generateCorDappWrappers'
}

If you have Java code on your project, also add:

sourceSets {
    main.kotlin.srcDirs += "$rootProject/src/main/java"
    test.kotlin.srcDirs += "$rootProject/src/test/java"
}

Note that for this to work, parallel execution must be disabled by adding org.gradle.parallel=false to your Gradle properties. Unfortunately, at the moment is not possible to disable parallel execution on specific tasks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant