forked from opentibiabr/myaac
-
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.
feature: include workflows (opentibiabr#84)
- Loading branch information
1 parent
9f13dc7
commit 15be51a
Showing
203 changed files
with
59,212 additions
and
28,599 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
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
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
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 |
---|---|---|
@@ -1,16 +1,13 @@ | ||
name: PHP Linting | ||
on: | ||
pull_request: | ||
branches: [master] | ||
push: | ||
branches: [master] | ||
|
||
pull_request: | ||
types: [ opened, synchronize, reopened, ready_for_review ] | ||
jobs: | ||
phplint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: overtrue/phplint@3.4.0 | ||
with: | ||
path: . | ||
options: --exclude="system/libs/polyfill-mbstring/bootstrap80.php" | ||
phplint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@main | ||
- uses: overtrue/phplint@3.4.0 | ||
with: | ||
path: . | ||
options: --exclude="system/libs/polyfill-mbstring/bootstrap80.php" |
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,56 @@ | ||
--- | ||
name: Format Prettier | ||
on: | ||
pull_request: | ||
types: [ opened, synchronize, reopened, ready_for_review ] | ||
merge_group: | ||
push: | ||
paths: | ||
- '*/**' | ||
jobs: | ||
cancel-runs: | ||
if: github.event_name == 'pull_request' && github.ref != 'refs/heads/main' | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Cancel Previous Runs | ||
uses: styfle/cancel-workflow-action@0.12.1 | ||
with: | ||
access_token: ${{ github.token }} | ||
|
||
prettier: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Set up Git | ||
if: ${{ github.ref != 'refs/heads/main' }} | ||
run: | | ||
git config --global user.email "github-actions[bot]@users.noreply.github.com" | ||
git config --global user.name "GitHub Actions" | ||
- name: Actions checkout | ||
if: ${{ github.ref != 'refs/heads/main' }} | ||
uses: actions/checkout@v3 | ||
with: | ||
repository: ${{ github.event.pull_request.head.repo.full_name }} | ||
ref: ${{ github.event.pull_request.head.ref }} | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18 | ||
|
||
- name: Install Dependencies | ||
run: npm install prettier @prettier/plugin-php stylelint-prettier | ||
|
||
- name: Run prettier code format | ||
run: npx prettier --write **/*.{php,js} --plugin=@prettier/plugin-php --ignore-unknown && npx stylelint **/*.css --fix | ||
|
||
- name: Run add and commit | ||
if: ${{ github.ref != 'refs/heads/main' }} | ||
uses: EndBug/add-and-commit@v9 | ||
with: | ||
author_name: GitHub Actions | ||
author_email: 41898282+github-actions[bot]@users.noreply.github.com | ||
message: 'PHP code format - (prettier)' | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_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,18 @@ | ||
# Ignore system libs | ||
plugins/ | ||
system/libs/PagSeguroLibrary | ||
system/libs/phpmailer | ||
system/libs/polyfill-mbstring | ||
system/libs/pot | ||
system/libs/semver | ||
system/libs/Twig | ||
system/cache | ||
system/php_sessions | ||
node_modules | ||
|
||
# Files | ||
login.php | ||
|
||
# Styles | ||
admin/bootstrap/pace/templates/pace-theme-loading-bar.tmpl.css | ||
admin/bootstrap/pace/templates/pace-theme-mac-osx.tmpl.css |
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,17 @@ | ||
{ | ||
"overrides": [ | ||
{ | ||
"files": [ | ||
"*.php" | ||
], | ||
"options": { | ||
"parser": "php", | ||
"singleQuote": true, | ||
"semi": false, | ||
"tabWidth": 2, | ||
"printWidth": 100, | ||
"trailingComma": "none" | ||
} | ||
} | ||
] | ||
} |
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,8 @@ | ||
{ | ||
"plugins": ["stylelint-prettier"], | ||
"ignoreFiles": ["**/*.min.css"], | ||
"rules": { | ||
"prettier/prettier": true | ||
}, | ||
"extends": ["stylelint-prettier/recommended"] | ||
} |
Oops, something went wrong.