Ändringar
This commit is contained in:
parent
952e9a3229
commit
2cfb13ad40
7 changed files with 91 additions and 138 deletions
BIN
.flake.nix.swp
Normal file
BIN
.flake.nix.swp
Normal file
Binary file not shown.
|
@ -13,6 +13,7 @@
|
|||
../moduler/common/dmenu.nix
|
||||
../moduler/common/kitty.nix
|
||||
../moduler/common/tmux.nix
|
||||
../moduler/common/vim.nix
|
||||
# ../moduler/common/zsh.nix
|
||||
../moduler/common/fish.nix
|
||||
# ../moduler/common/starship.nix
|
||||
|
@ -104,6 +105,7 @@
|
|||
macchina
|
||||
|
||||
#Desktop
|
||||
# vim_configurable
|
||||
aerc
|
||||
firefox
|
||||
vimb
|
||||
|
|
100
flake.lock
generated
100
flake.lock
generated
|
@ -1,23 +1,5 @@
|
|||
{
|
||||
"nodes": {
|
||||
"flake-parts": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": "nixpkgs-lib"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1715865404,
|
||||
"narHash": "sha256-/GJvTdTpuDjNn84j82cU6bXztE0MSkdnTWClUCRub78=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "8dc45382d5206bd292f9c2768b8058a8fd8311d9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"fw-pkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1716560453,
|
||||
|
@ -41,11 +23,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1715381426,
|
||||
"narHash": "sha256-wPuqrAQGdv3ISs74nJfGb+Yprm23U/rFpcHFFNWgM94=",
|
||||
"lastModified": 1716729592,
|
||||
"narHash": "sha256-Y3bOjoh2cFBqZN0Jw1zUdyr7tjygyxl2bD/QY73GZP0=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "ab5542e9dbd13d0100f8baae2bc2d68af901f4b4",
|
||||
"rev": "2c78a57c544dd19b07442350727ced097e1aa6e6",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -55,53 +37,22 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nix-gaming": {
|
||||
"inputs": {
|
||||
"flake-parts": "flake-parts",
|
||||
"nixpkgs": "nixpkgs"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1716513383,
|
||||
"narHash": "sha256-WKO8A3PvMRTXB5wNhFyTNXnYQThSazIyVqY5Yh4YIiI=",
|
||||
"owner": "fufexan",
|
||||
"repo": "nix-gaming",
|
||||
"rev": "a1b37351bf0fe01192eeb93f643749f2e0f944eb",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "fufexan",
|
||||
"repo": "nix-gaming",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1716062047,
|
||||
"narHash": "sha256-OhysviwHQz4p2HZL4g7XGMLoUbWMjkMr/ogaR3VUYNA=",
|
||||
"lastModified": 1716633019,
|
||||
"narHash": "sha256-xim1b5/HZYbWaZKyI7cn9TJCM6ewNVZnesRr00mXeS4=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "02923630b89aa1ab36ef8e422501a6f4fd4b2016",
|
||||
"rev": "9d29cd266cebf80234c98dd0b87256b6be0af44e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixpkgs-unstable",
|
||||
"ref": "nixos-23.11",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-lib": {
|
||||
"locked": {
|
||||
"lastModified": 1714640452,
|
||||
"narHash": "sha256-QBx10+k6JWz6u7VsohfSw8g8hjdBZEf8CFzXH1/1Z94=",
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/NixOS/nixpkgs/archive/50eb7ecf4cd0a5756d7275c8ba36790e5bd53e33.tar.gz"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/NixOS/nixpkgs/archive/50eb7ecf4cd0a5756d7275c8ba36790e5bd53e33.tar.gz"
|
||||
}
|
||||
},
|
||||
"nixpkgs-stable": {
|
||||
"locked": {
|
||||
"lastModified": 1716061101,
|
||||
|
@ -120,11 +71,11 @@
|
|||
},
|
||||
"nixpkgs-unstable": {
|
||||
"locked": {
|
||||
"lastModified": 1716330097,
|
||||
"narHash": "sha256-8BO3B7e3BiyIDsaKA0tY8O88rClYRTjvAp66y+VBUeU=",
|
||||
"lastModified": 1716509168,
|
||||
"narHash": "sha256-4zSIhSRRIoEBwjbPm3YiGtbd8HDWzFxJjw5DYSDy1n8=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "5710852ba686cc1fd0d3b8e22b3117d43ba374c2",
|
||||
"rev": "bfb7a882678e518398ce9a31a881538679f6f092",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -135,22 +86,6 @@
|
|||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1716361217,
|
||||
"narHash": "sha256-mzZDr00WUiUXVm1ujBVv6A0qRd8okaITyUp4ezYRgc4=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "46397778ef1f73414b03ed553a3368f0e7e33c2f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-23.11",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_3": {
|
||||
"locked": {
|
||||
"lastModified": 1716062047,
|
||||
"narHash": "sha256-OhysviwHQz4p2HZL4g7XGMLoUbWMjkMr/ogaR3VUYNA=",
|
||||
|
@ -170,29 +105,26 @@
|
|||
"inputs": {
|
||||
"fw-pkgs": "fw-pkgs",
|
||||
"home-manager": "home-manager",
|
||||
"nix-gaming": "nix-gaming",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs-unstable": "nixpkgs-unstable",
|
||||
"sops-nix": "sops-nix"
|
||||
}
|
||||
},
|
||||
"sops-nix": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs_3",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"nixpkgs-stable": "nixpkgs-stable"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1716400300,
|
||||
"narHash": "sha256-0lMkIk9h3AzOHs1dCL9RXvvN4PM8VBKb+cyGsqOKa4c=",
|
||||
"owner": "Mic92",
|
||||
"repo": "sops-nix",
|
||||
"path": "/nix/store/5cals4p1ryzfk8yb26dmk6j0rjqkyw3w-source",
|
||||
"rev": "b549832718b8946e875c016a4785d204fcfc2e53",
|
||||
"type": "github"
|
||||
"type": "path"
|
||||
},
|
||||
"original": {
|
||||
"owner": "Mic92",
|
||||
"repo": "sops-nix",
|
||||
"type": "github"
|
||||
"id": "sops-nix",
|
||||
"type": "indirect"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
22
flake.nix
22
flake.nix
|
@ -10,8 +10,6 @@
|
|||
# Home manager
|
||||
home-manager.url = "github:nix-community/home-manager/release-23.11";
|
||||
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||
nix-gaming.url = "github:fufexan/nix-gaming";
|
||||
sops-nix.url = "github:Mic92/sops-nix";
|
||||
|
||||
# TODO: Add any other flake you might need
|
||||
# hardware.url = "github:nixos/nixos-hardware";
|
||||
|
@ -71,17 +69,6 @@
|
|||
};
|
||||
modules = [./maskiner/jobb/configuration.nix];
|
||||
};
|
||||
server = nixpkgs.lib.nixosSystem {
|
||||
specialArgs = {
|
||||
inherit inputs outputs;
|
||||
myhostname = "server";
|
||||
};
|
||||
inherit system;
|
||||
modules = [
|
||||
({nixpkgs, ... }: { nixpkgs.overlays = [ overlay-unstable ]; })
|
||||
./maskiner/server/configuration.nix
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
# Standalone home-manager configuration entrypoint
|
||||
|
@ -117,15 +104,6 @@
|
|||
# > Our main home-manager configuration file <
|
||||
modules = [./config/home.nix];
|
||||
};
|
||||
"fw@server" = home-manager.lib.homeManagerConfiguration {
|
||||
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
||||
extraSpecialArgs = {
|
||||
inherit inputs outputs;
|
||||
myhostname = "server";
|
||||
};
|
||||
# > Our main home-manager configuration file <
|
||||
modules = [./config/server.nix];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
enable = true;
|
||||
font = if myhostname == "laptop" then {
|
||||
name = "FiraCode Nerd Font";
|
||||
size = 24;
|
||||
size = 20;
|
||||
} else {
|
||||
name = "FiraCode Nerd Font";
|
||||
size = 18;
|
||||
|
|
|
@ -12,8 +12,8 @@
|
|||
extraConfig = ''
|
||||
set -g @dracula-show-powerline true
|
||||
# available plugins: battery, cpu-usage, git, gpu-usage, ram-usage, tmux-ram-usage, network, network-bandwidth, network-ping, ssh-session, attached-clients, network-vpn, weather, time, mpc, spotify-tui, playerctl, kubernetes-context, synchronize-panes
|
||||
# set -g @dracula-plugins 'spotify-tui battery time'
|
||||
set -g @dracula-plugins 'battery time'
|
||||
set -g @dracula-plugins 'spotify-tui battery time'
|
||||
# set -g @dracula-plugins 'battery time'
|
||||
set -g @dracula-refresh-rate 10
|
||||
set -g @dracula-show-timezone false
|
||||
set -g @dracula-military-time true
|
||||
|
|
|
@ -1,26 +1,30 @@
|
|||
{ pkgs, lib, ... }:
|
||||
{
|
||||
environment.variables = { EDITOR = "vim"; };
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
((vim_configurable.override { }).customize{
|
||||
name = "vim";
|
||||
# Install plugins for example for syntax highlighting of nix files
|
||||
vimrcConfig.packages.myplugins = with pkgs.vimPlugins; {
|
||||
start = [
|
||||
programs.vim = {
|
||||
enable = true;
|
||||
plugins = with pkgs.vimPlugins; [
|
||||
ale
|
||||
vim-nix
|
||||
vim-lastplace
|
||||
vim-dracula
|
||||
dracula-vim
|
||||
vim-sensible
|
||||
vim-commentary
|
||||
vim-fugitive
|
||||
fzf-vim
|
||||
YouCompleteMe
|
||||
asyncomplete-vim
|
||||
asyncomplete-lsp-vim
|
||||
ultisnips
|
||||
vim-snippets
|
||||
vim-lsp
|
||||
vim-lsp-snippets
|
||||
vim-lsp-ultisnips
|
||||
vim-lsp-settings
|
||||
asyncomplete-lsp-vim
|
||||
];
|
||||
opt = [];
|
||||
};
|
||||
vimrcConfig.customRC = ''
|
||||
nnoremap <Space>e :Files<Cr>
|
||||
settings = { ignorecase = true; };
|
||||
extraConfig = ''
|
||||
nnoremap <Space>f :Files<Cr>
|
||||
nnoremap <Space>w :w<Cr>
|
||||
nnoremap <Space>q :q<Cr>
|
||||
nnoremap <Tab> :bnext<Cr>
|
||||
|
@ -35,7 +39,44 @@
|
|||
set shiftwidth=4
|
||||
set tabstop=4
|
||||
set termguicolors
|
||||
colorscheme dracula
|
||||
|
||||
function! s:on_lsp_buffer_enabled() abort
|
||||
setlocal omnifunc=lsp#complete
|
||||
setlocal signcolumn=yes
|
||||
if exists('+tagfunc') | setlocal tagfunc=lsp#tagfunc | endif
|
||||
nmap <buffer> gd <plug>(lsp-definition)
|
||||
nmap <buffer> gs <plug>(lsp-document-symbol-search)
|
||||
nmap <buffer> gS <plug>(lsp-workspace-symbol-search)
|
||||
nmap <buffer> gr <plug>(lsp-references)
|
||||
nmap <buffer> gi <plug>(lsp-implementation)
|
||||
nmap <buffer> gt <plug>(lsp-type-definition)
|
||||
nmap <buffer> <leader>rn <plug>(lsp-rename)
|
||||
nmap <buffer> [g <plug>(lsp-previous-diagnostic)
|
||||
nmap <buffer> ]g <plug>(lsp-next-diagnostic)
|
||||
nmap <buffer> K <plug>(lsp-hover)
|
||||
nnoremap <buffer> <expr><c-f> lsp#scroll(+4)
|
||||
nnoremap <buffer> <expr><c-d> lsp#scroll(-4)
|
||||
|
||||
let g:lsp_format_sync_timeout = 1000
|
||||
autocmd! BufWritePre *.rs,*.go call execute('LspDocumentFormatSync')
|
||||
|
||||
" refer to doc to add more commands
|
||||
endfunction
|
||||
|
||||
augroup lsp_install
|
||||
au!
|
||||
" call s:on_lsp_buffer_enabled only for languages that has the server registered.
|
||||
autocmd User lsp_buffer_enabled call s:on_lsp_buffer_enabled()
|
||||
augroup END
|
||||
if executable('nil')
|
||||
autocmd User lsp_setup call lsp#register_server({
|
||||
\ 'name': 'nil',
|
||||
\ 'cmd': {server_info->['nil']},
|
||||
\ 'whitelist': ['nix'],
|
||||
\ })
|
||||
endif
|
||||
|
||||
'';
|
||||
}
|
||||
)];
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue