mirror of
https://github.com/Gerg-L/nixos.git
synced 2025-12-10 00:43:56 -05:00
renamed configuration.nix to common.nix
moved sudo configuration to shells.nix switched to kmscon reorganized all packages removed a few switched from scripts to shell aliases set keep-outputs and keep-derivations to false removed picom from laptop
This commit is contained in:
parent
4b3e928482
commit
b3cb8940d4
11 changed files with 119 additions and 115 deletions
|
|
@ -1,4 +1,29 @@
|
|||
{pkgs, ...}: {
|
||||
services.kmscon = {
|
||||
enable = true;
|
||||
hwRender = true;
|
||||
extraConfig = ''
|
||||
font-size=12
|
||||
'';
|
||||
fonts = [
|
||||
{
|
||||
name = "Overpass Mono";
|
||||
package = pkgs.overpass;
|
||||
}
|
||||
{
|
||||
name = "OverpassMono Nerd Font";
|
||||
package =
|
||||
pkgs.nerdfonts.override
|
||||
{
|
||||
fonts = ["Overpass"];
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "Material Design Icons";
|
||||
package = pkgs.material-design-icons;
|
||||
}
|
||||
];
|
||||
};
|
||||
fonts = {
|
||||
fonts = with pkgs; [
|
||||
overpass
|
||||
|
|
@ -8,6 +33,7 @@
|
|||
fonts = ["Overpass"];
|
||||
})
|
||||
];
|
||||
enableDefaultFonts = false;
|
||||
fontDir.enable = true;
|
||||
fontconfig = {
|
||||
enable = true;
|
||||
|
|
|
|||
|
|
@ -1,40 +1,28 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
inputs,
|
||||
...
|
||||
}: {
|
||||
{pkgs, ...}: {
|
||||
environment = {
|
||||
defaultPackages = []; #don't install anything by default
|
||||
systemPackages = with pkgs; [
|
||||
bottom #view tasks
|
||||
efibootmgr #efi editor
|
||||
maim #screenshooter
|
||||
pciutils #lspci
|
||||
alsa-utils #volume control
|
||||
btrfs-progs #for external harddrive
|
||||
vlc #play stuff
|
||||
webcord # talk to people (gross)
|
||||
feh #for wallpaper
|
||||
xfce.mousepad
|
||||
brightnessctl #brightness control for laptop
|
||||
playerctl #music control
|
||||
networkmanagerapplet #gui connection control
|
||||
pavucontrol #gui volume control
|
||||
xclip #commandline clipboard access
|
||||
exa #ls replacement
|
||||
cava #pretty audio
|
||||
nitch # cus yes
|
||||
dmenu #suckless launcher
|
||||
st #suckless terminal
|
||||
pipes-rs # more fun things
|
||||
pcmanfm #file manager
|
||||
nix-tree #view packages
|
||||
btrfs-progs #for external harddrive
|
||||
feh #for wallpaper
|
||||
|
||||
#directly used tui apps
|
||||
bottom #view tasks
|
||||
bc #terminal calculator
|
||||
page #use nvim as a pager
|
||||
nix-tree #view packages
|
||||
#pointless stuff
|
||||
cava #pretty audio
|
||||
pipes-rs # more fun things
|
||||
|
||||
#gui apps
|
||||
pavucontrol #gui volume control
|
||||
pcmanfm #file manager
|
||||
#big gui apps
|
||||
webcord # talk to people (gross)
|
||||
librewolf #best browser
|
||||
inputs.nvim-config.packages.${pkgs.system}.default #my custom nvim flake
|
||||
fetch-rs
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,41 +0,0 @@
|
|||
{pkgs, ...}: let
|
||||
update-system = pkgs.writeShellScriptBin "update-system" ''
|
||||
if ! [ $(id -u) = 0 ]; then
|
||||
echo "RUN AS ROOT"
|
||||
exit 1
|
||||
fi
|
||||
nix flake update /etc/nixos/#
|
||||
'';
|
||||
|
||||
clean-store = pkgs.writeShellScriptBin "clean-store" ''
|
||||
if ! [ $(id -u) = 0 ]; then
|
||||
echo "RUN AS ROOT"
|
||||
exit 1
|
||||
fi
|
||||
rm /nix/var/nix/gcroots/auto/*
|
||||
nix-collect-garbage -d
|
||||
'';
|
||||
|
||||
apply-system = pkgs.writeShellScriptBin "apply-system" ''
|
||||
if ! [ $(id -u) = 0 ]; then
|
||||
echo "RUN AS ROOT"
|
||||
exit 1
|
||||
fi
|
||||
nixos-rebuild switch --flake /etc/nixos/#
|
||||
'';
|
||||
|
||||
full-upgrade = pkgs.writeShellScriptBin "full-upgrade" ''
|
||||
if ! [ $(id -u) = 0 ]; then
|
||||
echo "RUN AS ROOT"
|
||||
exit 1
|
||||
fi
|
||||
update-system
|
||||
apply-system
|
||||
'';
|
||||
|
||||
pastebin = pkgs.writeShellScriptBin "pastebin" ''
|
||||
curl -F 'clbin=<-' https://clbin.com
|
||||
'';
|
||||
in {
|
||||
environment.systemPackages = [update-system apply-system full-upgrade clean-store pastebin];
|
||||
}
|
||||
|
|
@ -1,18 +1,68 @@
|
|||
{pkgs, ...}: {
|
||||
{
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: rec {
|
||||
environment = {
|
||||
systemPackages = with pkgs; [
|
||||
dash
|
||||
neovim
|
||||
page
|
||||
zsh
|
||||
st
|
||||
exa
|
||||
fetch-rs
|
||||
];
|
||||
binsh = "${pkgs.dash}/bin/dash"; #use dash for speed
|
||||
variables = {
|
||||
EDITOR = "vi";
|
||||
VISUAL = "vi";
|
||||
EDITOR = "nvim";
|
||||
VISUAL = "nvim";
|
||||
PAGER = "page";
|
||||
SYSTEMD_PAGERSECURE = "true";
|
||||
TERMINAL = "st";
|
||||
NIX_BUILD_SHELL = "zsh";
|
||||
};
|
||||
shellAliases = {
|
||||
ls = "exa --long --icons";
|
||||
vm-start = "virsh start Windows";
|
||||
vm-stop = "virsh shutdown Windows";
|
||||
#make sudo use aliases
|
||||
sudo = "sudo ";
|
||||
#paste link trick
|
||||
pastebin = "curl -F 'clbin=<-' https://clbin.com";
|
||||
#nix stuff
|
||||
update = "nix flake update /etc/nixos/#";
|
||||
switch = "nixos-rebuild switch";
|
||||
boot = "nixos-rebuild boot";
|
||||
clean = "nix-collect-garbage -d";
|
||||
gc-force = "rm /nix/var/gcroots/auto/*";
|
||||
gc-check = "find -H /nix/var/nix/gcroots/auto -type l | xargs -I {} sh -c 'readlink {}; realpath {}; echo' | page";
|
||||
#vim stuff
|
||||
vi = "nvim";
|
||||
vim = "nvim";
|
||||
vimdiff = "nvim -d";
|
||||
#exa is 1 too many letters
|
||||
ls = "exa";
|
||||
l = "exa -lbF --git";
|
||||
ll = "$exa -lbGF --git";
|
||||
llm = "exa -lbGd --git --sort=modified";
|
||||
la = "exa -lbhHigUmuSa --time-style=long-iso --git --color-scale";
|
||||
lx = "exa -lbhHigUmuSa@ --time-style=long-iso --git --color-scale";
|
||||
lS = "exa -1";
|
||||
lt = "exa --tree --level=2";
|
||||
};
|
||||
interactiveShellInit = "fetch-rs";
|
||||
};
|
||||
security.sudo = {
|
||||
enable = true;
|
||||
execWheelOnly = true;
|
||||
extraConfig = ''
|
||||
Defaults env_keep += "${builtins.concatStringsSep " " (builtins.attrNames environment.variables)}"
|
||||
'';
|
||||
};
|
||||
|
||||
#zsh stuff
|
||||
users.defaultUserShell = pkgs.zsh;
|
||||
environment.shells = [pkgs.zsh];
|
||||
programs = {
|
||||
zsh = {
|
||||
enable = true;
|
||||
|
|
@ -23,6 +73,7 @@
|
|||
enable = true;
|
||||
};
|
||||
};
|
||||
#starship
|
||||
starship = {
|
||||
enable = true;
|
||||
settings = {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,9 @@
|
|||
{
|
||||
{pkgs, ...}: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
maim #screenshooter
|
||||
brightnessctl #brightness control for laptop
|
||||
playerctl #music control
|
||||
];
|
||||
services.sxhkd = {
|
||||
enable = true;
|
||||
keybindings = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue