Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/trunk' into adam/gravatar_quicke…
Browse files Browse the repository at this point in the history
…ditor
  • Loading branch information
AdamGrzybkowski committed Nov 14, 2024
2 parents c704bda + 835f19a commit 9d32788
Show file tree
Hide file tree
Showing 47 changed files with 342 additions and 354 deletions.
21 changes: 16 additions & 5 deletions .buildkite/beta-builds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ steps:
#################
- label: "Gradle Wrapper Validation"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
validate_gradle_wrapper
plugins: [$CI_TOOLKIT]

Expand All @@ -27,14 +28,18 @@ steps:

- label: "🕵️ Lint WordPress"
key: wplint
command: ".buildkite/commands/lint.sh wordpress"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
.buildkite/commands/lint.sh wordpress
plugins: [$CI_TOOLKIT]
artifact_paths:
- "**/build/reports/lint-results*.*"

- label: "🕵️ Lint Jetpack"
key: jplint
command: ".buildkite/commands/lint.sh jetpack"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
.buildkite/commands/lint.sh jetpack
plugins: [$CI_TOOLKIT]
artifact_paths:
- "**/build/reports/lint-results*.*"
Expand All @@ -47,7 +52,9 @@ steps:

- label: ":wordpress: :android: Beta Build"
key: wpbuild
command: ".buildkite/commands/beta-build.sh wordpress"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
.buildkite/commands/beta-build.sh wordpress
depends_on: wplint
plugins: [$CI_TOOLKIT]
notify:
Expand All @@ -59,7 +66,9 @@ steps:

- label: ":jetpack: :android: Beta Build"
key: jpbuild
command: ".buildkite/commands/beta-build.sh jetpack"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
.buildkite/commands/beta-build.sh jetpack
depends_on: jplint
plugins: [$CI_TOOLKIT]
notify:
Expand All @@ -76,5 +85,7 @@ steps:
depends_on:
- wpbuild
- jpbuild
command: ".buildkite/commands/create-github-release.sh"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
.buildkite/commands/create-github-release.sh
plugins: [$CI_TOOLKIT]
2 changes: 2 additions & 0 deletions .buildkite/commands/checkout-editorial-branch.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash -eu

echo '--- :git: Checkout Editorial Branch'

# EDITORIAL_BRANCH is passed as an environment variable from fastlane to Buildkite
#
if [[ -z "${EDITORIAL_BRANCH}" ]]; then
Expand Down
8 changes: 3 additions & 5 deletions .buildkite/commands/checkout-release-branch.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#!/bin/bash -eu

# RELEASE_VERSION is passed as an environment variable passed to Buildkite by ReleasesV2.
if [[ -z "${RELEASE_VERSION}" ]]; then
echo "RELEASE_VERSION is not set."
exit 1
fi
echo "--- :git: Checkout Release Branch"

RELEASE_VERSION="${1?Please provide a release version as an argument.}"

# Buildkite, by default, checks out a specific commit. For many release actions, we need to be
# on a release branch instead.
Expand Down
3 changes: 0 additions & 3 deletions .buildkite/commands/lint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
echo "--- :rubygems: Setting up Gems"
install_gems

echo "--- :clipboard: Copying gradle.properties"
cp gradle.properties-example gradle.properties

echo "--- :globe_with_meridians: Check Locales Declaration Consistency"
bundle exec fastlane check_declared_locales_consistency app:"$1"

Expand Down
1 change: 0 additions & 1 deletion .buildkite/commands/run-unit-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ else
exit 1
fi

cp gradle.properties-example gradle.properties
./gradlew $test_suite
TESTS_EXIT_STATUS=$?
set -e
Expand Down
3 changes: 1 addition & 2 deletions .buildkite/complete-code-freeze.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ steps:
echo '--- :robot_face: Use bot for git operations'
source use-bot-for-git
echo '--- :git: Checkout Release Branch'
.buildkite/commands/checkout-release-branch.sh
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
echo '--- :ruby: Setup Ruby Tools'
install_gems
Expand Down
5 changes: 1 addition & 4 deletions .buildkite/finalize-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,11 @@ steps:
echo '--- :robot_face: Use bot for git operations'
source use-bot-for-git
echo '--- :git: Checkout Release Branch'
.buildkite/commands/checkout-release-branch.sh
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
echo '--- :ruby: Setup Ruby Tools'
install_gems
cp gradle.properties-example gradle.properties
echo '--- :shipit: Finalize Release'
bundle exec fastlane finalize_release skip_confirm:true
agents:
Expand Down
2 changes: 0 additions & 2 deletions .buildkite/new-beta-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ steps:
echo '--- :ruby: Setup Ruby Tools'
install_gems
cp gradle.properties-example gradle.properties
echo '--- :shipit: New Beta Release'
bundle exec fastlane new_beta_release skip_confirm:true
agents:
Expand Down
3 changes: 0 additions & 3 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,13 @@ steps:

- label: "🕵️ checkstyle"
command: |
cp gradle.properties-example gradle.properties
./gradlew checkstyle
plugins: [$CI_TOOLKIT]
artifact_paths:
- "**/build/reports/checkstyle/checkstyle.*"

- label: "🕵️ detekt"
command: |
cp gradle.properties-example gradle.properties
./gradlew detekt
plugins: [$CI_TOOLKIT]
artifact_paths:
Expand All @@ -67,7 +65,6 @@ steps:

- label: "Dependency Tree Diff"
command: |
cp gradle.properties-example gradle.properties
comment_with_dependency_diff 'WordPress' 'wordpressVanillaReleaseRuntimeClasspath'
if: build.pull_request.id != null
plugins: [$CI_TOOLKIT]
Expand Down
3 changes: 1 addition & 2 deletions .buildkite/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ steps:
echo '--- :robot_face: Use bot for git operations'
source use-bot-for-git
echo '--- :git: Checkout Release Branch'
.buildkite/commands/checkout-release-branch.sh
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
echo '--- :ruby: Setup Ruby tools'
install_gems
Expand Down
21 changes: 16 additions & 5 deletions .buildkite/release-builds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ steps:
#################
- label: "Gradle Wrapper Validation"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
validate_gradle_wrapper
priority: 1
plugins: [$CI_TOOLKIT]
Expand All @@ -28,15 +29,19 @@ steps:

- label: "🕵️ Lint WordPress"
key: wplint
command: ".buildkite/commands/lint.sh wordpress"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
.buildkite/commands/lint.sh wordpress
priority: 1
plugins: [$CI_TOOLKIT]
artifact_paths:
- "**/build/reports/lint-results*.*"

- label: "🕵️ Lint Jetpack"
key: jplint
command: ".buildkite/commands/lint.sh jetpack"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
.buildkite/commands/lint.sh jetpack
priority: 1
plugins: [$CI_TOOLKIT]
artifact_paths:
Expand All @@ -50,7 +55,9 @@ steps:

- label: ":wordpress: :android: Release Build"
key: wpbuild
command: ".buildkite/commands/release-build.sh wordpress"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
.buildkite/commands/release-build.sh wordpress
priority: 1
depends_on: wplint
plugins: [$CI_TOOLKIT]
Expand All @@ -63,7 +70,9 @@ steps:

- label: ":jetpack: :android: Release Build"
key: jpbuild
command: ".buildkite/commands/release-build.sh jetpack"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
.buildkite/commands/release-build.sh jetpack
priority: 1
depends_on: jplint
plugins: [$CI_TOOLKIT]
Expand All @@ -81,6 +90,8 @@ steps:
depends_on:
- wpbuild
- jpbuild
command: ".buildkite/commands/create-github-release.sh"
command: |
.buildkite/commands/checkout-release-branch.sh "$RELEASE_VERSION"
.buildkite/commands/create-github-release.sh
priority: 1
plugins: [$CI_TOOLKIT]
1 change: 0 additions & 1 deletion .buildkite/schedules/dependency-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ steps:
- label: "dependency analysis"
command: |
echo "--- 📊 Analyzing"
cp gradle.properties-example gradle.properties
./gradlew buildHealth
plugins: [$CI_TOOLKIT]
artifact_paths:
Expand Down
1 change: 0 additions & 1 deletion .buildkite/update-release-notes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ steps:
echo '--- :robot_face: Use bot for git operations'
source use-bot-for-git
echo '--- :git: Checkout Editorial Branch'
.buildkite/commands/checkout-editorial-branch.sh
echo '--- :ruby: Setup Ruby Tools'
Expand Down
8 changes: 4 additions & 4 deletions .configure
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"project_name": "WordPress-Android",
"branch": "trunk",
"pinned_hash": "04a650613d9f0bb3fde8f0961e2494343f0df26d",
"pinned_hash": "11fa9c59619ba8d31d0bce2b7ba4412074c00d69",
"files_to_copy": [
{
"file": "android/WPAndroid/gradle.properties",
"destination": "gradle.properties",
"file": "android/WPAndroid/secrets.properties",
"destination": "~/.configure/wordpress-android/secrets/secrets.properties",
"encrypt": true
},
{
Expand Down Expand Up @@ -52,4 +52,4 @@
"file_dependencies": [

]
}
}
Binary file added .configure-files/secrets.properties.enc
Binary file not shown.
1 change: 0 additions & 1 deletion .github/workflows/submit-gradle-dependencies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,5 @@ jobs:
with:
distribution: 'temurin'
java-version: '17'
- run: cp gradle.properties-example gradle.properties
- name: Setup Gradle to generate and submit dependency graphs
uses: gradle/actions/dependency-submission@v3
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ captures/

# Gradle
.gradle/
gradle.properties
libs/fluxc/developer.properties
libs/login/developer.properties

# Generated by gradle
crashlytics.properties
Expand Down
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ If you're a developer wanting to contribute, read on.
1. Make sure you've installed [Android Studio](https://developer.android.com/studio).
1. Install npm using [Node Version Manager](https://github.com/nvm-sh/nvm)(nvm), as described in step one from the [Block Editor Quickstart guide](https://developer.wordpress.org/block-editor/getting-started/devenv/#quickstart)
1. `cd WordPress-Android` to enter the working directory.
1. `cp gradle.properties-example gradle.properties` to set up the sample app credentials file.
1. In Android Studio, open the project from the local repository. This will auto-generate `local.properties` with the SDK location.
1. Recommended: The CI uses JDK11 to build the app and run the tests. Some tests won't pass on the JDK embedded in Android Studio (JDK8). You might want to set JAVA_HOME and JDK location in Android Studio to JDK11.
1. Go to Tools → AVD Manager and create an emulated device.
Expand Down
Loading

0 comments on commit 9d32788

Please sign in to comment.