Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
SupremeMortal committed Sep 6, 2023
2 parents d2efaf7 + 3bfe3a4 commit 6158ed4
Show file tree
Hide file tree
Showing 73 changed files with 38,165 additions and 14,690 deletions.
2 changes: 2 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"import/no-namespace": "off",
"i18n-text/no-en": "off",
"no-unused-vars": "off",
"no-shadow": "off",
"sort-imports": "off",
"@typescript-eslint/no-unused-vars": ["error", { "argsIgnorePattern": "^_" }],
"@typescript-eslint/explicit-member-accessibility": ["error", {"accessibility": "no-public"}],
Expand All @@ -30,6 +31,7 @@
"@typescript-eslint/no-misused-new": "error",
"@typescript-eslint/no-namespace": "error",
"@typescript-eslint/no-non-null-assertion": "off",
"@typescript-eslint/no-shadow": "error",
"@typescript-eslint/no-unnecessary-qualifier": "error",
"@typescript-eslint/no-unnecessary-type-assertion": "error",
"@typescript-eslint/no-useless-constructor": "error",
Expand Down
13 changes: 12 additions & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,23 @@ updates:
directory: "/"
schedule:
interval: "weekly"
groups:
github-actions:
patterns:
- "*"

- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "weekly"
ignore:
- dependency-name: "@types/node"
- dependency-name: "@types/node" # Breaking change: update with next major release
- dependency-name: "@octokit/rest" # Tied to node version
groups:
npm-dependencies:
patterns:
- "*"

- package-ecosystem: "gradle"
directory: ".github/workflow-samples/gradle-plugin"
registries:
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionSha256Sum=e111cb9948407e26351227dabce49822fb88c37ee72f1d1582a69c68af2e702f
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
distributionSha256Sum=591855b517fc635b9e04de1d05d5e76ada3f89f5fc76f87978d1b245b4f69225
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
8 changes: 6 additions & 2 deletions .github/workflow-samples/gradle-plugin/gradlew
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@ done
# This is normally unused
# shellcheck disable=SC2034
APP_BASE_NAME=${0##*/}
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD=maximum
Expand Down Expand Up @@ -130,10 +131,13 @@ location of your Java installation."
fi
else
JAVACMD=java
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
if ! command -v java >/dev/null 2>&1
then
die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
fi

# Increase the maximum file descriptors if we can.
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionSha256Sum=e111cb9948407e26351227dabce49822fb88c37ee72f1d1582a69c68af2e702f
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
distributionSha256Sum=591855b517fc635b9e04de1d05d5e76ada3f89f5fc76f87978d1b245b4f69225
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
8 changes: 6 additions & 2 deletions .github/workflow-samples/groovy-dsl/gradlew
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@ done
# This is normally unused
# shellcheck disable=SC2034
APP_BASE_NAME=${0##*/}
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD=maximum
Expand Down Expand Up @@ -130,10 +131,13 @@ location of your Java installation."
fi
else
JAVACMD=java
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
if ! command -v java >/dev/null 2>&1
then
die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
fi

# Increase the maximum file descriptors if we can.
Expand Down
4 changes: 2 additions & 2 deletions .github/workflow-samples/groovy-dsl/settings.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id "com.gradle.enterprise" version "3.13.3"
id "com.gradle.common-custom-user-data-gradle-plugin" version "1.10"
id "com.gradle.enterprise" version "3.14.1"
id "com.gradle.common-custom-user-data-gradle-plugin" version "1.11.1"
}

gradleEnterprise {
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionSha256Sum=e111cb9948407e26351227dabce49822fb88c37ee72f1d1582a69c68af2e702f
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
distributionSha256Sum=591855b517fc635b9e04de1d05d5e76ada3f89f5fc76f87978d1b245b4f69225
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
8 changes: 6 additions & 2 deletions .github/workflow-samples/java-toolchain/gradlew
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@ done
# This is normally unused
# shellcheck disable=SC2034
APP_BASE_NAME=${0##*/}
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD=maximum
Expand Down Expand Up @@ -130,10 +131,13 @@ location of your Java installation."
fi
else
JAVACMD=java
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
if ! command -v java >/dev/null 2>&1
then
die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
fi

# Increase the maximum file descriptors if we can.
Expand Down
2 changes: 1 addition & 1 deletion .github/workflow-samples/java-toolchain/settings.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
id("org.gradle.toolchains.foojay-resolver-convention") version("0.4.0")
id("org.gradle.toolchains.foojay-resolver-convention") version("0.7.0")
}

rootProject.name = 'basic'
4 changes: 2 additions & 2 deletions .github/workflow-samples/kotlin-dsl/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ repositories {

dependencies {
api("org.apache.commons:commons-math3:3.6.1")
implementation("com.google.guava:guava:31.1-jre")
implementation("com.google.guava:guava:32.1.2-jre")

testImplementation("org.junit.jupiter:junit-jupiter:5.9.3")
testImplementation("org.junit.jupiter:junit-jupiter:5.10.0")
}

tasks.test {
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionSha256Sum=e111cb9948407e26351227dabce49822fb88c37ee72f1d1582a69c68af2e702f
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
distributionSha256Sum=591855b517fc635b9e04de1d05d5e76ada3f89f5fc76f87978d1b245b4f69225
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
8 changes: 6 additions & 2 deletions .github/workflow-samples/kotlin-dsl/gradlew
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@ done
# This is normally unused
# shellcheck disable=SC2034
APP_BASE_NAME=${0##*/}
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD=maximum
Expand Down Expand Up @@ -130,10 +131,13 @@ location of your Java installation."
fi
else
JAVACMD=java
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
if ! command -v java >/dev/null 2>&1
then
die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
fi

# Increase the maximum file descriptors if we can.
Expand Down
4 changes: 2 additions & 2 deletions .github/workflow-samples/kotlin-dsl/settings.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id("com.gradle.enterprise") version "3.13.3"
id("com.gradle.common-custom-user-data-gradle-plugin") version "1.10"
id("com.gradle.enterprise") version "3.14.1"
id("com.gradle.common-custom-user-data-gradle-plugin") version "1.11.1"
}

gradleEnterprise {
Expand Down
1 change: 1 addition & 0 deletions .github/workflow-samples/no-ge/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
// Required to keep dependabot happy
1 change: 1 addition & 0 deletions .github/workflow-samples/no-ge/settings.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
rootProject.name = 'no-ge'
2 changes: 1 addition & 1 deletion .github/workflow-samples/no-wrapper-gradle-5/build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
id "com.gradle.build-scan" version "3.13.3"
id "com.gradle.build-scan" version "3.14.1"
}

gradleEnterprise {
Expand Down
2 changes: 1 addition & 1 deletion .github/workflow-samples/no-wrapper/settings.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
id "com.gradle.enterprise" version "3.13.3"
id "com.gradle.enterprise" version "3.14.1"
}

gradleEnterprise {
Expand Down
17 changes: 17 additions & 0 deletions .github/workflows/ci-full-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ jobs:
with:
cache-key-prefix: ${{github.run_number}}-

dependency-graph:
uses: ./.github/workflows/integ-test-dependency-graph.yml
with:
cache-key-prefix: ${{github.run_number}}-

execution-with-caching:
uses: ./.github/workflows/integ-test-execution-with-caching.yml
with:
Expand All @@ -39,6 +44,13 @@ jobs:
with:
cache-key-prefix: ${{github.run_number}}-

gradle-enterprise-injection:
uses: ./.github/workflows/integ-test-inject-gradle-enterprise.yml
with:
cache-key-prefix: ${{github.run_number}}-
secrets:
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }}

provision-gradle-versions:
uses: ./.github/workflows/integ-test-provision-gradle-versions.yml
with:
Expand Down Expand Up @@ -78,3 +90,8 @@ jobs:
uses: ./.github/workflows/integ-test-sample-gradle-plugin.yml
with:
cache-key-prefix: ${{github.run_number}}-

toolchain-detection:
uses: ./.github/workflows/integ-test-detect-java-toolchains.yml
with:
cache-key-prefix: ${{github.run_number}}-
2 changes: 1 addition & 1 deletion .github/workflows/ci-init-script-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
distribution: temurin
java-version: 8
- name: Setup Gradle
uses: gradle/gradle-build-action@v2.4.2 # Use a released version to avoid breakages
uses: gradle/gradle-build-action@v2.7.1 # Use a released version to avoid breakages
- name: Run integration tests
working-directory: test/init-scripts
run: ./gradlew check
25 changes: 24 additions & 1 deletion .github/workflows/ci-quick-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
- name: Configure Gradle as default for unit test
uses: ./
with:
gradle-version: 8.1.1
gradle-version: 8.3
- name: Run tests
run: |
npm install
Expand Down Expand Up @@ -50,6 +50,13 @@ jobs:
runner-os: '["ubuntu-latest"]'
download-dist: true

dependency-graph:
needs: build-distribution
uses: ./.github/workflows/integ-test-dependency-graph.yml
with:
runner-os: '["ubuntu-latest"]'
download-dist: true

execution-with-caching:
needs: build-distribution
uses: ./.github/workflows/integ-test-execution-with-caching.yml
Expand All @@ -64,6 +71,15 @@ jobs:
runner-os: '["ubuntu-latest"]'
download-dist: true

gradle-enterprise-injection:
needs: build-distribution
uses: ./.github/workflows/integ-test-inject-gradle-enterprise.yml
with:
runner-os: '["ubuntu-latest"]'
download-dist: true
secrets:
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }}

provision-gradle-versions:
needs: build-distribution
uses: ./.github/workflows/integ-test-provision-gradle-versions.yml
Expand Down Expand Up @@ -117,3 +133,10 @@ jobs:
with:
runner-os: '["ubuntu-latest"]'
download-dist: true

toolchain-detection:
needs: build-distribution
uses: ./.github/workflows/integ-test-detect-java-toolchains.yml
with:
runner-os: '["ubuntu-latest"]'
download-dist: true
28 changes: 25 additions & 3 deletions .github/workflows/demo-job-summary.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Demo Job Summary for Gradle builds
name: Demo Job Summary, for Gradle builds

on:
workflow_dispatch:
Expand All @@ -23,10 +23,10 @@ jobs:
- name: Build kotlin-dsl project
working-directory: .github/workflow-samples/kotlin-dsl
run: ./gradlew assemble
- name: Build kotlin-dsl project without build scan
- name: Build kotlin-dsl project without Build Scan®
working-directory: .github/workflow-samples/kotlin-dsl
run: ./gradlew assemble check --no-scan
- name: Build kotlin-dsl project with build scan publish failure
- name: Build kotlin-dsl project with Build Scan® publish failure
working-directory: .github/workflow-samples/kotlin-dsl
run: ./gradlew check -Dgradle.enterprise.url=https://not.valid.server
- name: Build groovy-dsl project
Expand All @@ -41,3 +41,25 @@ jobs:
working-directory: .github/workflow-samples/groovy-dsl
continue-on-error: true
run: ./gradlew not-a-real-task

pre-existing-gradle-home:
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v3
- name: Build distribution
shell: bash
run: |
npm install
npm run build
- name: Pre-create Gradle User Home
shell: bash
run: |
mkdir ~/.gradle
mkdir ~/.gradle/caches
touch ~/.gradle/caches/dummy.txt
- name: Setup Gradle
uses: ./
- name: Run build
working-directory: .github/workflow-samples/groovy-dsl
run: ./gradlew assemble
4 changes: 2 additions & 2 deletions .github/workflows/demo-pr-build-scan-comment.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Demo adding build scan comment to PR
name: Demo adding Build Scan® comment to PR
on:
pull_request:
types: [assigned, review_requested]
Expand All @@ -14,7 +14,7 @@ jobs:
id: gradle
working-directory: .github/workflow-samples/kotlin-dsl
run: ./gradlew build --scan
- name: "Add build scan URL as PR comment"
- name: "Add Build Scan URL as PR comment"
uses: actions/github-script@v6
with:
github-token: ${{secrets.GITHUB_TOKEN}}
Expand Down
Loading

0 comments on commit 6158ed4

Please sign in to comment.