Skip to content

Commit

Permalink
Merge pull request #12314 from wordpress-mobile/merge/15.2-code-freez…
Browse files Browse the repository at this point in the history
…e-to-master

Merge 15.2 code freeze to master
  • Loading branch information
loremattei authored Jun 30, 2020
2 parents 17098fd + c8d3b89 commit 03f395e
Show file tree
Hide file tree
Showing 194 changed files with 4,293 additions and 1,068 deletions.
133 changes: 93 additions & 40 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,44 +5,47 @@ orbs:
bundle-install: toshimaru/[email protected]
slack: circleci/[email protected]

parameters:
translation_review_build:
type: boolean
default: false
translation_review_lang_id:
type: string
default: all-lang

commands:
copy-gradle-properties:
steps:
- run:
name: Setup gradle.properties
command: cp gradle.properties-example gradle.properties
yarn-install:
npm-install:
steps:
- restore_cache:
name: Restore Yarn Cache
name: Restore NPM Cache
keys:
- yarn-i18n-v4-cache-v{{ .Environment.CACHE_TRIGGER_VERSION }}-job-{{ .Environment.CIRCLE_JOB }}-{{ checksum "libs/gutenberg-mobile/yarn.lock" }}
- npm-i18n-v1-cache-v{{ .Environment.CACHE_TRIGGER_VERSION }}-job-{{ .Environment.CIRCLE_JOB }}-{{ checksum "libs/gutenberg-mobile/package-lock.json" }}
- run:
name: Yarn Install
name: NPM Install
working_directory: libs/gutenberg-mobile
command: yarn install --frozen-lockfile --prefer-offline --network-concurrency 1
command: npm ci --prefer-offline
- save_cache:
name: Save Yarn Cache
key: yarn-i18n-v4-cache-v{{ .Environment.CACHE_TRIGGER_VERSION }}-job-{{ .Environment.CIRCLE_JOB }}-{{ checksum "libs/gutenberg-mobile/yarn.lock" }}
name: Save NPM Cache
key: npm-i18n-v1-cache-v{{ .Environment.CACHE_TRIGGER_VERSION }}-job-{{ .Environment.CIRCLE_JOB }}-{{ checksum "libs/gutenberg-mobile/package-lock.json" }}
paths:
- libs/gutenberg-mobile/node_modules
- ~/.npm
- libs/gutenberg-mobile/i18n-cache/data
checkout-submodules:
steps:
- run:
name: Checkout submodules
command: git submodule update --init --recursive
checkout-gutenberg-mobile-submodule-only:
steps:
- run:
name: Checkout gutenberg-mobile submodule (no recursive)
command: git submodule update --init
yarn-bundle-android:
command: git submodule update --init --recursive --depth 1
npm-bundle-android:
steps:
- run:
name: Yarn bundle Android
name: Npm bundle Android
working_directory: libs/gutenberg-mobile
command: yarn bundle:android
command: npm run bundle:android
save-gutenberg-bundle-cache:
steps:
- run:
Expand All @@ -54,7 +57,7 @@ commands:
name: Cache JS Bundle
key: android-js-bundle-{{ checksum "gutenberg_submodule_hash" }}
paths:
- libs/gutenberg-mobile/react-native-gutenberg-bridge/android/build/assets/index.android.bundle
- libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/build/assets/index.android.bundle
restore-gutenberg-bundle-cache:
steps:
- run:
Expand All @@ -77,37 +80,37 @@ jobs:
- run:
name: Abort If JS Bundle Exists
command: |
if [ -f "libs/gutenberg-mobile/react-native-gutenberg-bridge/android/build/assets/index.android.bundle" ]; then
if [ -f "libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/build/assets/index.android.bundle" ]; then
echo "Gutenberg-Mobile bundle already in cache, no need to create a new one."
circleci-agent step halt
else
echo "Gutenberg-Mobile bundle not found in cache. Proceeding to generate new bundle"
fi
- checkout-submodules
- yarn-install
- yarn-bundle-android
- npm-install
- npm-bundle-android
- run:
name: Ensure assets folder exists
command: mkdir -p libs/gutenberg-mobile/react-native-gutenberg-bridge/android/build/assets
command: mkdir -p libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/build/assets
- run:
name: Move bundle to assets folder
command: mv libs/gutenberg-mobile/bundle/android/App.js libs/gutenberg-mobile/react-native-gutenberg-bridge/android/build/assets/index.android.bundle
command: mv libs/gutenberg-mobile/bundle/android/App.js libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/build/assets/index.android.bundle
- save-gutenberg-bundle-cache
test:
executor:
name: android/default
api-version: "28"
steps:
- git/shallow-checkout
- checkout-gutenberg-mobile-submodule-only
- checkout-submodules
- android/restore-gradle-cache
- copy-gradle-properties
- restore-gutenberg-bundle-cache
- run:
name: Ensure assets folder exists
command: mkdir -p libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
command: mkdir -p libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/src/main/assets
- attach_workspace:
at: libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
at: libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/src/main/assets
- run:
name: Test WordPress
environment:
Expand All @@ -126,15 +129,15 @@ jobs:
api-version: "28"
steps:
- git/shallow-checkout
- checkout-gutenberg-mobile-submodule-only
- checkout-submodules
- android/restore-gradle-cache
- copy-gradle-properties
- restore-gutenberg-bundle-cache
- run:
name: Ensure assets folder exists
command: mkdir -p libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
command: mkdir -p libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/src/main/assets
- attach_workspace:
at: libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
at: libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/src/main/assets
- run:
name: Checkstyle
environment:
Expand Down Expand Up @@ -169,7 +172,7 @@ jobs:
api-version: "28"
steps:
- git/shallow-checkout
- checkout-gutenberg-mobile-submodule-only
- checkout-submodules
- bundle-install/bundle-install:
cache_key_prefix: installable-build
- run:
Expand All @@ -179,9 +182,9 @@ jobs:
- restore-gutenberg-bundle-cache
- run:
name: Ensure assets folder exists
command: mkdir -p libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
command: mkdir -p libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/src/main/assets
- attach_workspace:
at: libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
at: libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/src/main/assets
- run:
name: Build APK
environment:
Expand Down Expand Up @@ -218,15 +221,15 @@ jobs:
api-version: "28"
steps:
- git/shallow-checkout
- checkout-gutenberg-mobile-submodule-only
- checkout-submodules
- android/restore-gradle-cache
- copy-gradle-properties
- restore-gutenberg-bundle-cache
- run:
name: Ensure assets folder exists
command: mkdir -p libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
command: mkdir -p libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/src/main/assets
- attach_workspace:
at: libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
at: libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/src/main/assets
- run:
name: Build
environment:
Expand Down Expand Up @@ -261,15 +264,15 @@ jobs:
api-version: "28"
steps:
- git/shallow-checkout
- checkout-gutenberg-mobile-submodule-only
- checkout-submodules
- android/restore-gradle-cache
- copy-gradle-properties
- restore-gutenberg-bundle-cache
- run:
name: Ensure assets folder exists
command: mkdir -p libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
command: mkdir -p libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/src/main/assets
- attach_workspace:
at: libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
at: libs/gutenberg-mobile/gutenberg/packages/react-native-bridge/android/src/main/assets
- run:
name: Build
environment:
Expand All @@ -293,7 +296,7 @@ jobs:
- image: circleci/ruby:2.6.4
steps:
- git/shallow-checkout
- checkout-gutenberg-mobile-submodule-only
- checkout-submodules
- run:
name: Install bundler
command: gem install bundler --version 2.0.2
Expand All @@ -302,9 +305,54 @@ jobs:
- run:
name: Validate login strings
command: bundle exec fastlane validate_login_strings pr_url:$CIRCLE_PULL_REQUEST
translation-review-build:
executor:
name: android/default
api-version: "28"
environment:
APP_VERSION_PREFIX: << pipeline.parameters.translation_review_lang_id >>
steps:
- git/shallow-checkout
- checkout-submodules
- bundle-install/bundle-install:
cache_key_prefix: installable-build
- run:
name: Copy Secrets
command: bundle exec fastlane run configure_apply
- android/restore-gradle-cache
- restore-gutenberg-bundle-cache
- run:
name: Ensure assets folder exists
command: mkdir -p libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
- attach_workspace:
at: libs/gutenberg-mobile/react-native-gutenberg-bridge/android/src/main/assets
- run:
name: Build APK
environment:
SUPPRESS_GUTENBERG_MOBILE_JS_BUNDLE_BUILD: 1
command: |
TODAY_DATE=$(date +'%Y%m%d')
VERSION_NAME="${APP_VERSION_PREFIX}-build-${TODAY_DATE}-${CIRCLE_BUILD_NUM}"
echo "export VERSION_NAME=$VERSION_NAME" >> $BASH_ENV
bundle exec fastlane build_for_translation_review custom_version:"$VERSION_NAME"
- android/save-gradle-cache
- run:
name: Prepare APK
command: |
mkdir -p Artifacts
mv WordPress/build/outputs/apk/jalapeno/debug/org.wordpress.android-jalapeno-debug.apk "Artifacts/WordPress-${VERSION_NAME}.apk"
- run:
name: Upload APK
command: |
curl --http1.1 https://${APPET_TOKEN}@api.appetize.io/v1/apps/${APPET_APPID} -F "file=@Artifacts/WordPress-${VERSION_NAME}.apk" -F "platform=android"
- store_artifacts:
path: Artifacts
destination: Artifacts

workflows:
wordpress_android:
unless: << pipeline.parameters.translation_review_build >>
jobs:
- gutenberg-bundle-build
- strings-check
Expand All @@ -329,14 +377,15 @@ workflows:
- Connected Tests:
requires:
- gutenberg-bundle-build
post-to-slack: true
post-to-slack: false
# Always run connected tests on develop and release branches
filters:
branches:
only:
- develop
- /^release.*/
Optional Tests:
unless: << pipeline.parameters.translation_review_build >>
#Optionally run connected tests on PRs
jobs:
- Hold:
Expand All @@ -349,3 +398,7 @@ workflows:
- /pull\/[0-9]+/
- Connected Tests:
requires: [Hold]
Translation Review Build:
when: << pipeline.parameters.translation_review_build >>
jobs:
- translation-review-build
8 changes: 4 additions & 4 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
GIT
remote: https://github.com/wordpress-mobile/release-toolkit
revision: 6c1fa45f3beb216f4f5d03346f2981f1024b799e
tag: 0.9.6
revision: b515c0b26b78bfffc3cbe5ceb3b51bb6eb979ab4
tag: 0.9.8
specs:
fastlane-plugin-wpmreleasetoolkit (0.9.6)
fastlane-plugin-wpmreleasetoolkit (0.9.8)
activesupport (~> 4)
chroma (= 0.2.0)
diffy (~> 3.3)
Expand Down Expand Up @@ -169,7 +169,7 @@ GEM
optimist (3.0.1)
options (2.3.2)
os (1.1.0)
parallel (1.19.1)
parallel (1.19.2)
plist (3.5.0)
progress_bar (1.3.1)
highline (>= 1.6, < 3)
Expand Down
10 changes: 9 additions & 1 deletion RELEASE-NOTES.txt
Original file line number Diff line number Diff line change
@@ -1,11 +1,19 @@
15.3
-----

15.2
-----
* [**] Fixes tons of rendering issues in Reader post detail by changing the technical solution (shared CSS file).
* [**] Block editor: Display content metrics information (blocks, words, characters count).
* [**] Block Editor: Adds editor support for theme defined colors and theme defined gradients on cover and button blocks.
* [**] Block Editor: Add support allowing Cover Block video uploads to complete after the editor has closed
* [*] Block Editor: Fix handling of upload completion while re-opening the editor
* [*] Fix crash when WordPress api response has an empty body

15.1
-----
* Fixes issue on Notifications tab when two screens were drawn on top of each other
* [**] Fix video thumbnails, settings and preview in Media section for private sites
* [**] Block Editor: Adds editor support for theme defined colors and theme defined gradients on cover and button blocks.
* [*] Support for breaking out of captions/citation authors by pressing enter on the following blocks: image, video, gallery, quote, and pullquote.

15.0
Expand Down
61 changes: 0 additions & 61 deletions WordPress/FEATURE_ANNOUNCEMENTS.json-example

This file was deleted.

Loading

0 comments on commit 03f395e

Please sign in to comment.