Compare commits

..

No commits in common. "63422ffe6d4a85f8f691dd6aee8111e0c7e6ba11" and "9d8479c88dba3d3d3be4b5b15b82295ced6851d5" have entirely different histories.

6 changed files with 25 additions and 93 deletions

View File

@ -10,8 +10,6 @@
imports = [ imports = [
# Include the results of the hardware scan. # Include the results of the hardware scan.
./hardware-configuration.nix ./hardware-configuration.nix
# script for rebuilding nixos
../../modules/nixos/rebuild.nix
# greetd login manager # greetd login manager
../../modules/nixos/greetd.nix ../../modules/nixos/greetd.nix
# sway as window manager # sway as window manager
@ -84,9 +82,12 @@
# List packages installed in system profile. To search, run: # List packages installed in system profile. To search, run:
# $ nix search wget # $ nix search wget
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
neovim
wget wget
fprintd fprintd
home-manager home-manager
git
alejandra
]; ];
fonts.packages = with pkgs; [ fonts.packages = with pkgs; [

View File

@ -63,7 +63,7 @@
]; ];
home.sessionVariables = { home.sessionVariables = {
EDITOR = "${pkgs.neovim}/bin/nvim"; EDITOR = "nvim";
}; };
xdg.enable = true; xdg.enable = true;

View File

@ -80,6 +80,7 @@
{command = "${pkgs.keepassxc}/bin/keepassxc";} {command = "${pkgs.keepassxc}/bin/keepassxc";}
{command = "${pkgs.waybar}/bin/waybar";} {command = "${pkgs.waybar}/bin/waybar";}
{command = "${pkgs.foot}/bin/foot";} {command = "${pkgs.foot}/bin/foot";}
{command = "${pkgs.firefox}/bin/firefox";}
]; ];
}; };
}; };
@ -243,29 +244,4 @@
fuzzy-match = true fuzzy-match = true
''; '';
}; };
services.mako = {
enable = true;
actions = true;
anchor = "top-right";
backgroundColor = "#313131";
borderColor = "#00FFEE";
progressColor = "#338833";
textColor = "#e0e0e0";
extraConfig = ''
[urgency=low]
border-color=#008877
'';
borderRadius = 10;
borderSize = 2;
height = 100;
width = 400;
defaultTimeout = 10000; # ms
font = "FiraCode Nerd Font 11";
icons = true;
markup = true;
};
} }

View File

@ -10,25 +10,26 @@
historySubstringSearch.enable = true; historySubstringSearch.enable = true;
shellAliases = { shellAliases = {
ls = "${pkgs.eza}/bin/eza --icons -a --group-directories-first"; ls = "${pkgs.eza}/bin/eza --icons -a --group-directories-first";
diff = "${pkgs.diffutils}/bin/diff --color=auto"; diff = "diff --color=auto";
grep = "${pkgs.gnugrep}/bin/grep --color=auto"; grep = "grep --color=auto";
ip = "${pkgs.iproute2}/bin/ip --color=auto"; ip = "ip --color=auto";
mkdir = "${pkgs.coreutils}/bin/mkdir -p"; mkdir = "mkdir -p";
gst = "${pkgs.git}/bin/git status"; gst = "git status";
gc = "${pkgs.git}/bin/git commit"; gc = "git commit";
ga = "${pkgs.git}/bin/git add"; ga = "git add";
gpl = "${pkgs.git}/bin/git pull"; gpl = "git pull";
gpu = "${pkgs.git}/bin/git push"; gpu = "git push";
gd = "${pkgs.git}/bin/git diff"; gd = "git diff";
gch = "${pkgs.git}/bin/git checkout"; gch = "git checkout";
gs = "${pkgs.git}/bin/git switch"; gs = "git switch";
gre = "${pkgs.git}/bin/git restore"; gre = "git restore";
gr = "${pkgs.git}/bin/git remote"; gr = "git remote";
gcl = "${pkgs.git}/bin/git clone"; gcl = "git clone";
glg = "${pkgs.git}/bin/git log --graph --abbrev-commit --decorate --format=format:'%C(bold green)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold yellow)(%ar)%C(reset)%C(auto)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)' --all"; glg = "git log --graph --abbrev-commit --decorate --format=format:'%C(bold green)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold yellow)(%ar)%C(reset)%C(auto)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)' --all";
gb = "${pkgs.git}/bin/git branch"; gb = "git branch";
gm = "${pkgs.git}/bin/git merge"; gm = "git merge";
gf = "${pkgs.git}/bin/git fetch"; gf = "git fetch";
rebuild = "~/dotfiles/nixos/rebuild.sh";
}; };
syntaxHighlighting.enable = true; syntaxHighlighting.enable = true;
syntaxHighlighting.highlighters = ["main" "brackets"]; syntaxHighlighting.highlighters = ["main" "brackets"];

View File

@ -1,45 +0,0 @@
{pkgs, ...}: let
# script for rebuilding nixos
rebuild = pkgs.writeTextFile {
name = "rebuild";
destination = "/bin/rebuild";
executable = true;
text = ''
#!${pkgs.bash}/bin/bash
# A rebuild script that commits on a successful build
set -e
# cd to your config dir
pushd ~/dotfiles/nixos/
# Edit your config
$EDITOR
# Autoformat your nix files
${pkgs.alejandra}/bin/alejandra . #&>/dev/null
# Shows your changes
${pkgs.git}/bin/git diff -U0 *.nix
echo "NixOS Rebuilding..."
# Rebuild, output simplified errors, log trackebacks
${pkgs.sudo}/bin/sudo nixos-rebuild switch &>nixos-switch.log || (${pkgs.coreutils}/bin/cat nixos-switch.log | ${pkgs.gnugrep}/bin/grep --color error && false)
# Get current generation metadata
current=$(nixos-rebuild list-generations | ${pkgs.gnugrep}/bin/grep current)
# Commit all changes with the gereation metadata
${pkgs.git}/bin/git commit -am "$current"
# Back to where you were
popd
# Notify all OK!
${pkgs.libnotify}/bin/notify-send -e "NixOS Rebuilt OK!" --icon=software-update-available
'';
};
in {
environment.systemPackages = [rebuild];
}

View File

@ -48,7 +48,6 @@ in {
wl-clipboard # wl-copy and wl-paste for copy/paste from stdin/stdout wl-clipboard # wl-copy and wl-paste for copy/paste from stdin/stdout
mako # notification system developed by swaywm maintainer mako # notification system developed by swaywm maintainer
wdisplays # tool to configure displays wdisplays # tool to configure displays
libnotify
]; ];
sound.enable = true; sound.enable = true;