summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--home.nix17
-rw-r--r--vim.nix19
-rw-r--r--vimrc6
3 files changed, 16 insertions, 26 deletions
diff --git a/home.nix b/home.nix
index f31fe54..abca0b3 100644
--- a/home.nix
+++ b/home.nix
@@ -178,11 +178,18 @@ in
];
};
- vim = import ./vim.nix {
- inherit pkgs;
- inherit (pkgs) vimUtils fetchFromGitHub;
- };
-
+ vim = {
+ enable = true;
+ plugins = [
+ "ctrlp"
+ "fugitive"
+ "editorconfig-vim"
+ "gitgutter"
+ "surround"
+ ];
+ extraConfig = builtins.readFile ./vimrc;
+ }
+
git = {
enable = true;
userName = "Ben Sima";
diff --git a/vim.nix b/vim.nix
deleted file mode 100644
index ddc0b5a..0000000
--- a/vim.nix
+++ /dev/null
@@ -1,19 +0,0 @@
-{ pkgs, vimUtils, fetchFromGitHub}:
-
-{
- enable = true;
- plugins = [
- "ctrlp"
- "fugitive"
- "editorconfig-vim"
- "gitgutter"
- "surround"
- ];
- settings = {
- ignorecase = true;
- expandtab = true;
- history = 1000;
- tabstop = 4;
- };
- extraConfig = builtins.readFile ./vimrc;
-}
diff --git a/vimrc b/vimrc
index 10884b8..e67256a 100644
--- a/vimrc
+++ b/vimrc
@@ -1,20 +1,22 @@
""" General settings
set autoindent
set backspace=indent,eol,start
-set cc=80 " 80 column lines
set complete-=i " Set the matches for insert mode completion
set encoding=utf-8 " Set encoding
+set expandtab " Use spaces instead of tabs
set formatoptions+=j " Delete comment character when joining commented lines
set hlsearch " Highlight all search results
+set ignorecase " Ignore cases when searching
set incsearch " Incremental search
set laststatus=1 " No status line
set linebreak " Break lines at word (requires Wrap lines)
set ruler " Show line & col number of cursor position
set shiftwidth=4 " Number of auto-indent spaces
set showmatch " Highlight matching brace
-set smartcase " Better searching
+set smartcase " Better searching btw cases
set smartindent " Autoindent when starting a new line
set smarttab " Tab insertion & deletion
+set tabstop=4 " One tab = 4 spaces
set textwidth=80 " Line wrap (number of cols)
set visualbell " Use visual bell (no beeping)
set wildmenu " Helpful completion menu