Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
Luehrsen committed Aug 29, 2018
2 parents 2bf4e81 + 6259b23 commit 9264ec0
Show file tree
Hide file tree
Showing 2,380 changed files with 118,389 additions and 80,670 deletions.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ coverage
node_modules
test/e2e/test-plugins
vendor
packages/block-serialization-spec-parser/index.js
54 changes: 30 additions & 24 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,77 +34,83 @@ module.exports = {
rules: {
'no-restricted-syntax': [
'error',
// NOTE: We can't include the forward slash in our regex or
// we'll get a `SyntaxError` (Invalid regular expression: \ at end of pattern)
// here. That's why we use \\u002F in the regexes below.
{
selector: 'ImportDeclaration[source.value=/^@wordpress\\u002F.+\\u002F/]',
message: 'Path access on WordPress dependencies is not allowed.',
},
{
selector: 'ImportDeclaration[source.value=/^api-request$/]',
message: 'Use @wordpress/api-request as import path instead.',
selector: 'ImportDeclaration[source.value=/^api-fetch(\\u002F|$)/]',
message: 'Use @wordpress/api-fetch as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^blob$/]',
selector: 'ImportDeclaration[source.value=/^blob(\\u002F|$)/]',
message: 'Use @wordpress/blob as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^blocks$/]',
message: 'Use @wordpress/blocks as import path instead.',
selector: 'ImportDeclaration[source.value=/^block-serialization-spec-parser(\\u002F|$)/]',
message: 'Use @wordpress/block-serialization-spec-parser as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^components$/]',
selector: 'ImportDeclaration[source.value=/^blocks(\\u002F|$)/]',
message: 'Use @wordpress/blocks as import path instead.',
},{
selector: 'ImportDeclaration[source.value=/^components(\\u002F|$)/]',
message: 'Use @wordpress/components as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^data$/]',
selector: 'ImportDeclaration[source.value=/^data(\\u002F|$)/]',
message: 'Use @wordpress/data as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^date$/]',
selector: 'ImportDeclaration[source.value=/^date(\\u002F|$)/]',
message: 'Use @wordpress/date as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^deprecated$/]',
selector: 'ImportDeclaration[source.value=/^deprecated(\\u002F|$)/]',
message: 'Use @wordpress/deprecated as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^dom$/]',
selector: 'ImportDeclaration[source.value=/^dom(\\u002F|$)/]',
message: 'Use @wordpress/dom as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^editor$/]',
selector: 'ImportDeclaration[source.value=/^editor(\\u002F|$)/]',
message: 'Use @wordpress/editor as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^element$/]',
selector: 'ImportDeclaration[source.value=/^element(\\u002F|$)/]',
message: 'Use @wordpress/element as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^utils$/]',
message: 'Use @wordpress/utils as import path instead.',
selector: 'ImportDeclaration[source.value=/^keycodes(\\u002F|$)/]',
message: 'Use @wordpress/keycodes as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^nux(\\u002F|$)/]',
message: 'Use @wordpress/nux as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^edit-post$/]',
selector: 'ImportDeclaration[source.value=/^edit-post(\\u002F|$)/]',
message: 'Use @wordpress/edit-post as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^viewport$/]',
selector: 'ImportDeclaration[source.value=/^viewport(\\u002F|$)/]',
message: 'Use @wordpress/viewport as import path instead.',
},
{
selector: 'ImportDeclaration[source.value=/^plugins$/]',
selector: 'ImportDeclaration[source.value=/^plugins(\\u002F|$)/]',
message: 'Use @wordpress/plugins as import path instead.',
},
{
"selector": "ImportDeclaration[source.value=/^core-data$/]",
"message": "Use @wordpress/core-data as import path instead."
},
{
"selector": "ImportDeclaration[source.value=/^core-blocks$/]",
"message": "Use @wordpress/core-blocks as import path instead."
},
{
"selector": "ImportDeclaration[source.value=/^nux$/]",
"message": "Use @wordpress/nux as import path instead."
"selector": "ImportDeclaration[source.value=/^block-library$/]",
"message": "Use @wordpress/block-library as import path instead."
},
{
selector: 'CallExpression[callee.name="deprecated"] Property[key.name="version"][value.value=/' + majorMinorRegExp + '/]',
Expand All @@ -120,7 +126,7 @@ module.exports = {
},
{
selector: 'ImportDeclaration[source.value="lodash"] Identifier.imported[name="memoize"]',
message: 'Use memize instead of Lodash\'s memoize',
message: 'Use memize instead of Lodashs memoize',
},
{
selector: 'CallExpression[callee.object.name="page"][callee.property.name="waitFor"]',
Expand Down
45 changes: 0 additions & 45 deletions .github/ISSUE_TEMPLATE.md

This file was deleted.

2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Directories/files that may be generated by this project
build
build-module
build-style
coverage
node_modules
gutenberg.zip
Expand All @@ -13,3 +14,4 @@ languages/gutenberg.pot
phpcs.xml
yarn.lock
docker-compose.override.yml
/wordpress
17 changes: 17 additions & 0 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"extends": "stylelint-config-wordpress",
"rules": {
"at-rule-empty-line-before": null,
"at-rule-no-unknown": null,
"comment-empty-line-before": null,
"declaration-block-no-duplicate-properties": null,
"declaration-property-unit-whitelist": null,
"font-weight-notation": null,
"max-line-length": null,
"no-descending-specificity": null,
"no-duplicate-selectors": null,
"rule-empty-line-before": null,
"selector-class-pattern": null,
"value-keyword-case": null
}
}
8 changes: 7 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@ cache:
- $HOME/.npm

before_install:
- |
git diff --name-only $TRAVIS_COMMIT_RANGE | grep -qvE '(\.md$)' || {
echo "Only docs were updated, stopping build process."
exit
}
- nvm install && nvm use
- npm install npm -g

Expand All @@ -29,6 +34,7 @@ branches:
jobs:
include:
- stage: test
env: WP_VERSION=latest
script:
- npm install || exit 1
- npm run ci || exit 1
Expand Down Expand Up @@ -59,7 +65,7 @@ jobs:
- ./bin/run-wp-unit-tests.sh

- stage: test
env: WP_VERSION=latest
script:
- npm install || exit 1
- npm run build || exit 1
- ./bin/run-e2e-tests.sh || exit 1
Loading

0 comments on commit 9264ec0

Please sign in to comment.