ci: add formatting check ci

This commit is contained in:
amrbashir
2022-05-15 14:37:47 +02:00
parent 2321d1f1f7
commit 7150b700c2
3 changed files with 26 additions and 1 deletions

20
.github/workflows/ci.yml vendored Normal file
View File

@@ -0,0 +1,20 @@
name: CI
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
format_check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: lua format check
uses: JohnnyMorganz/stylua-action@1.0.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: --color always --check lua/

5
.stylua.toml Normal file
View File

@@ -0,0 +1,5 @@
column_width = 100
line_endings = "Unix"
indent_type = "Spaces"
indent_width = 2
quote_style = "AutoPreferDouble"

View File

@@ -1,7 +1,7 @@
local M = {}
local config = {
position = "right",
width = vim.api.nvim_get_option("columns") / 3,
width = 40,
}
M.setup = function(conf)