zsh: refactored to it's own profile
This commit is contained in:
parent
dac1513abe
commit
60d670fa6b
|
@ -13,7 +13,6 @@
|
|||
|
||||
environment.systemPackages = with pkgs; [
|
||||
gnupg # GPL OpenPGP implementation
|
||||
nix-zsh-completions # ZSH completions for Nix, NixOS, and NixOps
|
||||
nixops # NixOS cloud provisioning and deployment tool
|
||||
];
|
||||
|
||||
|
|
42
hosts/paidh-uachdar.nix
Normal file
42
hosts/paidh-uachdar.nix
Normal file
|
@ -0,0 +1,42 @@
|
|||
# NixOps configuration for pàidh-uachdar
|
||||
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../hardware/raspberry_pi_3_model_B.nix
|
||||
../profiles/host_common.nix
|
||||
../profiles/openssh.nix
|
||||
../profiles/pi_common.nix
|
||||
#../profiles/xmonad.nix
|
||||
../secrets/craige.nix # Ssshhhhh!
|
||||
../secrets/root.nix # Ssshhhhh!
|
||||
../secrets/wireless.nix # Hey look! A squirrel!
|
||||
];
|
||||
|
||||
# Comment out deployment when building the SD Image.
|
||||
deployment.targetHost = "10.42.0.125";
|
||||
networking.hostName = "paidh-uachdar"; # Define your hostname.
|
||||
|
||||
# Ensure the right package architecture is used
|
||||
nixpkgs = {
|
||||
config = {
|
||||
allowUnfree = true;
|
||||
allowUnsupportedSystem = true;
|
||||
};
|
||||
localSystem = {
|
||||
system = "aarch64-linux";
|
||||
config = "aarch64-unknown-linux-gnu";
|
||||
};
|
||||
};
|
||||
|
||||
documentation = {
|
||||
nixos.enable = false; # Save some space by disabling the manual
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
gnupg # GPL OpenPGP implementation
|
||||
];
|
||||
|
||||
system.stateVersion = "20.09"; # The version of NixOS originally installed
|
||||
}
|
|
@ -7,6 +7,7 @@
|
|||
imports = [
|
||||
./chrony.nix
|
||||
./tmux.nix
|
||||
./zsh.nix
|
||||
];
|
||||
|
||||
# Common boot settings
|
||||
|
@ -99,29 +100,6 @@
|
|||
};
|
||||
};
|
||||
|
||||
# Program defaults for all hosts
|
||||
programs.zsh = {
|
||||
enable = true;
|
||||
autosuggestions = {
|
||||
enable = true;
|
||||
};
|
||||
interactiveShellInit = ''
|
||||
export TERM="xterm-256color"
|
||||
eval "$(direnv hook zsh)"
|
||||
test -r ~/.dir_colors && eval $(dircolors ~/.dir_colors)
|
||||
export GPG_TTY="$(tty)"
|
||||
export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket)
|
||||
gpgconf --launch gpg-agent
|
||||
'';
|
||||
ohMyZsh = {
|
||||
enable = true;
|
||||
plugins = [ "git" ];
|
||||
};
|
||||
promptInit = "source ${pkgs.zsh-powerlevel9k}/share/zsh-powerlevel9k/powerlevel9k.zsh-theme";
|
||||
};
|
||||
|
||||
users.defaultUserShell = pkgs.zsh; # Set the default shell for all users
|
||||
|
||||
# Users common across MIO Ops:
|
||||
users.mutableUsers = false; # Remove any users not defined in here
|
||||
|
||||
|
|
28
profiles/zsh.nix
Normal file
28
profiles/zsh.nix
Normal file
|
@ -0,0 +1,28 @@
|
|||
# Configuration common to all my servers
|
||||
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
|
||||
# Program defaults for all hosts
|
||||
programs.zsh = {
|
||||
enable = true; # Also enables & installs nix-zsh-completions
|
||||
autosuggestions.enable = true;
|
||||
interactiveShellInit = ''
|
||||
export TERM="xterm-256color"
|
||||
eval "$(direnv hook zsh)"
|
||||
test -r ~/.dir_colors && eval $(dircolors ~/.dir_colors)
|
||||
export GPG_TTY="$(tty)"
|
||||
export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket)
|
||||
gpgconf --launch gpg-agent
|
||||
'';
|
||||
ohMyZsh = {
|
||||
enable = true;
|
||||
plugins = [ "git" ];
|
||||
};
|
||||
promptInit = "source ${pkgs.zsh-powerlevel9k}/share/zsh-powerlevel9k/powerlevel9k.zsh-theme";
|
||||
};
|
||||
|
||||
users.defaultUserShell = pkgs.zsh; # Set the default shell for all users
|
||||
|
||||
}
|
Loading…
Reference in a new issue