[pre-commit.ci] pre-commit autoupdate #16
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
--- | |
name: Lint | |
'on': | |
pull_request: | |
push: | |
branches: | |
- master | |
jobs: | |
yamllint: | |
name: yamllint | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out the codebase. | |
uses: actions/checkout@v2 | |
- name: Set up Python 3.7. | |
uses: actions/setup-python@v2 | |
with: | |
python-version: '3.x' | |
- name: Install yamllist | |
run: pip3 install yamllint | |
- name: Run yamllint. | |
run: yamllint . | |
ansible-lint: | |
name: ansible-lint | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout the codebase. | |
uses: actions/checkout@v2 | |
- name: Set up Python 3.7. | |
uses: actions/setup-python@v2 | |
with: | |
python-version: '3.x' | |
- name: Install ansible and other packages | |
run: pip3 install ansible ansible-lint | |
- name: Run ansible-lint. | |
run: ansible-lint | |
pre-commit: | |
name: 'Pre-Commit' | |
needs: | |
- yamllint | |
- ansible-lint | |
runs-on: ubuntu-latest | |
steps: | |
- name: 'Checkout' | |
uses: actions/[email protected] | |
- name: Install ansible-lint | |
run: pip3 install ansible-lint | |
- name: 'Pre-Commit 🔎' | |
uses: pre-commit/[email protected] | |
continue-on-error: true | |
- name: 'Slack Notification' | |
uses: clouddrove/action-slack@v2 | |
with: | |
status: ${{ job.status }} | |
fields: repo,author | |
author_name: 'CloudDrove Inc.' | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_ANSIBLE }} | |
if: always() |