add linters

This commit is contained in:
Alexander Anpleenko committed 2026-11-20 10:00:17 +03:00
1 parent 6f9759283a
commit b31ff485a3
5 files changed
+52 -3

No files matched your search

+13
View File
@@ -0,0 +1,13 @@
# EditorConfig is awesome: https://editorconfig.org
root = true
[*]
end_of_line = lf
charset = utf-8
insert_final_newline = true
indent_style = space
indent_size = 2
[Makefile]
indent_style = tab
+28
View File
@@ -0,0 +1,28 @@
name: Linting file
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
editorconfig:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- run: wget https://github.com/editorconfig-checker/editorconfig-checker/releases/download/v4.0.2/editorconfig-checker_4.0.2_linux_amd64.deb
- run: sudo apt install ./editorconfig-checker_4.0.2_linux_amd64.deb
- run: rm editorconfig-checker_4.0.2_linux_amd64.deb
- run: editorconfig-checker
whitespace-format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- run: wget https://github.com/DavidPal/whitespace-format-rust/releases/download/0.1.9/whitespace-format_0.1.9-1_amd64.deb
- run: sudo apt install ./whitespace-format_0.1.9-1_amd64.deb
- run: rm whitespace-format_0.1.9-1_amd64.deb
- run: make format ARGS=--check-only
+10
View File
@@ -0,0 +1,10 @@
format:
whitespace-format \
$(ARGS) \
--exclude "\.git/|\.idea/|Package\ Control.sublime-package" \
--new-line-marker=linux \
--add-new-line-marker-at-end-of-file \
--normalize-new-line-markers \
--remove-trailing-whitespace \
--remove-leading-empty-lines \
--remove-trailing-empty-lines .
@@ -1,4 +1,4 @@
<snippet>
<content><![CDATA[…]]></content>
<tabTrigger>...</tabTrigger>
</snippet>
</snippet>
@@ -17,5 +17,3 @@ describe('$1', () => {
<tabTrigger>rts</tabTrigger>
<scope>source.js</scope>
</snippet>