-
Notifications
You must be signed in to change notification settings - Fork 56
42 lines (36 loc) · 1.12 KB
/
test-n-lint.yml
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
32
33
34
35
36
37
38
39
40
41
42
name: test-n-lint
on: [push, pull_request, workflow_dispatch]
jobs:
lint-docker:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install hadolint
run: |
url_api="https://api.github.com/repos/hadolint/hadolint/releases/latest"
version=$(curl --silent $url_api | jq -r .tag_name)
url_rlz="https://github.com/hadolint/hadolint/releases/download/${version}"
file='hadolint-Linux-x86_64'
wget "${url_rlz}/$file"
chmod u+x "$file"
ln -s "$file" hadolint
- name: Check Docker files
run: |
for file in $(find . -name Dockerfile); do
./hadolint --ignore DL3008 --ignore DL3018 --ignore DL3059 $file
done
lint-markdown:
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install mardownlint
run: |
sudo apt-get install ruby-full
sudo gem install mdl
- name: Check md files
run: |
for file in $(find . -name "*.md"); do
mdl $file
done