mirror of
https://github.com/cisagov/log4j-affected-db.git
synced 2024-11-13 20:37:54 +00:00
38 lines
1,005 B
YAML
38 lines
1,005 B
YAML
---
|
|
name: build
|
|
|
|
on: [
|
|
push,
|
|
pull_request
|
|
]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-python@v1
|
|
with:
|
|
python-version: 3.8
|
|
- name: Cache pip test requirements
|
|
uses: actions/cache@v1
|
|
with:
|
|
path: ~/.cache/pip
|
|
key: "${{ runner.os }}-pip-test-\
|
|
${{ hashFiles('**/requirements-test.txt') }}"
|
|
restore-keys: |
|
|
${{ runner.os }}-pip-test-
|
|
${{ runner.os }}-pip-
|
|
- name: Cache pre-commit hooks
|
|
uses: actions/cache@v1
|
|
with:
|
|
path: ~/.cache/pre-commit
|
|
key: "${{ runner.os }}-pre-commit-\
|
|
${{ hashFiles('**/.pre-commit-config.yaml') }}"
|
|
- name: Install dependencies
|
|
run: |
|
|
python -m pip install --upgrade pip
|
|
pip install --upgrade --requirement requirements-test.txt
|
|
- name: Run pre-commit on all files
|
|
run: pre-commit run --all-files
|