nvim: Cleanup configuration
This commit is contained in:
parent
d29da3cfd8
commit
a71c541ea2
2 changed files with 214 additions and 209 deletions
|
@ -35,7 +35,7 @@
|
||||||
;; Configure Linters per FT
|
;; Configure Linters per FT
|
||||||
(set lint.linters_by_ft {:dockerfile [:hadolint]
|
(set lint.linters_by_ft {:dockerfile [:hadolint]
|
||||||
:elixir [:credo]
|
:elixir [:credo]
|
||||||
;:fennel [:fennel]
|
:fennel [:fennel]
|
||||||
:fish [:fish]
|
:fish [:fish]
|
||||||
:java [:checkstyle]
|
:java [:checkstyle]
|
||||||
:nix [:deadnix :nix :statix]
|
:nix [:deadnix :nix :statix]
|
||||||
|
|
|
@ -1,10 +1,5 @@
|
||||||
{ pkgs, config, lib, ... }:
|
{ pkgs, config, lib, ... }:
|
||||||
|
|
||||||
let
|
|
||||||
customPlugins = import ./plugins.nix { inherit pkgs; };
|
|
||||||
|
|
||||||
nvim-spell-directory = "${config.xdg.configHome}/nvim/spell";
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
programs.neovim = {
|
programs.neovim = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -16,7 +11,7 @@ in
|
||||||
withRuby = false;
|
withRuby = false;
|
||||||
withPython3 = false;
|
withPython3 = false;
|
||||||
|
|
||||||
extraLuaPackages = _: [ pkgs.luarocks-jsregexp ];
|
extraLuaPackages = luaPkgs: with luaPkgs; [ jsregexp readline ];
|
||||||
|
|
||||||
extraPackages = with pkgs; [
|
extraPackages = with pkgs; [
|
||||||
git
|
git
|
||||||
|
@ -42,12 +37,14 @@ in
|
||||||
checkstyle
|
checkstyle
|
||||||
deadnix
|
deadnix
|
||||||
hadolint
|
hadolint
|
||||||
lua51Packages.fennel
|
luajitPackages.fennel
|
||||||
fnlfmt
|
fnlfmt
|
||||||
shellcheck
|
shellcheck
|
||||||
shfmt
|
shfmt
|
||||||
statix
|
statix
|
||||||
yamllint
|
yamllint
|
||||||
|
] ++ lib.optionals pkgs.stdenv.isDarwin [
|
||||||
|
xcbuild
|
||||||
];
|
];
|
||||||
|
|
||||||
extraLuaConfig =
|
extraLuaConfig =
|
||||||
|
@ -97,7 +94,11 @@ in
|
||||||
require('configuration.init')
|
require('configuration.init')
|
||||||
'';
|
'';
|
||||||
|
|
||||||
plugins = (with customPlugins; [
|
plugins =
|
||||||
|
let
|
||||||
|
customPlugins = import ./plugins.nix { inherit pkgs; };
|
||||||
|
in
|
||||||
|
(with customPlugins; [
|
||||||
# Fixes
|
# Fixes
|
||||||
impatient-nvim
|
impatient-nvim
|
||||||
|
|
||||||
|
@ -332,7 +333,7 @@ in
|
||||||
xdg.configFile."nvim" = {
|
xdg.configFile."nvim" = {
|
||||||
source = pkgs.runCommand "nvim-fennel-files"
|
source = pkgs.runCommand "nvim-fennel-files"
|
||||||
{
|
{
|
||||||
nativeBuildInputs = with pkgs; [ lua51Packages.fennel stylua ];
|
nativeBuildInputs = with pkgs; [ luajitPackages.fennel stylua ];
|
||||||
} ''
|
} ''
|
||||||
mkdir -p $out/lua/configuration
|
mkdir -p $out/lua/configuration
|
||||||
mkdir -p $out/lua/nifoc/utils
|
mkdir -p $out/lua/nifoc/utils
|
||||||
|
@ -409,7 +410,11 @@ in
|
||||||
echo 'Done'
|
echo 'Done'
|
||||||
'';
|
'';
|
||||||
|
|
||||||
file = {
|
file =
|
||||||
|
let
|
||||||
|
nvim-spell-directory = "${config.xdg.configHome}/nvim/spell";
|
||||||
|
in
|
||||||
|
{
|
||||||
"${nvim-spell-directory}/de.utf-8.spl".source = builtins.fetchurl {
|
"${nvim-spell-directory}/de.utf-8.spl".source = builtins.fetchurl {
|
||||||
url = "http://ftp.vim.org/pub/vim/runtime/spell/de.utf-8.spl";
|
url = "http://ftp.vim.org/pub/vim/runtime/spell/de.utf-8.spl";
|
||||||
sha256 = "73c7107ea339856cdbe921deb92a45939c4de6eb9c07261da1b9dd19f683a3d1";
|
sha256 = "73c7107ea339856cdbe921deb92a45939c4de6eb9c07261da1b9dd19f683a3d1";
|
||||||
|
|
Loading…
Reference in a new issue