Skip to content

Run with build cache by default #1596

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

Merged
merged 1 commit into from
Mar 2, 2023
Merged

Conversation

Goooler
Copy link
Member

@Goooler Goooler commented Feb 28, 2023

  • Enable --stacktrace and --info flags for all GradleRunners, easy to get more valuable info from test failures.
  • Remove extra --build-cache flags on CI, cause I enabled caching in a9ad736.

@nedtwigg
Copy link
Member

nedtwigg commented Mar 1, 2023

Looks like ./gradlew testNpm is actually failing.

Also, just FYI, I'm okay to merge this, but the --stacktrace everywhere is certainly going to drift. If you want them to always be there, it either needs to be a function or something like this.

def noInternalDepsClosure = {
String text = it
/*
* No good way to get around using this import:
* https://github.com/gradle/gradle/issues/3191
*/
String regex = "import org\\.gradle\\.api\\.internal\\.(?!plugins\\.DslObject)(?!project\\.ProjectInternal)"
if ((text.contains('import org.gradle.internal.') || text.find(regex)) &&
!text.contains('def noInternalDepsClosure')) {
throw new AssertionError("Accidental internal import")
}
}
if (project != rootProject) {
// the rootProject doesn't have any java
java {
ratchetFrom 'origin/main'
bumpThisNumberIfACustomStepChanges(1)
licenseHeaderFile rootProject.file('gradle/spotless.license')
importOrderFile rootProject.file('gradle/spotless.importorder')
eclipse().configFile rootProject.file('gradle/spotless.eclipseformat.xml')
trimTrailingWhitespace()
removeUnusedImports()
// TODO: formatAnnotations()
custom 'noInternalDeps', noInternalDepsClosure

@Goooler Goooler force-pushed the enable_cc_for_tests branch from df44ba9 to 0a3e694 Compare March 2, 2023 01:59
@Goooler
Copy link
Member Author

Goooler commented Mar 2, 2023

Alright, just dropped ec968af for now.

@Goooler Goooler changed the title Tweak Gradle flags Run with build cache by default Mar 2, 2023
@Goooler Goooler force-pushed the enable_cc_for_tests branch from 0a3e694 to 771d5e3 Compare March 2, 2023 02:00
@nedtwigg nedtwigg merged commit 6789a1d into diffplug:main Mar 2, 2023
@Goooler Goooler deleted the enable_cc_for_tests branch March 2, 2023 02:06
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.

2 participants