188 lines
4 KiB
Nix
188 lines
4 KiB
Nix
{ config, pkgs, inputs, lib, ... }:
|
|
|
|
{
|
|
home.username = "till";
|
|
home.homeDirectory = "/home/till";
|
|
home.stateVersion = "22.11";
|
|
|
|
nixpkgs = {
|
|
config = {
|
|
allowUnfree = true;
|
|
allowUnfreePredicate = (_: true);
|
|
};
|
|
};
|
|
|
|
programs.home-manager.enable = true;
|
|
|
|
home.packages = with pkgs; [
|
|
exa
|
|
firefox
|
|
fzf
|
|
jq
|
|
khal
|
|
khard
|
|
neomutt
|
|
nodejs
|
|
qutebrowser
|
|
rstudio
|
|
ruby
|
|
silver-searcher
|
|
tmux
|
|
tree
|
|
vdirsyncer
|
|
];
|
|
|
|
modules = [
|
|
./R.nix
|
|
];
|
|
|
|
programs.neovim = {
|
|
enable = true;
|
|
defaultEditor = true;
|
|
plugins = with pkgs.vimPlugins; [
|
|
# todo: pandoc, completion, lsp
|
|
{
|
|
plugin = fzf-vim;
|
|
config = ''
|
|
let maplocalleader="\\"
|
|
let mapleader=" "
|
|
nnoremap <leader><tab> :Buffers<return>
|
|
imap <c-x><c-f> <Plug>(fzf-complete-path)
|
|
nnoremap <leader>o :Files<return>
|
|
nnoremap <leader>O :Files ~/
|
|
nnoremap <leader>r :Read<cr>
|
|
nnoremap <leader>a :Ag<cr>
|
|
nnoremap <leader>b :Buffers<cr>
|
|
nnoremap <leader>. :Files ~/.config/<return>
|
|
command! -nargs=? -complete=dir Read call fzf#run(
|
|
\fzf#wrap({'sink': 'read', 'dir': <q-args>})
|
|
\)
|
|
'';
|
|
}
|
|
|
|
{
|
|
plugin = goyo;
|
|
config = ''
|
|
nnoremap yog :Goyo<return>
|
|
nnoremap [og :Goyo 80<return>
|
|
nnoremap ]og :Goyo!<return>
|
|
'';
|
|
}
|
|
|
|
{
|
|
plugin = limelight-vim;
|
|
config = ''
|
|
set termguicolors
|
|
let g:limelight_conceal_ctermfg = 'darkgray'
|
|
nnoremap yof :Limelight!!<return>
|
|
nnoremap [of :Limelight<return>
|
|
nnoremap ]of :Limelight!<return>
|
|
'';
|
|
}
|
|
|
|
{
|
|
plugin = nvim-colorizer-lua;
|
|
config = "lua require 'colorizer'.setup()";
|
|
}
|
|
|
|
{
|
|
plugin = papercolor-theme;
|
|
config = ''
|
|
set background=light
|
|
colorscheme PaperColor
|
|
'';
|
|
}
|
|
|
|
typescript-vim
|
|
|
|
{
|
|
plugin = ultisnips;
|
|
config = "nnoremap <leader>se :UltiSnipsEdit!<return>";
|
|
}
|
|
|
|
vim-commentary
|
|
{
|
|
plugin = vim-easy-align;
|
|
config = ''
|
|
xmap ga <Plug>(EasyAlign)
|
|
nmap ga <Plug>(EasyAlign)
|
|
'';
|
|
}
|
|
vim-fish
|
|
vim-nix
|
|
vim-repeat
|
|
{
|
|
plugin = vim-slime;
|
|
config = ''
|
|
let g:slime_target = "tmux"
|
|
let g:slime_default_config = {"socket_name": get(split($TMUX, ","), 0), "target_pane": ":.1"}
|
|
let g:slime_no_mappings = 1
|
|
let g:slime_dont_ask_default = 1
|
|
xmap s <plug>SlimeRegionSend
|
|
nmap s <plug>SlimeMotionSend
|
|
nmap ss <plug>SlimeLineSend
|
|
nnoremap s: :SlimeSend1
|
|
" let g:slime_target = "neovim"
|
|
" autocmd TermOpen * let g:slime_default_config = {"jobid": &channel}
|
|
'';
|
|
}
|
|
vim-snippets
|
|
vim-speeddating
|
|
vim-surround
|
|
vim-unimpaired
|
|
];
|
|
extraConfig = ''
|
|
let mapleader=" "
|
|
let maplocalleader="\\"
|
|
|
|
set colorcolumn=+1
|
|
set expandtab
|
|
set ignorecase
|
|
set iskeyword+=ä,Ä,ö,Ö,ü,Ü,ß
|
|
set linebreak
|
|
set list listchars=tab:»\ ,trail:·,nbsp:~
|
|
set number
|
|
set relativenumber
|
|
set scrolloff=7
|
|
set shell=/bin/sh
|
|
set shiftwidth=2
|
|
set shortmess=FfmnxoTIc
|
|
set signcolumn=no
|
|
set smartcase
|
|
set softtabstop=2
|
|
set spelllang=en_us,de_20
|
|
set splitbelow
|
|
set splitright
|
|
set tabstop=2
|
|
set updatetime=300
|
|
|
|
let g:netrw_liststyle = 3
|
|
let g:netrw_fastbrowse = 0
|
|
'';
|
|
};
|
|
|
|
home.shellAliases = {
|
|
ls = "exa";
|
|
tree = "exa --tree";
|
|
v = "nvim";
|
|
};
|
|
|
|
programs.fish = {
|
|
enable = true;
|
|
};
|
|
|
|
programs.git = {
|
|
enable = true;
|
|
userName = "Till";
|
|
userEmail = "till@ktiu.net";
|
|
lfs = {
|
|
enable = true;
|
|
};
|
|
extraConfig = {
|
|
init = {
|
|
defaultBranch = "main";
|
|
};
|
|
};
|
|
};
|
|
}
|
|
|