mirror of
https://github.com/ashishb/android-security-awesome.git
synced 2024-12-18 11:36:09 +00:00
Add YAML Linter to GitHub CI (#172)
This commit is contained in:
parent
6c50a49d0a
commit
3e6216bda2
52
.github/workflows/lint-yaml.yaml
vendored
Normal file
52
.github/workflows/lint-yaml.yaml
vendored
Normal file
@ -0,0 +1,52 @@
|
||||
---
|
||||
# Run this locally with act - https://github.com/nektos/act
|
||||
# act -j lintYaml
|
||||
name: Lint YAML
|
||||
|
||||
on: # yamllint disable-line rule:truthy
|
||||
push:
|
||||
branches: [master, main]
|
||||
paths:
|
||||
- '**.yml'
|
||||
- '**.yaml'
|
||||
- '.github/workflows/**.yml'
|
||||
- '.github/workflows/**.yaml'
|
||||
pull_request:
|
||||
branches: [master, main]
|
||||
paths:
|
||||
- '**.yml'
|
||||
- '**.yaml'
|
||||
- '.github/workflows/**.yml'
|
||||
- '.github/workflows/**.yaml'
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
lintYaml:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 15
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
- name: Check YAML files with linter
|
||||
uses: ibiqlik/action-yamllint@v3
|
||||
with:
|
||||
# All files under base dir
|
||||
file_or_dir: "."
|
||||
config_data: |
|
||||
extends: default
|
||||
yaml-files:
|
||||
- '*.yaml'
|
||||
- '*.yml'
|
||||
rules:
|
||||
document-start:
|
||||
level: warning
|
||||
line-length:
|
||||
level: warning
|
||||
new-line-at-end-of-file:
|
||||
level: warning
|
||||
trailing-spaces:
|
||||
level: warning
|
@ -1,4 +1,6 @@
|
||||
# android-security-awesome ![Awesome](https://cdn.rawgit.com/sindresorhus/awesome/d7305f38d29fed78fa85652e3a63e154dd8e8829/media/badge.svg) [![Lint Markdown](https://github.com/ashishb/android-security-awesome/actions/workflows/lint-markdown.yaml/badge.svg)](https://github.com/ashishb/android-security-awesome/actions/workflows/lint-markdown.yaml) [![Test](https://github.com/ashishb/android-security-awesome/actions/workflows/test.yml/badge.svg)](https://github.com/ashishb/android-security-awesome/actions/workflows/test.yml)
|
||||
# android-security-awesome ![Awesome](https://cdn.rawgit.com/sindresorhus/awesome/d7305f38d29fed78fa85652e3a63e154dd8e8829/media/badge.svg)
|
||||
|
||||
[![Test](https://github.com/ashishb/android-security-awesome/actions/workflows/test.yml/badge.svg)](https://github.com/ashishb/android-security-awesome/actions/workflows/test.yml) [![Lint Markdown](https://github.com/ashishb/android-security-awesome/actions/workflows/lint-markdown.yaml/badge.svg)](https://github.com/ashishb/android-security-awesome/actions/workflows/lint-markdown.yaml) [![Lint YAML](https://github.com/ashishb/android-security-awesome/actions/workflows/lint-yaml.yaml/badge.svg)](https://github.com/ashishb/android-security-awesome/actions/workflows/lint-yaml.yaml)
|
||||
|
||||
A collection of android security related resources.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user