Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding linting jobs in github action #96

Merged
merged 4 commits into from Jan 18, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
56 changes: 56 additions & 0 deletions .github/workflows/linting.yaml
@@ -0,0 +1,56 @@
---
name: Linting jobs

# yamllint disable-line rule:truthy
on:
- push
- pull_request

jobs:
validate-composer:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v1
- name: Validate composer.json and composer.lock
uses: "docker://composer"
with:
args: "composer validate --no-check-lock"

lint-json:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v1
- name: Lint php
uses: "docker://pipelinecomponents/jsonlint:latest"
with:
args: "find . -not -path './.git/*' -name '*.json' -type f -exec jsonlint --quiet {} ;"

yamllint:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v1
- name: Check yaml for issues
uses: pipeline-components/yamllint@master

php-codesniffer:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v1
- name: Check php composer for security issues
uses: pipeline-components/php-codesniffer@master

lint-remark:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v1
- name: Check markdown
uses: pipeline-components/remark-lint@master

php-compitibility:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v1
- name: Check php compatibility
uses: pipeline-components/php-codesniffer@master
with:
options: "-s -p --colors --extensions=php --standard=PHPCompatibility --runtime-set testVersion 5.3-7.4"
6 changes: 6 additions & 0 deletions .yamllint
@@ -0,0 +1,6 @@
---
extends: default
rules:
line-length:
level: warning
max: 120