diff options
author | tdro <tdro@users.noreply.github.com> | 2021-10-20 03:43:42 -0400 |
---|---|---|
committer | tdro <tdro@users.noreply.github.com> | 2021-10-20 03:43:42 -0400 |
commit | 537cc93fc967e18301126f0a19184c0e78728b38 (patch) | |
tree | 52c94d55f6bf331381242f0327b6d53199812567 | |
parent | bd62f21ef5177163f99c4577187abec52dc789b7 (diff) | |
download | dotfiles-537cc93fc967e18301126f0a19184c0e78728b38.tar.gz dotfiles-537cc93fc967e18301126f0a19184c0e78728b38.tar.bz2 dotfiles-537cc93fc967e18301126f0a19184c0e78728b38.zip |
.vimrc: Bring back nim for a few scripts
-rw-r--r-- | .config/nixpkgs/config.nix | 19 | ||||
-rw-r--r-- | .vimrc | 4 |
2 files changed, 12 insertions, 11 deletions
diff --git a/.config/nixpkgs/config.nix b/.config/nixpkgs/config.nix index aad40de..3468988 100644 --- a/.config/nixpkgs/config.nix +++ b/.config/nixpkgs/config.nix @@ -24,7 +24,7 @@ in paths = [ Terminal Graphical Xorg Awesome Fonts Audio LaTeX Dictionary Android JavaScript Python PHP Lua Elixir HTML Shell Haskell - Perl Nix C Golang Rust CSS SQL YAML Ruby Themes + Perl Nix C Golang Rust CSS SQL YAML Ruby Nim Themes ]; }; @@ -397,11 +397,7 @@ in Lua = pkgs.buildEnv { name = "lua"; - paths = [ - (callPackage ./packages/luaformatter/default.nix {}) - lua5_3 - lua53Packages.luacheck - ]; + paths = [ (callPackage ./packages/luaformatter/default.nix {}) lua5_3 lua53Packages.luacheck ]; }; Elixir = pkgs.buildEnv { @@ -441,11 +437,7 @@ in Ruby = pkgs.buildEnv { name = "ruby"; - paths = [ - (callPackage ./packages/rufo/default.nix {}) - rubocop - ruby - ]; + paths = [ (callPackage ./packages/rufo/default.nix {}) rubocop ruby ]; }; C = pkgs.buildEnv { @@ -463,6 +455,11 @@ in paths = [ evcxr rustup ]; }; + Nim = pkgs.buildEnv { + name = "nim"; + paths = [ nim ]; + }; + CSS = pkgs.buildEnv { name = "css"; paths = [ @@ -308,6 +308,7 @@ augroup AutoCommands autocmd FileType html autocmd! BufWritePost <buffer> exe 'Notify(''prettier --write --parser html ' . expand('%') . ' 2>&1'')' | :e autocmd FileType python autocmd! BufWritePost <buffer> exe 'Notify(''black ' . expand('%') . ' 2>&1 && pylint ' . expand('%') . ' 2>&1'')' | :e autocmd FileType ruby autocmd! BufWritePost <buffer> exe 'Notify(''rufo ' . expand('%') . ' 2>&1 && rubocop ' . expand('%') . ' 2>&1'')' | :e + autocmd FileType nim autocmd! BufWritePost <buffer> exe 'Notify(''nimpretty ' . expand('%') . ' 2>&1 && printf "Nim OK: ' . expand('%') . '"'')' | :e autocmd FileType rust autocmd! BufWritePost <buffer> exe 'Notify(''rustfmt ' . expand('%') . ' 2>&1 && printf "rustfmt OK: ' . expand('%') . '"'')' | :e autocmd FileType json autocmd! BufWritePost <buffer> exe 'Notify(''jsonlint -i ' . expand('%') . ' 2>&1 && printf "JSON OK: ' . expand('%') . '"'')' | :e autocmd FileType elixir autocmd! BufWritePost <buffer> exe 'Notify(''mix format ' . expand('%') . ' 2>&1 && printf "Elixir Format OK: ' . expand('%') . '"'')' | :e @@ -345,6 +346,9 @@ augroup AutoCommands autocmd FileType nix set formatprg=nixfmt autocmd FileType sh set formatprg=shfmt\ - + " Set file types. + autocmd BufRead,BufNewFile *.nims set filetype=nim + " General auto commands. autocmd BufWritePost *.tex :term ++close ++rows=10 latex-compile % autocmd BufWritePost $HOME/.config/chromexup/config.ini exe 'Notify(''chromexup 2>&1'')' |