Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
{ config, pkgs, ... }:
{
imports =
[
./hardware-configuration.nix
];
boot.loader.grub = {
enable = true;
version = 2;
device = "/dev/sda";
};
hardware.pulseaudio.enable = true;
boot.kernelModules = [ "kvm-intel" ];
i18n = {
consoleFont = "";
consoleKeyMap = "us";
defaultLocale = "en_US.UTF-8";
};
time.timeZone = "America/Montreal";
environment.systemPackages = with pkgs; [
ammonite
chromium
dmenu
git
sbt
sublime3
tig
xclip
];
fonts.fonts = with pkgs; [
powerline-fonts
];
virtualisation.libvirtd.enable = true;
services = {
kubernetes = {
roles = ["master" "node"];
};
xserver = {
videoDrivers = ["amdgpu"];
enable = true;
windowManager = {
default = "xmonad";
xmonad.enable = true;
xmonad.enableContribAndExtras = true;
};
desktopManager = {
default = "none";
xterm.enable = true;
};
displayManager = {
slim = {
autoLogin = true;
enable = true;
defaultUser = "gui";
};
sessionCommands = ''
${pkgs.xlibs.xrdb}/bin/xrdb -all ~/.Xresources
${pkgs.xlibs.xsetroot}/bin/xsetroot -cursor_name left_ptr
${pkgs.xlibs.xset}/bin/xset r rate 200 50
${pkgs.hsetroot}/bin/hsetroot -solid '#000000'
${pkgs.xlibs.xrandr}/bin/xrandr --output DisplayPort-0 --rotate left --left-of DVI-D-0
${pkgs.xlibs.xrandr}/bin/xrandr --output DVI-D-0 --rotate left
${pkgs.xlibs.xrandr}/bin/xrandr --output HDMI-A-0 --rotate left --right-of DVI-D-0
'';
};
};
};
programs.zsh = {
enable = true;
shellAliases = {
cls = "echo '\033c'";
};
ohMyZsh = {
enable = true;
theme = "agnoster";
plugins= ["git"];
};
};
environment.variables = {
EDITOR="${pkgs.sublime3}/bin/sublime3 -n -w";
SBT_OPTS="-Xms512M -Xmx2G -Xss1M -XX:+CMSClassUnloadingEnabled";
};
users.users.gui = {
isNormalUser = true;
home = "/home/gui";
description = "gui";
extraGroups = [ "wheel" "docker" "libvirtd"];
shell = "/run/current-system/sw/bin/zsh";
};
nixpkgs.config = {
allowUnfree = true;
};
security = {
sudo.wheelNeedsPassword = false;
};
system.stateVersion = "19.03";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment