fix: move to nixfmt-rfc-style instead of nixpkgs-fmt
This commit is contained in:
parent
5ad03ee2e8
commit
ecbe0c069c
16
flake.nix
16
flake.nix
|
@ -10,9 +10,17 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { self, home-manager, nixpkgs, ... }@inputs:
|
outputs =
|
||||||
let system = "x86_64-linux";
|
{
|
||||||
in {
|
self,
|
||||||
|
home-manager,
|
||||||
|
nixpkgs,
|
||||||
|
...
|
||||||
|
}@inputs:
|
||||||
|
let
|
||||||
|
system = "x86_64-linux";
|
||||||
|
in
|
||||||
|
{
|
||||||
nixosConfigurations."nixos" =
|
nixosConfigurations."nixos" =
|
||||||
let
|
let
|
||||||
specialArgs = inputs;
|
specialArgs = inputs;
|
||||||
|
@ -31,6 +39,6 @@
|
||||||
in
|
in
|
||||||
nixpkgs.lib.nixosSystem { inherit system specialArgs modules; };
|
nixpkgs.lib.nixosSystem { inherit system specialArgs modules; };
|
||||||
|
|
||||||
formatter."${system}" = nixpkgs.legacyPackages.${system}.nixpkgs-fmt;
|
formatter."${system}" = nixpkgs.legacyPackages.${system}.nixfmt-rfc-style;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,13 +1,25 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
# and may be overwritten by future invocations. Please make changes
|
# and may be overwritten by future invocations. Please make changes
|
||||||
# to /etc/nixos/configuration.nix instead.
|
# to /etc/nixos/configuration.nix instead.
|
||||||
{ config, lib, pkgs, modulesPath, ... }:
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
modulesPath,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||||
|
|
||||||
boot.initrd.availableKernelModules =
|
boot.initrd.availableKernelModules = [
|
||||||
[ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
|
"nvme"
|
||||||
|
"xhci_pci"
|
||||||
|
"ahci"
|
||||||
|
"usbhid"
|
||||||
|
"usb_storage"
|
||||||
|
"sd_mod"
|
||||||
|
];
|
||||||
boot.initrd.kernelModules = [ ];
|
boot.initrd.kernelModules = [ ];
|
||||||
boot.kernelModules = [ "kvm-amd" ];
|
boot.kernelModules = [ "kvm-amd" ];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [ ];
|
||||||
|
@ -25,19 +37,29 @@
|
||||||
fileSystems."/mnt/ssd" = {
|
fileSystems."/mnt/ssd" = {
|
||||||
device = "/dev/disk/by-uuid/f27f2224-d351-46fd-89f5-991de36166ad";
|
device = "/dev/disk/by-uuid/f27f2224-d351-46fd-89f5-991de36166ad";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
options = [ "defaults" "nofail" ];
|
options = [
|
||||||
|
"defaults"
|
||||||
|
"nofail"
|
||||||
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/mnt/internal" = {
|
fileSystems."/mnt/internal" = {
|
||||||
device = "/dev/disk/by-uuid/b8541c0d-9146-4388-b217-431f196957cc";
|
device = "/dev/disk/by-uuid/b8541c0d-9146-4388-b217-431f196957cc";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
options = [ "defaults" "nofail" ];
|
options = [
|
||||||
|
"defaults"
|
||||||
|
"nofail"
|
||||||
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/mnt/media" = {
|
fileSystems."/mnt/media" = {
|
||||||
device = "/dev/disk/by-uuid/52c17b8b-46c1-4870-b86c-c3b9f4bd4434";
|
device = "/dev/disk/by-uuid/52c17b8b-46c1-4870-b86c-c3b9f4bd4434";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
options = [ "defaults" "nofail" ];
|
options = [
|
||||||
|
"defaults"
|
||||||
|
"nofail"
|
||||||
|
];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [ ];
|
swapDevices = [ ];
|
||||||
|
@ -51,6 +73,5 @@
|
||||||
# networking.interfaces.enp5s0.useDHCP = lib.mkDefault true;
|
# networking.interfaces.enp5s0.useDHCP = lib.mkDefault true;
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
hardware.cpu.amd.updateMicrocode =
|
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||||
lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -125,10 +125,15 @@
|
||||||
|
|
||||||
# Create an FHS environment using the command `fhs`, enabling the execution of non-NixOS packages in NixOS!
|
# Create an FHS environment using the command `fhs`, enabling the execution of non-NixOS packages in NixOS!
|
||||||
(
|
(
|
||||||
let base = pkgs.appimageTools.defaultFhsEnvArgs;
|
let
|
||||||
in pkgs.buildFHSUserEnv (base // {
|
base = pkgs.appimageTools.defaultFhsEnvArgs;
|
||||||
|
in
|
||||||
|
pkgs.buildFHSUserEnv (
|
||||||
|
base
|
||||||
|
// {
|
||||||
name = "fhs";
|
name = "fhs";
|
||||||
targetPkgs = pkgs:
|
targetPkgs =
|
||||||
|
pkgs:
|
||||||
(
|
(
|
||||||
# pkgs.buildFHSUserEnv provides only a minimal FHS environment,
|
# pkgs.buildFHSUserEnv provides only a minimal FHS environment,
|
||||||
# lacking many basic packages needed by most software.
|
# lacking many basic packages needed by most software.
|
||||||
|
@ -140,7 +145,8 @@
|
||||||
profile = "export FHS=1";
|
profile = "export FHS=1";
|
||||||
runScript = "bash";
|
runScript = "bash";
|
||||||
extraOutputsToInstall = [ "dev" ];
|
extraOutputsToInstall = [ "dev" ];
|
||||||
})
|
}
|
||||||
|
)
|
||||||
)
|
)
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -152,8 +158,7 @@
|
||||||
# plain files is through 'home.file'.
|
# plain files is through 'home.file'.
|
||||||
home.file = {
|
home.file = {
|
||||||
# Cattpuccin theme for fish shell.
|
# Cattpuccin theme for fish shell.
|
||||||
".config/fish/themes/Catppuccin-Frappe.theme".source =
|
".config/fish/themes/Catppuccin-Frappe.theme".source = ./programs/fish/Catppuccin-Frappe.theme;
|
||||||
./programs/fish/Catppuccin-Frappe.theme;
|
|
||||||
|
|
||||||
# Configuration for gamemode, for running games with optimizations.
|
# Configuration for gamemode, for running games with optimizations.
|
||||||
".config/gamemode.ini".source = ./programs/gamemode.ini;
|
".config/gamemode.ini".source = ./programs/gamemode.ini;
|
||||||
|
@ -180,8 +185,7 @@
|
||||||
## Themeing configuration for qt5 and qt6
|
## Themeing configuration for qt5 and qt6
|
||||||
".config/qt5ct/colors".source = ./theming/qt5ct;
|
".config/qt5ct/colors".source = ./theming/qt5ct;
|
||||||
|
|
||||||
".config/qt6ct/colors".source =
|
".config/qt6ct/colors".source = ./theming/qt5ct; # We use the qt5ct because it's the SAME spec
|
||||||
./theming/qt5ct; # We use the qt5ct because it's the SAME spec
|
|
||||||
##
|
##
|
||||||
|
|
||||||
# Configure pipewire for microphone noise supression.
|
# Configure pipewire for microphone noise supression.
|
||||||
|
|
|
@ -1,4 +1,10 @@
|
||||||
{ lib, stdenv, fetchFromGitHub, kernel, kmod }:
|
{
|
||||||
|
lib,
|
||||||
|
stdenv,
|
||||||
|
fetchFromGitHub,
|
||||||
|
kernel,
|
||||||
|
kmod,
|
||||||
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
kernelDirectory = "${kernel.dev}/lib/modules/${kernel.modDirVersion}/build";
|
kernelDirectory = "${kernel.dev}/lib/modules/${kernel.modDirVersion}/build";
|
||||||
|
@ -16,12 +22,13 @@ stdenv.mkDerivation {
|
||||||
|
|
||||||
nativeBuildInputs = [ kmod ] ++ kernel.moduleBuildDependencies;
|
nativeBuildInputs = [ kmod ] ++ kernel.moduleBuildDependencies;
|
||||||
|
|
||||||
hardeningDisable = [ "format" "pic" ];
|
hardeningDisable = [
|
||||||
|
"format"
|
||||||
makeFlags = kernel.makeFlags ++ [
|
"pic"
|
||||||
"KDIR=${kernelDirectory}"
|
|
||||||
];
|
];
|
||||||
|
|
||||||
|
makeFlags = kernel.makeFlags ++ [ "KDIR=${kernelDirectory}" ];
|
||||||
|
|
||||||
makeTargets = [ "modules_install" ];
|
makeTargets = [ "modules_install" ];
|
||||||
|
|
||||||
preBuild = ''
|
preBuild = ''
|
||||||
|
|
27
nixos.nix
27
nixos.nix
|
@ -19,7 +19,10 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
# Enable experimental features
|
# Enable experimental features
|
||||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
nix.settings.experimental-features = [
|
||||||
|
"nix-command"
|
||||||
|
"flakes"
|
||||||
|
];
|
||||||
|
|
||||||
# Enable automatic garbage collection.
|
# Enable automatic garbage collection.
|
||||||
nix.gc = {
|
nix.gc = {
|
||||||
|
@ -91,12 +94,14 @@
|
||||||
8211 # Palworld
|
8211 # Palworld
|
||||||
];
|
];
|
||||||
|
|
||||||
allowedTCPPortRanges = [{
|
allowedTCPPortRanges = [
|
||||||
|
{
|
||||||
from = 1714;
|
from = 1714;
|
||||||
to = 1764;
|
to = 1764;
|
||||||
} # KDEConnect
|
} # KDEConnect
|
||||||
];
|
];
|
||||||
allowedUDPPortRanges = [{
|
allowedUDPPortRanges = [
|
||||||
|
{
|
||||||
from = 1714;
|
from = 1714;
|
||||||
to = 1764;
|
to = 1764;
|
||||||
} # KDEConnect
|
} # KDEConnect
|
||||||
|
@ -115,7 +120,13 @@
|
||||||
users.users.wizardlink = {
|
users.users.wizardlink = {
|
||||||
createHome = true;
|
createHome = true;
|
||||||
description = "Alexandre Cavalheiro";
|
description = "Alexandre Cavalheiro";
|
||||||
extraGroups = [ "networkmanager" "wheel" "postgresql" "docker" "openrazer" ];
|
extraGroups = [
|
||||||
|
"networkmanager"
|
||||||
|
"wheel"
|
||||||
|
"postgresql"
|
||||||
|
"docker"
|
||||||
|
"openrazer"
|
||||||
|
];
|
||||||
|
|
||||||
initialPassword = "wizardlink";
|
initialPassword = "wizardlink";
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
|
@ -214,15 +225,11 @@
|
||||||
xdg.portal = {
|
xdg.portal = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
extraPortals = with pkgs; [
|
extraPortals = with pkgs; [ xdg-desktop-portal-hyprland ];
|
||||||
xdg-desktop-portal-hyprland
|
|
||||||
];
|
|
||||||
|
|
||||||
config = {
|
config = {
|
||||||
common = {
|
common = {
|
||||||
default = [
|
default = [ "hyprland" ];
|
||||||
"hyprland"
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -28,9 +28,13 @@
|
||||||
zoxide init --cmd cd fish | source
|
zoxide init --cmd cd fish | source
|
||||||
'';
|
'';
|
||||||
|
|
||||||
shellAbbrs = { z = "zoxide"; };
|
shellAbbrs = {
|
||||||
|
z = "zoxide";
|
||||||
|
};
|
||||||
|
|
||||||
shellAliases = { del = "trash_file"; };
|
shellAliases = {
|
||||||
|
del = "trash_file";
|
||||||
|
};
|
||||||
|
|
||||||
functions = {
|
functions = {
|
||||||
fish_prompt.body = ''
|
fish_prompt.body = ''
|
||||||
|
|
|
@ -47,9 +47,13 @@
|
||||||
gpgsign = true;
|
gpgsign = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
tag = { gpgsign = true; };
|
tag = {
|
||||||
|
gpgsign = true;
|
||||||
|
};
|
||||||
|
|
||||||
difftool = { prompt = true; };
|
difftool = {
|
||||||
|
prompt = true;
|
||||||
|
};
|
||||||
|
|
||||||
mergetool = {
|
mergetool = {
|
||||||
# https://www.git-scm.com/docs/git-mergetool#Documentation/git-mergetool.txt---no-prompt
|
# https://www.git-scm.com/docs/git-mergetool#Documentation/git-mergetool.txt---no-prompt
|
||||||
|
@ -75,9 +79,13 @@
|
||||||
signingkey = "A1D3A2B4E14BD7C0445BB749A5767B54367CFBDF";
|
signingkey = "A1D3A2B4E14BD7C0445BB749A5767B54367CFBDF";
|
||||||
};
|
};
|
||||||
|
|
||||||
pull = { ff = "only"; };
|
pull = {
|
||||||
|
ff = "only";
|
||||||
|
};
|
||||||
|
|
||||||
init = { defaultBranch = "main"; };
|
init = {
|
||||||
|
defaultBranch = "main";
|
||||||
|
};
|
||||||
|
|
||||||
credential = {
|
credential = {
|
||||||
helper = "/usr/libexec/git-core/git-credential-libsecret";
|
helper = "/usr/libexec/git-core/git-credential-libsecret";
|
||||||
|
|
|
@ -15,8 +15,15 @@
|
||||||
gpu_fan = true;
|
gpu_fan = true;
|
||||||
gpu_junction_temp = true;
|
gpu_junction_temp = true;
|
||||||
gpu_load_change = true;
|
gpu_load_change = true;
|
||||||
gpu_load_color = [ "39F900" "FDFD09" "B22222" ];
|
gpu_load_color = [
|
||||||
gpu_load_value = [ 60 90 ];
|
"39F900"
|
||||||
|
"FDFD09"
|
||||||
|
"B22222"
|
||||||
|
];
|
||||||
|
gpu_load_value = [
|
||||||
|
60
|
||||||
|
90
|
||||||
|
];
|
||||||
gpu_mem_clock = true;
|
gpu_mem_clock = true;
|
||||||
gpu_mem_temp = true;
|
gpu_mem_temp = true;
|
||||||
gpu_power = true;
|
gpu_power = true;
|
||||||
|
@ -26,8 +33,15 @@
|
||||||
|
|
||||||
# CPU Statistics
|
# CPU Statistics
|
||||||
cpu_load_change = true;
|
cpu_load_change = true;
|
||||||
cpu_load_color = [ "39F900" "FDFD09" "B22222" ];
|
cpu_load_color = [
|
||||||
cpu_load_value = [ 60 90 ];
|
"39F900"
|
||||||
|
"FDFD09"
|
||||||
|
"B22222"
|
||||||
|
];
|
||||||
|
cpu_load_value = [
|
||||||
|
60
|
||||||
|
90
|
||||||
|
];
|
||||||
cpu_mhz = true;
|
cpu_mhz = true;
|
||||||
cpu_power = true;
|
cpu_power = true;
|
||||||
cpu_stats = true;
|
cpu_stats = true;
|
||||||
|
@ -46,8 +60,15 @@
|
||||||
# FPS Statistics
|
# FPS Statistics
|
||||||
fps = true;
|
fps = true;
|
||||||
fps_color_change = true;
|
fps_color_change = true;
|
||||||
fps_value = [ 60 90 ];
|
fps_value = [
|
||||||
fps_color = [ "B22222" "FDFD09" "39F900" ];
|
60
|
||||||
|
90
|
||||||
|
];
|
||||||
|
fps_color = [
|
||||||
|
"B22222"
|
||||||
|
"FDFD09"
|
||||||
|
"39F900"
|
||||||
|
];
|
||||||
frametime = true;
|
frametime = true;
|
||||||
frame_timing = true; # Display graphs
|
frame_timing = true; # Display graphs
|
||||||
histogram = true; # ^
|
histogram = true; # ^
|
||||||
|
|
|
@ -34,7 +34,7 @@
|
||||||
|
|
||||||
# Nix
|
# Nix
|
||||||
nil
|
nil
|
||||||
nixpkgs-fmt
|
nixfmt-rfc-style
|
||||||
|
|
||||||
# TypeScript
|
# TypeScript
|
||||||
(callPackage ../vtsls/package.nix { })
|
(callPackage ../vtsls/package.nix { })
|
||||||
|
|
|
@ -12,9 +12,7 @@ return {
|
||||||
-- https://github.com/nvimtools/none-ls.nvim/tree/main/lua/null-ls/builtins/diagnostics
|
-- https://github.com/nvimtools/none-ls.nvim/tree/main/lua/null-ls/builtins/diagnostics
|
||||||
config.sources = {
|
config.sources = {
|
||||||
-- Set a formatter
|
-- Set a formatter
|
||||||
-- null_ls.builtins.formatting.stylua,
|
null_ls.builtins.formatting.nixfmt,
|
||||||
-- null_ls.builtins.formatting.prettier,
|
|
||||||
null_ls.builtins.formatting.nixpkgs_fmt,
|
|
||||||
null_ls.builtins.formatting.prettier,
|
null_ls.builtins.formatting.prettier,
|
||||||
null_ls.builtins.formatting.stylua,
|
null_ls.builtins.formatting.stylua,
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
{ lib
|
{
|
||||||
, buildNpmPackage
|
lib,
|
||||||
, fetchFromGitHub
|
buildNpmPackage,
|
||||||
, importNpmLock
|
fetchFromGitHub,
|
||||||
|
importNpmLock,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
buildNpmPackage rec {
|
buildNpmPackage rec {
|
||||||
|
@ -28,4 +29,12 @@ buildNpmPackage rec {
|
||||||
npmConfigHook = importNpmLock.npmConfigHook;
|
npmConfigHook = importNpmLock.npmConfigHook;
|
||||||
|
|
||||||
dontNpmPrune = true;
|
dontNpmPrune = true;
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
description = "LSP wrapper around TypeScript extension bundled with VSCode.";
|
||||||
|
homepage = "https://github.com/yioneko/vtsls";
|
||||||
|
license = licenses.mit;
|
||||||
|
maintainers = with maintainers; [ wizardlink ];
|
||||||
|
platforms = platforms.all;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
{ ... }: {
|
{ ... }:
|
||||||
|
{
|
||||||
programs.waybar = {
|
programs.waybar = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
|
@ -92,7 +93,13 @@
|
||||||
critical-threshold = 90;
|
critical-threshold = 90;
|
||||||
interval = 5;
|
interval = 5;
|
||||||
format = "{icon} {temperatureC}°";
|
format = "{icon} {temperatureC}°";
|
||||||
format-icons = [ "" "" "" "" "" ];
|
format-icons = [
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
];
|
||||||
tooltip = false;
|
tooltip = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -110,7 +117,13 @@
|
||||||
format-charging-full = " {capacity}%";
|
format-charging-full = " {capacity}%";
|
||||||
format-full = "{icon} {capacity}%";
|
format-full = "{icon} {capacity}%";
|
||||||
format-alt = "{icon} {power}W";
|
format-alt = "{icon} {power}W";
|
||||||
format-icons = [ "" "" "" "" "" ];
|
format-icons = [
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
];
|
||||||
tooltip = false;
|
tooltip = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
{ ... }: {
|
{ ... }:
|
||||||
|
{
|
||||||
services.caddy = {
|
services.caddy = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue