Skip to content

Commit

Permalink
Merge branch 'master' into rnmobile/refactor-notices-copy-paste
Browse files Browse the repository at this point in the history
# Conflicts:
#	packages/block-editor/src/components/inserter/menu.native.js
  • Loading branch information
Gerardo Pacheco committed Dec 29, 2020
2 parents d163761 + b084ecd commit 0bc39c9
Show file tree
Hide file tree
Showing 1,125 changed files with 32,789 additions and 31,934 deletions.
1 change: 0 additions & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ node_modules
packages/block-serialization-spec-parser/parser.js
packages/e2e-tests/plugins
packages/react-native-editor/bundle
playground/dist
vendor
wordpress
!.*.js
4 changes: 0 additions & 4 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,6 @@ module.exports = {
'Avoid truthy checks on length property rendering, as zero length is rendered verbatim.',
},
],
// Temporarily converted to warning until all errors are resolved.
// See https://github.com/WordPress/gutenberg/pull/22771 for the eslint-plugin-jsdoc update.
'jsdoc/check-param-names': 'warn',
'jsdoc/require-param': 'warn',
},
overrides: [
{
Expand Down
8 changes: 4 additions & 4 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -101,16 +101,16 @@
/packages/plugins @gziolo @adamsilverstein

# Rich Text
/packages/format-library @ellatrix @etoledom @cameronvoell @guarani
/packages/rich-text @ellatrix @etoledom @cameronvoell @guarani
/packages/block-editor/src/components/rich-text @ellatrix @etoledom @cameronvoell @guarani
/packages/format-library @ellatrix @cameronvoell @guarani
/packages/rich-text @ellatrix @cameronvoell @guarani
/packages/block-editor/src/components/rich-text @ellatrix @cameronvoell @guarani

# Project Management
/.github @mapk @karmatosed
/packages/project-management-automation

# wp-env
/packages/env @epiqueras @noahtallen
/packages/env @noahtallen

# PHP
/lib @timothybjacobs @spacedmonkey
Expand Down
12 changes: 12 additions & 0 deletions .github/SUPPORT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@

# Gutenberg Project Support

Welcome to Gutenberg, a WordPress project. We hope you join us in creating the future platform for publishing; all are welcome here.

* Please see the [Contributing Guidelines](https://github.com/WordPress/gutenberg/blob/master/CONTRIBUTING.md) for additional information on how to contribute.

* As with all WordPress projects, we want to ensure a welcoming environment for everyone. With that in mind, all contributors are expected to follow our [Code of Conduct](https://github.com/WordPress/gutenberg/blob/master/CODE_OF_CONDUCT.md).

* Join us on Slack for real-time communication, it is where maintainers coordinate around the project. To get started using Slack, see: https://make.wordpress.org/chat/

* For general WordPress support with the core editor, see the [WordPress.org support forums](https://wordpress.org/support/) — it is highly active and well maintained.
2 changes: 2 additions & 0 deletions .github/workflows/build-plugin-zip.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ on:
- '**.md'
push:
branches: [master]
tags:
- 'v*'
paths-ignore:
- '**.md'

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/bundle-size.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
with:
fetch-depth: 1

- uses: preactjs/compressed-size-action@v1
- uses: preactjs/compressed-size-action@v2
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
pattern: "{build/**/*.js,build/**/*.css}"
153 changes: 7 additions & 146 deletions .github/workflows/end2end-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,106 +10,16 @@ on:
- '**.md'

jobs:
admin-1:
name: Admin - 1
admin:
name: Admin - ${{ matrix.part }}

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Cache node modules
uses: actions/cache@v2
env:
cache-name: cache-node-modules
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Use Node.js 14.x
uses: actions/setup-node@v1
with:
node-version: 14.x

- name: Npm install and build
run: |
npm ci
FORCE_REDUCED_MOTION=true npm run build
- name: Install WordPress
run: |
chmod -R 767 ./ # TODO: Possibly integrate in wp-env
npm run wp-env start
- name: Running the tests
run: |
$( npm bin )/wp-scripts test-e2e --config=./packages/e2e-tests/jest.config.js --listTests > ~/.jest-e2e-tests
$( npm bin )/wp-scripts test-e2e --config=./packages/e2e-tests/jest.config.js --cacheDirectory="$HOME/.jest-cache" --runTestsByPath $( awk 'NR % 4 == 0' < ~/.jest-e2e-tests )
- name: Archive debug artifacts (screenshots, HTML snapshots)
uses: actions/upload-artifact@v2
if: always()
with:
name: failures-artifacts
path: artifacts

admin-2:
name: Admin - 2

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Cache node modules
uses: actions/cache@v2
env:
cache-name: cache-node-modules
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Use Node.js 14.x
uses: actions/setup-node@v1
with:
node-version: 14.x

- name: Npm install and build
run: |
npm ci
FORCE_REDUCED_MOTION=true npm run build
- name: Install WordPress
run: |
chmod -R 767 ./ # TODO: Possibly integrate in wp-env
npm run wp-env start
- name: Running the tests
run: |
$( npm bin )/wp-scripts test-e2e --config=./packages/e2e-tests/jest.config.js --listTests > ~/.jest-e2e-tests
$( npm bin )/wp-scripts test-e2e --config=./packages/e2e-tests/jest.config.js --cacheDirectory="$HOME/.jest-cache" --runTestsByPath $( awk 'NR % 4 == 1' < ~/.jest-e2e-tests )
- name: Archive debug artifacts (screenshots, HTML snapshots)
uses: actions/upload-artifact@v2
if: always()
with:
name: failures-artifacts
path: artifacts
strategy:
fail-fast: false
matrix:
part: [1, 2, 3, 4]

admin-3:
name: Admin - 3

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
Expand Down Expand Up @@ -145,60 +55,11 @@ jobs:
- name: Running the tests
run: |
$( npm bin )/wp-scripts test-e2e --config=./packages/e2e-tests/jest.config.js --listTests > ~/.jest-e2e-tests
$( npm bin )/wp-scripts test-e2e --config=./packages/e2e-tests/jest.config.js --cacheDirectory="$HOME/.jest-cache" --runTestsByPath $( awk 'NR % 4 == 2' < ~/.jest-e2e-tests )
$( npm bin )/wp-scripts test-e2e --config=./packages/e2e-tests/jest.config.js --cacheDirectory="$HOME/.jest-cache" --runTestsByPath $( awk 'NR % 4 == ${{ matrix.part }} - 1' < ~/.jest-e2e-tests )
- name: Archive debug artifacts (screenshots, HTML snapshots)
uses: actions/upload-artifact@v2
if: always()
with:
name: failures-artifacts
path: artifacts

admin-4:
name: Admin - 4

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Cache node modules
uses: actions/cache@v2
env:
cache-name: cache-node-modules
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Use Node.js 14.x
uses: actions/setup-node@v1
with:
node-version: 14.x

- name: Npm install and build
run: |
npm ci
FORCE_REDUCED_MOTION=true npm run build
- name: Install WordPress
run: |
chmod -R 767 ./ # TODO: Possibly integrate in wp-env
npm run wp-env start
- name: Running the tests
run: |
$( npm bin )/wp-scripts test-e2e --config=./packages/e2e-tests/jest.config.js --listTests > ~/.jest-e2e-tests
$( npm bin )/wp-scripts test-e2e --config=./packages/e2e-tests/jest.config.js --cacheDirectory="$HOME/.jest-cache" --runTestsByPath $( awk 'NR % 4 == 3' < ~/.jest-e2e-tests )
- name: Archive debug artifacts (screenshots, HTML snapshots)
uses: actions/upload-artifact@v2
if: always()
with:
name: failures-artifacts
path: artifacts

2 changes: 1 addition & 1 deletion .github/workflows/storybook-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@ jobs:
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./playground/dist
publish_dir: ./storybook/build
3 changes: 3 additions & 0 deletions .github/workflows/unit-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@ jobs:
- name: Running the tests
run: npm run test-unit -- --ci --maxWorkers=2 --cacheDirectory="$HOME/.jest-cache"

- name: Running the date tests
run: npm run test-unit:date -- --ci --maxWorkers=2 --cacheDirectory="$HOME/.jest-cache"

unit-php:
name: PHP

Expand Down
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,13 @@ yarn.lock
/wordpress
/artifacts

playground/dist
.cache
*.tsbuildinfo

# Report generated from tests
# Report generated from jest-junit
test/native/junit.xml

# Local overrides
.wp-env.override.json
phpunit.xml
phpunit-watcher.yml
14 changes: 14 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Listen for Xdebug",
"type": "php",
"request": "launch",
"port": 9003,
"pathMappings": {
"/var/www/html/wp-content/plugins/gutenberg": "${workspaceRoot}/"
}
}
]
}
2 changes: 1 addition & 1 deletion .wp-env.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"plugins": [
"."
],
"themes": [ "WordPress/theme-experiments/twentytwentyone-blocks" ],
"themes": [ "WordPress/theme-experiments/tt1-blocks" ],
"env": {
"tests": {
"mappings": {
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

[![lerna](https://img.shields.io/badge/maintained%20with-lerna-cc00ff.svg)](https://lerna.js.org)

![Screenshot of the Gutenberg Editor, editing a post in WordPress](https://user-images.githubusercontent.com/1204802/73433964-2540d900-4346-11ea-94f3-5df2e9d876bc.png)
![Screenshot of the Gutenberg Editor, editing a post in WordPress](https://user-images.githubusercontent.com/1204802/100067796-fc3e8700-2e36-11eb-993b-6b80b4310b87.png)

Welcome to the development hub for the WordPress Gutenberg project!

Expand Down
7 changes: 5 additions & 2 deletions bin/build-plugin-zip.sh
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,11 @@ mv gutenberg.tmp.php gutenberg.php

build_files=$(
ls build/*/*.{js,css,asset.php} \
build/block-library/blocks/*.php build/block-library/blocks/*/block.json \
build/edit-widgets/blocks/*.php build/edit-widgets/blocks/*/block.json \
build/block-library/blocks/*.php \
build/block-library/blocks/*/block.json \
build/block-library/blocks/*/*.css \
build/edit-widgets/blocks/*.php \
build/edit-widgets/blocks/*/block.json \
)


Expand Down
9 changes: 8 additions & 1 deletion bin/packages/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,14 @@ if ( files.length ) {
bar.tick( 0 );

stream = glob.stream(
[ `${ PACKAGES_DIR }/*/src/**/*.js`, `${ PACKAGES_DIR }/*/src/*.scss` ],
[
`${ PACKAGES_DIR }/*/src/**/*.js`,
`${ PACKAGES_DIR }/*/src/*.scss`,
`${ PACKAGES_DIR }/block-library/src/**/*.js`,
`${ PACKAGES_DIR }/block-library/src/*/style.scss`,
`${ PACKAGES_DIR }/block-library/src/*/editor.scss`,
`${ PACKAGES_DIR }/block-library/src/*.scss`,
],
{
ignore: [
`**/benchmark/**`,
Expand Down
Loading

0 comments on commit 0bc39c9

Please sign in to comment.