-
-
Notifications
You must be signed in to change notification settings - Fork 209
31 lines (31 loc) · 833 Bytes
/
lintsql.yml
File metadata and controls
31 lines (31 loc) · 833 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
###########################
## Lint All SQL code
###########################
#
name: Lint SQL
on:
workflow_dispatch:
pull_request:
paths:
src/requirements.txt
jobs:
lint:
name: Lint SQL
runs-on: ubuntu-20.04
steps:
- name: Checkout Code
uses: actions/checkout@v4
with:
# Full git history is needed to get a proper list of changed files within `super-linter`
fetch-depth: 0
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Lint SQL code
if: |
github.event_name == 'workflow_dispatch' ||
startsWith(github.event.pull_request.title,'Bump sqlfluff') == true
run: |
pip install -r src/requirements.txt
sqlfluff lint sql -p 4