about summary refs log tree commit diff
path: root/machines/base.nix
diff options
context:
space:
mode:
authorPatryk Niedźwiedziński <pniedzwiedzinski19@gmail.com>2020-12-11 12:11:45 +0100
committerPatryk Niedźwiedziński <pniedzwiedzinski19@gmail.com>2020-12-11 12:11:45 +0100
commit527c96af4ed48111cfa19161fb2680b6866c2594 (patch)
tree54fc683de97bb5a768598413cebae83553e4f7c1 /machines/base.nix
parentbb668c1bdfb2937e2ca987426aac6cfe1b544fc9 (diff)
downloaddots-527c96af4ed48111cfa19161fb2680b6866c2594.tar.gz
dots-527c96af4ed48111cfa19161fb2680b6866c2594.zip
Add machines folder
Diffstat (limited to 'machines/base.nix')
-rwxr-xr-xmachines/base.nix49
1 files changed, 49 insertions, 0 deletions
diff --git a/machines/base.nix b/machines/base.nix
new file mode 100755
index 0000000..5976448
--- /dev/null
+++ b/machines/base.nix
@@ -0,0 +1,49 @@
+## Base setup, absolute minimum
+
+{ pkgs, ... }:
+{
+
+  imports = [
+    ../modules/nur.nix
+    ../users/pn.nix
+  ];
+
+  environment.systemPackages = with pkgs; [
+    wget vim curl htop file
+    stdenv git zip unzip
+    dnsutils ripgrep jq
+  ];
+
+  console.font = "${pkgs.terminus_font}/share/consolefonts/ter-v22n";
+
+  ## === Vim configuration ===
+  programs.vim.defaultEditor = true;
+  environment.etc."vim/vimrc".text = ''
+    set undodir=$XDG_DATA_HOME/vim/undo
+    set directory=$XDG_DATA_HOME/vim/swap
+    set backupdir=$XDG_DATA_HOME/vim/backup
+    set viewdir=$XDG_DATA_HOME/vim/view
+    set viminfo+='1000,n$XDG_DATA_HOME/vim/viminfo
+    set runtimepath=$XDG_CONFIG_HOME/vim,$VIMRUNTIME,$XDG_CONFIG_HOME/vim/after
+  '';
+
+  ## === ZSH configuration ===
+
+  ## Make zsh the default shell
+  users.defaultUserShell = "/run/current-system/sw/bin/zsh";
+
+  ## Cleanup home
+  environment.etc."zshenv.local".text = ''
+    export ZDOTDIR=$HOME/.config/zsh
+  '';
+
+  programs.zsh = {
+    enable = true;
+    enableCompletion = true;
+    autosuggestions.enable = true;
+    histFile = "$XDG_DATA_HOME/zsh/history";
+
+    syntaxHighlighting.enable = true;
+  };
+
+}