mirror of
https://github.com/zdharma-continuum/zinit.git
synced 2026-09-10 07:36:38 -04:00
Disabled following checks: - MD024/no-duplicate-heading - MD059/descriptive-link-text - MD060/table-column-style Signed-off-by: Vladislav Doster <mvdoster@gmail.com>
79 lines
1.8 KiB
YAML
79 lines
1.8 KiB
YAML
name: Lint
|
|
|
|
on:
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
push:
|
|
branches:
|
|
- main
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
mdlint:
|
|
name: Markdown Lint
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
- uses: xt0rted/markdownlint-problem-matcher@v3
|
|
|
|
- run: npm install -g markdownlint-cli
|
|
# disabled checks:
|
|
# MD013/line-length
|
|
# MD024/no-duplicate-heading
|
|
# MD033/no-inline-html
|
|
# MD034/no-bare-urls
|
|
# MD036/no-emphasis-as-heading
|
|
# MD041/first-line-heading/first-line-h1
|
|
# MD059/descriptive-link-text
|
|
# MD060/table-column-style
|
|
- run: |
|
|
markdownlint --version
|
|
|
|
# List files to lint
|
|
ls *.md **/*.md
|
|
|
|
markdownlint \
|
|
--disable MD013 MD024 MD029 MD033 MD034 MD036 MD041 MD059 MD060 \
|
|
--ignore '**/CHANGELOG.md' \
|
|
-- *.md **/*.md
|
|
|
|
zshlint:
|
|
name: ZSH Lint
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
task: [zsh-noexec, zsh-zcompile]
|
|
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- uses: actions/setup-python@v6
|
|
|
|
- name: install dependencies
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install --yes zsh
|
|
|
|
- name: "run lint (${{ matrix.task }})"
|
|
run: |
|
|
case "${{ matrix.task }}" in
|
|
zsh-noexec)
|
|
find . -name '*.zsh' -type f -print0 \
|
|
| xargs -0 -n1 -P4 zsh -n
|
|
;;
|
|
zsh-zcompile)
|
|
find . -name '*.zsh' -type f \
|
|
-exec zsh -fc "zcompile {}" \;
|
|
;;
|
|
*)
|
|
echo "ERROR: unknown task ${{ matrix.task }}" >&2
|
|
exit 1
|
|
;;
|
|
esac
|