Skip to content

Commit

Permalink
Add tool configs
Browse files Browse the repository at this point in the history
  • Loading branch information
the-csaba committed Sep 4, 2020
1 parent 60d7cac commit 97afdc4
Show file tree
Hide file tree
Showing 6 changed files with 69 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# OM4 default settings
# v0.9
# EditorConfig is awesome: https://editorconfig.org

root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
indent_style = space
indent_size = 2

[*.md]
trim_trailing_whitespace = false

[*.{css,json,php,xml}]
indent_size = 4

[*.php]
indent_style = tab
7 changes: 7 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.editorconfig export-ignore
.gitattributes export-ignore
.github export-ignore
.gitignore export-ignore
.wordpress-org export-ignore
composer.json export-ignore
phpstan.neon export-ignore
19 changes: 19 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Deploy to WordPress.org
on:
release:
types: [published]
jobs:
tag:
name: New release
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: WordPress Plugin Deploy
id: deploy
uses: 10up/action-wordpress-plugin-deploy@stable
with:
generate-zip: false
env:
SVN_USERNAME: ${{ secrets.SVN_USERNAME }}
SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }}
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/composer.lock
/vendor
13 changes: 13 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"require-dev": {
"php-stubs/woocommerce-stubs": "^4.4.1",
"phpstan/phpstan-deprecation-rules": "^0.12.5",
"phpstan/phpstan": "^0.12.42",
"szepeviktor/phpstan-wordpress": "^0.6.2",
"wp-cli/wp-cli-bundle": "^2.4"
},
"scripts": {
"makepot": "vendor/bin/wp i18n make-pot . languages/cpt-editor.pot",
"phpstan": "vendor/bin/phpstan analyse inc cpt-editor.php"
}
}
6 changes: 6 additions & 0 deletions phpstan.neon
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
includes:
- vendor/szepeviktor/phpstan-wordpress/extension.neon
parameters:
fileExtensions:
- php
level: 5

0 comments on commit 97afdc4

Please sign in to comment.