diff options
| author | seth <[email protected]> | 2024-07-13 20:12:35 -0400 |
|---|---|---|
| committer | seth <[email protected]> | 2024-07-14 13:47:39 -0400 |
| commit | 5ec30e9a2b9047713c060c90a5e7930fafc2a3d6 (patch) | |
| tree | 4c10736c3f5a69d2e214575f0ed1fc0e6d3f2f90 /lua | |
| parent | c9fb0eded5c69af78a1af12e5fdce7b347c40da3 (diff) | |
flatten plugin structure
Diffstat (limited to 'lua')
| -rw-r--r-- | lua/getchoo/efmls.lua | 58 | ||||
| -rw-r--r-- | lua/getchoo/init.lua | 25 |
2 files changed, 83 insertions, 0 deletions
diff --git a/lua/getchoo/efmls.lua b/lua/getchoo/efmls.lua new file mode 100644 index 0000000..92d61e9 --- /dev/null +++ b/lua/getchoo/efmls.lua @@ -0,0 +1,58 @@ +local alex = require("efmls-configs.linters.alex") +alex.rootMarkers = nil +local actionlint = require("efmls-configs.linters.actionlint") +local beautysh = require("efmls-configs.formatters.beautysh") +local fish_indent = require("efmls-configs.formatters.fish_indent") +local prettier = require("efmls-configs.formatters.prettier") +local prettier_eslint = require("efmls-configs.formatters.prettier_eslint") +local selene = require("efmls-configs.linters.selene") +local statix = require("efmls-configs.linters.statix") +local stylua = require("efmls-configs.formatters.stylua") + +local languages = { + all = { alex }, + + bash = { + beautysh, + }, + + css = { prettier }, + + fish = { fish_indent }, + + html = { prettier }, + + javascript = { prettier_eslint }, + + json = { prettier }, + + lua = { selene, stylua }, + + nix = { statix }, + + sass = { prettier }, + + scss = { prettier }, + + sh = { beautysh }, + + typescript = { prettier_eslint }, + + yaml = { prettier, actionlint }, + + zsh = { beautysh }, +} + +return { + filetypes = vim.tbl_keys(languages), + + settings = { + rootMarkers = { ".git/" }, + languages = languages, + }, + + init_options = { + documentFormatting = true, + documentRangeFormatting = true, + }, +} diff --git a/lua/getchoo/init.lua b/lua/getchoo/init.lua new file mode 100644 index 0000000..a919bc8 --- /dev/null +++ b/lua/getchoo/init.lua @@ -0,0 +1,25 @@ +local opt = vim.opt + +opt.shiftwidth = 2 +opt.tabstop = 2 +-- https://www.reddit.com/r/neovim/comments/14n6iiy/if_you_have_treesitter_make_sure_to_disable +-- TLDR: this breaks things with treesitter indent +opt.smartindent = false +opt.number = true +opt.wrap = true +opt.syntax = "on" +opt.termguicolors = true +opt.mouse = "a" + +local backupDir = vim.fn.stdpath("state") .. "/backup" +local b = io.open(backupDir, "r") +if b then + b:close() +else + os.execute("mkdir -p " .. backupDir) +end + +opt.backupdir = backupDir + +vim.g.mapleader = "," +vim.g.do_filetype_lua = 1 |
