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

Enable version catalogs #1428

Merged
merged 7 commits into from
Apr 7, 2022
Merged

Enable version catalogs #1428

merged 7 commits into from
Apr 7, 2022

Conversation

Goooler
Copy link
Contributor

@Goooler Goooler commented Mar 21, 2022

Description

https://docs.gradle.org/current/userguide/platforms.html

Addressed from #1316.

Checklist

  • PR description added
  • tests are added
  • CHANGELOG.md is updated

In case of adding a new rule:

  • README.md is updated
  • Rule has been applied on Ktlint itself and violations are fixed

}

test {
useJUnitPlatform()
}

task ktlint(type: JavaExec, dependsOn: classes) {
main = 'com.pinterest.ktlint.Main'
task ktlint(type: JavaExec, dependsOn: classes, group: LifecycleBasePlugin.VERIFICATION_GROUP) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Solve ktlint task doesn't appear in verification group, link #1316 (comment).

[versions]
gradle = "7.4"
gradleSha256 = "8cc27038d5dbd815759851ba53e70cf62e481b87494cc97cfd97982ada5ba634"
kotlin = "1.6.0"
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this accessible in build.gradle.kts? That's where we define the Kotlin version (or the kotlin-dev version for snapshots)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've done in Goooler@8d719fd, but something wrong with checksums, it might be a bug of Gradle when using VC in buildSrc with checksums enabled, should we delete verification-metadata.xml?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Filed a bug to gradle/gradle#20234.

Copy link
Collaborator

Choose a reason for hiding this comment

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

I've done in Goooler@8d719fd, but something wrong with checksums, it might be a bug of Gradle when using VC in buildSrc with checksums enabled, should we delete verification-metadata.xml?

Your change Use VC in buildSrc addresses the problem of the distinct kotlinDev version. In this commit the version was actually changed and has been merged to master already. Merging this PR would result in reverting the kotlinDev version in the snapshot. If you can mitigate this, I am happy to merge the PR.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've tried again in Goooler@08fefbe, but still failed.
The problem is related to dependency verification, it works if I delete verification-metadata.xml.

@Goooler
Copy link
Contributor Author

Goooler commented Mar 29, 2022

May we can merge this PR first?

@paul-dingemans
Copy link
Collaborator

May we can merge this PR first?

See remark:

Your change Use VC in buildSrc addresses the problem of the distinct kotlinDev version. In this commit the version was actually changed and has been merged to master already. Merging this PR would result in reverting the kotlinDev version in the snapshot. If you can mitigate this, I am happy to merge the PR.

@paul-dingemans paul-dingemans merged commit c426471 into pinterest:master Apr 7, 2022
@paul-dingemans
Copy link
Collaborator

Thnx for your contribution @Goooler

@paul-dingemans paul-dingemans added this to the 0.46.0 milestone Apr 7, 2022
@Goooler Goooler deleted the vc branch April 8, 2022 01:44
@Goooler Goooler mentioned this pull request Apr 8, 2022
5 tasks
@Goooler Goooler mentioned this pull request Sep 2, 2022
6 tasks
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