Setup laptop hibernation and nix dotfiles alias

This commit is contained in:
Daniel Flanagan 2020-10-26 23:43:18 -05:00
parent 44f819a1db
commit 984e56ba67
Signed by: lytedev
GPG key ID: 5B2020A0F9921EF4
2 changed files with 11 additions and 0 deletions

View file

@ -77,6 +77,7 @@ alias cdc "d $XDG_CONFIG_HOME" # go to ~/.config
alias cdn "d $NOTES_PATH" alias cdn "d $NOTES_PATH"
alias cdl "d $NICE_HOME/dl" alias cdl "d $NICE_HOME/dl"
alias cdg "d $NICE_HOME/games" alias cdg "d $NICE_HOME/games"
alias cdnx "d $DOTFILES_PATH/env/nix"
# quick parent-directory aliases # quick parent-directory aliases
alias .. "d .." alias .. "d .."

View file

@ -31,6 +31,16 @@
xft-dpi=260 xft-dpi=260
''; '';
swapDevices = [ { device = "/swapfile"; size = (1024*16); } ];
boot = {
# fallocate -l 16G /swapfile
resumeDevice = "/dev/disk/by-uuid/d1d92974-c0c0-4566-8131-c3dda9b21122";
# sudo filefrag -v /swapfile | head -n 4 | tail -n 1 | \
# tr -s "[:blank:]" | field 5 | tr -d ":"
kernelParams = [ "resume_offset=874496" ];
};
# services.upower = { # services.upower = {
# enable = true; # enable = true;
# criticalPowerAction = "Hibernate"; # criticalPowerAction = "Hibernate";