-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 7e76d42
Showing
17 changed files
with
16,990 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
.git | ||
.github | ||
node_modules/ | ||
vendor/ | ||
.distignore | ||
.eslintrc.js | ||
.gitignore | ||
composer.json | ||
composer.lock | ||
package-lock.json | ||
package.json | ||
phpcs.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
module.exports = { | ||
extends: [ 'plugin:@wordpress/eslint-plugin/recommended' ], | ||
env: { | ||
browser: true, | ||
}, | ||
ignorePatterns: [ | ||
'.*.js', | ||
'*.config.js', | ||
'**/build/*.js', | ||
], | ||
rules: { | ||
'no-console': [ 'warn', { allow: [ 'error' ] } ], | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
name: Add new issues to Happy Prime project | ||
|
||
on: | ||
issues: | ||
types: | ||
- opened | ||
|
||
jobs: | ||
add-to-project: | ||
name: Add issue to project | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/add-to-project@main | ||
with: | ||
project-url: https://github.com/orgs/happyprime/projects/5 | ||
github-token: ${{ secrets.AMIABOT_BOT_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
name: PHP_CodeSniffer | ||
|
||
on: pull_request | ||
|
||
jobs: | ||
phpcs: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Setup PHP | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: '8.0' | ||
coverage: none | ||
tools: composer, cs2pr | ||
|
||
- name: Cache Composer | ||
id: cache-composer | ||
run: | | ||
echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT | ||
- uses: actions/cache@v3 | ||
with: | ||
path: ${{ steps.cache-composer.outputs.dir }} | ||
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-composer- | ||
- name: Install dependencies | ||
run: | | ||
composer install --no-progress | ||
- name: Detect coding standard violations | ||
run: vendor/bin/phpcs -q --report=checkstyle . | cs2pr --notices-as-warnings |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
/build/ | ||
/node_modules | ||
/vendor/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Toggle Block | ||
|
||
Add a toggle in the WordPress block editor to show and hide another block. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
{ | ||
"name": "happyprime/toggle-block", | ||
"description": "Add a toggle to show and hide another block.", | ||
"version": "0.1.0", | ||
"type": "wordpress-plugin", | ||
"license": "GPLv2-or-later", | ||
"config": { | ||
"allow-plugins": { | ||
"dealerdirect/phpcodesniffer-composer-installer": true, | ||
"composer/installers": true | ||
} | ||
}, | ||
"require-dev": { | ||
"squizlabs/php_codesniffer": "*", | ||
"dealerdirect/phpcodesniffer-composer-installer": "*", | ||
"phpcompatibility/phpcompatibility-wp": "*", | ||
"sirbrillig/phpcs-variable-analysis": "*", | ||
"wp-coding-standards/wpcs": "*" | ||
}, | ||
"scripts": { | ||
"phpcs": "vendor/bin/phpcs", | ||
"phpcbf": "vendor/bin/phpcbf" | ||
} | ||
} |
Oops, something went wrong.