refactor: format config with nixpkgs-fmt

for consistency
This commit is contained in:
Pierre Martin
2022-09-03 07:26:40 +02:00
parent 6d13cc66bc
commit e39666ee76
5 changed files with 79 additions and 73 deletions

View File

@@ -13,7 +13,7 @@
programs.vscode = { programs.vscode = {
enable = true; enable = true;
extensions = []; extensions = [ ];
}; };
services.unclutter.enable = true; services.unclutter.enable = true;
@@ -26,9 +26,11 @@
terminal = "sakura"; terminal = "sakura";
}; };
xsession.windowManager.i3 = let xsession.windowManager.i3 =
let
modifier = "Mod4"; modifier = "Mod4";
in { in
{
enable = true; enable = true;
config = { config = {
assigns = { assigns = {
@@ -150,38 +152,38 @@
setopt PROMPT_CR setopt PROMPT_CR
setopt PROMPT_SP setopt PROMPT_SP
m2wipe() { m2wipe() {
echo "Pouf pouf pouf" echo "Pouf pouf pouf"
sudo rm -rf $1/generated $1/var/cache/**/* $1/pub/static/* $1/var/page_cache $1/var/view_preprocessed sudo rm -rf $1/generated $1/var/cache/**/* $1/pub/static/* $1/var/page_cache $1/var/view_preprocessed
mkdir $1/generated mkdir $1/generated
sudo chmod -R 777 $1/{var,pub,generated,app/etc} sudo chmod -R 777 $1/{var,pub,generated,app/etc}
echo " tchak !" echo " tchak !"
} }
dcrefresh() { dcrefresh() {
dc stop -t0 $1 && dc rm -vf $1 && dc up -d $1 dc stop -t0 $1 && dc rm -vf $1 && dc up -d $1
} }
akamai() { akamai() {
# see https://gist.github.com/saml/4758360 # see https://gist.github.com/saml/4758360
curl -v -s -H "Pragma: akamai-x-cache-on, akamai-x-cache-remote-on, akamai-x-check-cacheable, akamai-x-get-cache-key, akamai-x-get-extracted-values, akamai-x-get-nonces, akamai-x-get-ssl-client-session-id, akamai-x-get-true-cache-key, akamai-x-ser" "$1" 2>&1 > /dev/null curl -v -s -H "Pragma: akamai-x-cache-on, akamai-x-cache-remote-on, akamai-x-check-cacheable, akamai-x-get-cache-key, akamai-x-get-extracted-values, akamai-x-get-nonces, akamai-x-get-ssl-client-session-id, akamai-x-get-true-cache-key, akamai-x-ser" "$1" 2>&1 > /dev/null
} }
unalias v unalias v
# see https://github.com/cantino/mcfly # see https://github.com/cantino/mcfly
export MCFLY_FUZZY=true export MCFLY_FUZZY=true
eval "$(mcfly init zsh)" eval "$(mcfly init zsh)"
eval "$(op completion zsh)"; compdef _op op eval "$(op completion zsh)"; compdef _op op
eval "$(glab completion -s zsh)" eval "$(glab completion -s zsh)"
# K8s # K8s
source <(helm completion zsh) source <(helm completion zsh)
source <(k3d completion zsh) source <(k3d completion zsh)
source <(kubectl completion zsh) source <(kubectl completion zsh)
''; '';
sessionVariables = { sessionVariables = {
EDITOR = "vim"; EDITOR = "vim";

View File

@@ -6,7 +6,8 @@
{ {
imports = imports =
[ # Include the results of the hardware scan. [
# Include the results of the hardware scan.
./hardware-configuration.nix ./hardware-configuration.nix
./framework.nix ./framework.nix
<home-manager/nixos> <home-manager/nixos>
@@ -72,7 +73,7 @@
description = "Pierre"; description = "Pierre";
extraGroups = [ "networkmanager" "wheel" "audio" "docker" "video" ]; extraGroups = [ "networkmanager" "wheel" "audio" "docker" "video" ];
shell = pkgs.zsh; shell = pkgs.zsh;
packages = with pkgs; []; packages = with pkgs; [ ];
}; };
home-manager.users.pierre = import /home/pierre/dotfiles/home.nix; home-manager.users.pierre = import /home/pierre/dotfiles/home.nix;

View File

@@ -5,7 +5,8 @@
{ {
imports = imports =
[ (modulesPath + "/installer/scan/not-detected.nix") [
(modulesPath + "/installer/scan/not-detected.nix")
]; ];
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" ]; boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" ];
@@ -14,18 +15,19 @@
boot.extraModulePackages = [ ]; boot.extraModulePackages = [ ];
fileSystems."/" = fileSystems."/" =
{ device = "/dev/disk/by-uuid/db660732-f520-4e68-9141-b0899f221e82"; {
device = "/dev/disk/by-uuid/db660732-f520-4e68-9141-b0899f221e82";
fsType = "ext4"; fsType = "ext4";
}; };
fileSystems."/boot/efi" = fileSystems."/boot/efi" =
{ device = "/dev/disk/by-uuid/D7D6-B4C6"; {
device = "/dev/disk/by-uuid/D7D6-B4C6";
fsType = "vfat"; fsType = "vfat";
}; };
swapDevices = swapDevices =
[ { device = "/dev/disk/by-uuid/da431bdf-cec4-4928-b44b-e6d2c3419063"; } [{ device = "/dev/disk/by-uuid/da431bdf-cec4-4928-b44b-e6d2c3419063"; }];
];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's # (the default) this is the recommended approach. When using systemd-networkd it's

View File

@@ -109,6 +109,7 @@
playerctl playerctl
numlockx numlockx
nixpkgs-fmt
nodejs-16_x nodejs-16_x
cypress cypress
docker docker