Compare commits

...

6 commits

Author SHA1 Message Date
7984da51d3 firefox with video acceleration 2020-08-29 16:53:14 +02:00
b1376304b7 new software 2020-08-29 16:52:59 +02:00
f4984704f9 direnv 2020-08-29 16:51:58 +02:00
527948d845 background and keyboard config 2020-08-29 16:51:24 +02:00
f434cfa3e0 adapt for new hardware 2020-08-29 16:51:01 +02:00
3a335817cb use latest linux kernel (for new amd cpus) 2020-08-29 16:49:58 +02:00
7 changed files with 62 additions and 45 deletions

View file

@ -7,9 +7,6 @@
{ {
imports = imports =
[ [
<nixos-hardware/lenovo/thinkpad/x220>
<home-manager/nixos>
# Include the results of the hardware scan. # Include the results of the hardware scan.
./hardware-configuration.nix ./hardware-configuration.nix
@ -23,13 +20,14 @@
boot.loader.systemd-boot.enable = true; boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true; boot.loader.efi.canTouchEfiVariables = true;
boot.kernelPackages = pkgs.linuxPackages_latest;
networking.hostName = "raven"; networking.hostName = "raven";
networking.hostId = "e3a397c5"; networking.hostId = "e3a397c5";
networking.useDHCP = false; networking.useDHCP = false;
networking.interfaces.enp0s25.useDHCP = true; networking.interfaces.wlo1.useDHCP = true;
networking.interfaces.wlp3s0.useDHCP = true; networking.resolvconf.useLocalResolver = true;
i18n.defaultLocale = "en_US.UTF-8"; i18n.defaultLocale = "en_US.UTF-8";
time.timeZone = "Europe/Berlin"; time.timeZone = "Europe/Berlin";

View file

@ -7,8 +7,10 @@ set $right l
set $term alacritty set $term alacritty
set $menu bemenu-run set $menu bemenu-run
output * bg /home/stefan/Sync/wall/nasa-yZygONrUBe8-unsplash.jpg fill input "1:1:AT_Translated_Set_2_keyboard" xkb_layout de
output eDP-1 scale 1.3
output * bg /home/stefan/Downloads/bg.jpg fill
#output * bg /home/stefan/Sync/wall/nasa-yZygONrUBe8-unsplash.jpg fill
output DP-1 res 5120x1440 output DP-1 res 5120x1440
# user keybinds # user keybinds

View file

@ -54,7 +54,7 @@ hide_missing = true
[[block]] [[block]]
block = "net" block = "net"
device = "wlp3s0" device = "wlo1"
ip = true ip = true
ssid = true ssid = true
speed_up = false speed_up = false
@ -63,11 +63,8 @@ hide_inactive = true
hide_missing = true hide_missing = true
[[block]] [[block]]
block = "temperature" block = "custom"
collapsed = false command = '''echo " $(cat /sys/class/thermal/thermal_zone0/temp | head -c 2) °C"'''
interval = 10
chip = "coretemp-isa-0000"
format = "{min}..{max}°"
[[block]] [[block]]
block = "disk_space" block = "disk_space"
@ -99,9 +96,9 @@ block = "backlight"
[[block]] [[block]]
block = "battery" block = "battery"
device = "BAT0" device = "BAT1"
interval = 10 interval = 10
format = "{percentage}%" format = "{percentage}% {time}"
[[block]] [[block]]
block = "time" block = "time"

View file

@ -4,21 +4,17 @@
{ config, lib, pkgs, ... }: { config, lib, pkgs, ... }:
{ {
imports = imports = [
[ <nixpkgs/nixos/modules/installer/scan/not-detected.nix> <nixpkgs/nixos/modules/installer/scan/not-detected.nix>
<nixos-hardware/common/cpu/amd>
<nixos-hardware/common/pc/ssd>
<nixos-hardware/common/pc/laptop>
]; ];
boot.initrd.availableKernelModules = [ "ehci_pci" "ahci" "usb_storage" "sd_mod" "sdhci_pci" ]; boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
boot.initrd.kernelModules = [ ]; boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ]; boot.extraModulePackages = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.initrd.luks.devices = {
swap = {
device = "/dev/disk/by-uuid/fe87a31c-7d0b-4073-98fc-fa825de77181";
allowDiscards = true;
};
};
fileSystems."/" = fileSystems."/" =
{ device = "tank/root/nixos"; { device = "tank/root/nixos";
@ -31,14 +27,11 @@
}; };
fileSystems."/boot" = fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/0C2D-2799"; { device = "/dev/disk/by-uuid/B048-FBC8";
fsType = "vfat"; fsType = "vfat";
}; };
swapDevices = swapDevices = [ ];
[ { device = "/dev/disk/by-uuid/2ac33f61-0db5-4f94-8148-93f2166b2f29"; }
];
nix.maxJobs = lib.mkDefault 4; nix.maxJobs = lib.mkDefault 8;
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
} }

View file

@ -6,7 +6,7 @@ in {
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
bash bash
bat bat
emacs-nox direnv
fd fd
fzf fzf
git git
@ -64,6 +64,7 @@ precmd_user_func = "title"
. "$(fzf-share)/key-bindings.bash" . "$(fzf-share)/key-bindings.bash"
. "$(fzf-share)/completion.bash" . "$(fzf-share)/completion.bash"
. <(z --init bash) . <(z --init bash)
. <(direnv hook bash)
''; '';
shellAliases = { shellAliases = {
@ -87,4 +88,5 @@ precmd_user_func = "title"
''; '';
services.resolved.enable = true; services.resolved.enable = true;
services.lorri.enable = true;
} }

View file

@ -4,8 +4,9 @@
{ config, lib, pkgs, ... }: { config, lib, pkgs, ... }:
let let
unstable = import <nixos-unstable> {}; unstable = import <nixos-unstable> { config.allowUnfree = true; };
in { in {
programs.sway = { programs.sway = {
enable = true; enable = true;
extraPackages = with pkgs; [ extraPackages = with pkgs; [
@ -17,6 +18,7 @@ in {
slurp slurp
swayidle swayidle
swaylock swaylock
xwayland
]; ];
}; };
@ -41,14 +43,33 @@ in {
]; ];
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
# firefox also needs:
#
# gfx.webrenderer.enabled = true
# widget.wayland-dmabuf-vaapi.enabled = true
#
# check in `about:support` that
# * Composing -> Webrenderer
unstable.firefox-bin
libva
libva-utils
mesa
librsvg
unstable.mypaint
unstable.mypaint-brushes
hicolor-icon-theme
numix-icon-theme
alacritty alacritty
firefox
mumble mumble
neofetch neofetch
inkscape
pulseaudio pulseaudio
pulsemixer pulsemixer
wl-clipboard
unstable.keepassxc unstable.keepassxc
wl-clipboard
( (
pkgs.writeTextFile { pkgs.writeTextFile {
name = "startsway"; name = "startsway";
@ -57,11 +78,12 @@ in {
text = '' text = ''
#! ${pkgs.bash}/bin/bash #! ${pkgs.bash}/bin/bash
export MOZ_ENABLE_WAYLAND=1
export QT_QPA_PLATFORM=wayland-egl
export QT_WAYLAND_FORCE_DPI=physical
export SDL_VIDEODRIVER=wayland
export _JAVA_AWT_WM_NOREPARENTING=1 export _JAVA_AWT_WM_NOREPARENTING=1
export MOZ_ENABLE_WAYLAND=1
export QT_AUTO_SCREEN_SCALE_FACTOR=0
export QT_WAYLAND_FORCE_DPI=96
export QT_QPA_PLATFORM=wayland-egl
export SDL_VIDEODRIVER=wayland
exec ${pkgs.dbus}/bin/dbus-run-session ${pkgs.sway}/bin/sway exec ${pkgs.dbus}/bin/dbus-run-session ${pkgs.sway}/bin/sway
''; '';
} }
@ -77,4 +99,8 @@ in {
}; };
services.printing.enable = true; services.printing.enable = true;
hardware.opengl = {
enable = true;
};
} }

View file

@ -5,10 +5,9 @@
let let
unstable = import <nixos-unstable> {}; unstable = import <nixos-unstable> {};
mozilla = import <mozilla> {};
in { in {
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
emacs
go go
python37 python37
python37Packages.pyls-black python37Packages.pyls-black