Skip to content

Commit

Permalink
CI: Use shared buildkite pipeline vars file
Browse files Browse the repository at this point in the history
For more info see: https://github.com/wordpress-mobile/
WordPress-Login-Flow-Android/pull/151#issuecomment-2225299197
  • Loading branch information
ParaskP7 committed Jul 12, 2024
1 parent 87777a1 commit 04d046a
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 15 deletions.
13 changes: 4 additions & 9 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,21 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/buildkite/pipeline-schema/main/schema.json
---

common_params:
# Common plugin settings to use with the `plugins` key.
- &common_plugins
- automattic/a8c-ci-toolkit#3.4.2

agents:
queue: "android"

steps:
- label: "Gradle Wrapper Validation"
command: |
validate_gradle_wrapper
plugins: *common_plugins
plugins: [$CI_TOOLKIT]

# Wait for Gradle Wrapper to be validated before running any other jobs
- wait

- label: "Lint & Checkstyle"
key: "lint_and_checkstyle"
plugins: *common_plugins
plugins: [$CI_TOOLKIT]
command: |
cp gradle.properties-example gradle.properties
./gradlew lintRelease checkstyle
Expand All @@ -29,7 +24,7 @@ steps:
- "**/build/reports/checkstyle/checkstyle.*"
- label: "Test"
key: "test"
plugins: *common_plugins
plugins: [$CI_TOOLKIT]
command: |
cp gradle.properties-example gradle.properties
./gradlew testRelease
Expand All @@ -38,7 +33,7 @@ steps:
depends_on:
- "lint_and_checkstyle"
- "test"
plugins: *common_plugins
plugins: [$CI_TOOLKIT]
command: |
cp gradle.properties-example gradle.properties
./gradlew \
Expand Down
7 changes: 1 addition & 6 deletions .buildkite/schedules/dependency-analysis.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,6 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/buildkite/pipeline-schema/main/schema.json
---

common_params:
# Common plugin settings to use with the `plugins` key.
- &common_plugins
- automattic/a8c-ci-toolkit#3.4.2

agents:
queue: "android"

Expand All @@ -15,7 +10,7 @@ steps:
echo "--- 📊 Analyzing"
cp gradle.properties-example gradle.properties
./gradlew buildHealth
plugins: *common_plugins
plugins: [$CI_TOOLKIT]
artifact_paths:
- "build/reports/dependency-analysis/build-health-report.*"
notify:
Expand Down
6 changes: 6 additions & 0 deletions .buildkite/shared-pipeline-vars
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/sh

# This file is `source`'d before calling `buildkite-agent pipeline upload`, and can be used
# to set up some variables that will be interpolated in the `.yml` pipeline before uploading it.

export CI_TOOLKIT="automattic/a8c-ci-toolkit#3.4.2"

0 comments on commit 04d046a

Please sign in to comment.