Skip to content

Commit

Permalink
Added pre-commits.
Browse files Browse the repository at this point in the history
  • Loading branch information
atropos112 committed Mar 24, 2024
1 parent ae72454 commit df44155
Show file tree
Hide file tree
Showing 8 changed files with 46 additions and 23 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/pre-commit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
name: Pre-commit
on:
workflow_dispatch: # allows manual triggering
pull_request:
branches: [main]
push:
branches:
- main
jobs:
pre-commit:
name: Run pre-commit hooks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pre-commit/[email protected]
with:
extra_args: --all-files
13 changes: 0 additions & 13 deletions .github/workflows/stylua.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .luarc.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@
"diagnostics.disable": [
"missing-fields"
]
}
}
17 changes: 17 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- repo: https://github.com/JohnnyMorganz/StyLua
rev: v0.20.0
hooks:
- id: stylua-github
- repo: https://github.com/jumanjihouse/pre-commit-hook-yamlfmt
rev: 0.2.1 # or other specific tag
hooks:
- id: yamlfmt
8 changes: 4 additions & 4 deletions TODO.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Needs documenting

1. Gitsigns details
1. Gitsigns details
- https://github.com/lewis6991/gitsigns.nvim?tab=readme-ov-file

2. Neotree detailed setup with keymaps
Expand All @@ -13,7 +13,7 @@
- https://invidious.atro.xyz/watch?v=SWldGqw9wkc


---
---
1. How did you "make" each language "work"
- For C# explain how https://github.com/Hoffs/omnisharp-extended-lsp.nvim was needed to allow go-def to work on non-owned code (decompiled). This really needs to be documented, the `~/.omnisharp/omnisharp.json`
- For Go explain how you use a package and all works
Expand All @@ -24,9 +24,9 @@

4. More research needed
- Into youtube videos
- Other's peoples work.
- Other's peoples work.

5. Document somewhere all my defined keymaps, `:nmap`, `:vmap`, `:imap` can help with this.
5. Document somewhere all my defined keymaps, `:nmap`, `:vmap`, `:imap` can help with this.
- Document window jumping `<C-w>` followed by arrows/hjkl.
- Document window resizing `<C-w>` followed by +/- for vertical increase/decrease and >/< for horizontal increase/decrease.

Expand Down
7 changes: 4 additions & 3 deletions atro.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
origin: [email protected]:atropos112/nvim.git
copyToRepo:
- sourcePath: "."
destinationRepo: "[email protected]:atropos112/docs"
destinationPath: "repos/nvim"
- sourcePath: .
destinationRepo: [email protected]:atropos112/docs
destinationPath: repos/nvim
2 changes: 1 addition & 1 deletion lazy-lock.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,4 +92,4 @@
"vim-wakatime": { "branch": "master", "commit": "56b4d073adaf18c04c7bb5728d41c03b2f25754d" },
"virtual-types.nvim": { "branch": "master", "commit": "d652ec0b1781bbb0e83dc588fb62d638006cf61e" },
"which-key.nvim": { "branch": "main", "commit": "4433e5ec9a507e5097571ed55c02ea9658fb268a" }
}
}
2 changes: 1 addition & 1 deletion lua/atro/plugins/fmt.lua
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ return {
just = { "just" },
md = { "mdformat" },
sh = { "shfmt" },
-- yaml = { "yamlfmt" },
yaml = { "yamlfmt" },
toml = { "taplo" },
markdown = { "prettier" },
},
Expand Down

0 comments on commit df44155

Please sign in to comment.