feat: add .editorconfig

This commit is contained in:
Felix Schröter 2020-03-12 15:41:24 +01:00 committed by Felix Schroeter
parent 387891a388
commit 55b9993e57
4 changed files with 35 additions and 13 deletions

33
home/common/editors.nix Normal file
View file

@ -0,0 +1,33 @@
{ config, pkgs, ... }:
{
imports = [
./neovim.nix
./emacs.nix
./vscode.nix
];
home.packages = with pkgs; [
fzf
ripgrep
];
home.sessionVariables = with pkgs; {
EDITOR = "nvim";
FZF_DEFAULT_COMMAND = "${ripgrep}/bin/rg --files --hidden";
};
home.file.".editorconfig".text = ''
[*]
charset = utf-8
indent_style = space
indent_size = 2
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
[*.md]
insert_final_newline = false
trim_trailing_whitespace = false
'';
}

View file

@ -53,17 +53,10 @@ in
];
home.packages = with pkgs; [
fzf
ripgrep
nodejs-12_x
# haskellPackages.ghcide
];
home.sessionVariables = {
EDITOR = "vim";
FZF_DEFAULT_COMMAND = "rg --files --hidden";
};
programs.neovim = {
enable = true;
viAlias = true;

View file

@ -8,9 +8,7 @@ with pkgs;
./common/mimeapps.nix
./common/gtk.nix
./common/gnome.nix
./common/neovim.nix
./common/emacs.nix
./common/vscode.nix
./common/editors.nix
./common/keybase.nix
./common/signal.nix
./common/chromium.nix

View file

@ -7,9 +7,7 @@ with pkgs;
./common/mimeapps.nix
./common/gtk.nix
./common/gnome.nix
./common/neovim.nix
./common/emacs.nix
./common/vscode.nix
./common/editors.nix
./common/keybase.nix
./common/signal.nix
./common/chromium.nix