whole flake: cleanup
This commit is contained in:
parent
fefa90ecbb
commit
57831df0d5
22 changed files with 330 additions and 437 deletions
|
@ -1,15 +0,0 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (config.meta.mainUser) username;
|
||||
in {
|
||||
home-manager.users.${username}.programs.atuin = {
|
||||
enable = true;
|
||||
package = pkgs.atuin;
|
||||
enableFishIntegration = true;
|
||||
enableBashIntegration = true;
|
||||
};
|
||||
}
|
|
@ -1,25 +0,0 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (config.modules.other.system) username;
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.modules.system.programs.eza;
|
||||
in {
|
||||
config = mkIf cfg.enable {
|
||||
home-manager.users.${username} = {
|
||||
programs.eza = {
|
||||
enable = true;
|
||||
package = pkgs.eza;
|
||||
git = true;
|
||||
icons = "auto";
|
||||
enableNushellIntegration = true;
|
||||
enableBashIntegration = true;
|
||||
enableFishIntegration = true;
|
||||
enableZshIntegration = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,69 +0,0 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib; let
|
||||
cfg = config.modules.programs.fish;
|
||||
inherit (config.modules.other.system) username;
|
||||
in {
|
||||
options.modules.programs.fish = {
|
||||
enable = mkEnableOption "fish";
|
||||
extraAliases = mkOption {
|
||||
type = types.attrs;
|
||||
description = "extra shell aliases";
|
||||
default = {};
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
programs.fish.enable = false;
|
||||
|
||||
# homix.".config/fish/config.fish".source = fishinit;
|
||||
# users.users.${username}.shell = pkgs.fish;
|
||||
|
||||
environment = {
|
||||
# shells = [pkgs.fish];
|
||||
# pathsToLink = ["/share/fish"];
|
||||
};
|
||||
|
||||
home-manager.users.${username} = {
|
||||
programs = {
|
||||
fish = {
|
||||
enable = true;
|
||||
interactiveShellInit = "set fish_greeting";
|
||||
plugins = [
|
||||
{
|
||||
name = "sponge";
|
||||
inherit (pkgs.fishPlugins.sponge) src;
|
||||
}
|
||||
{
|
||||
name = "done";
|
||||
inherit (pkgs.fishPlugins.done) src;
|
||||
}
|
||||
{
|
||||
name = "puffer";
|
||||
inherit (pkgs.fishPlugins.puffer) src;
|
||||
}
|
||||
];
|
||||
shellAbbrs = {
|
||||
c = "clear";
|
||||
cc = "cd ~ && clear";
|
||||
mv = "mv -iv";
|
||||
rm = "trash -v";
|
||||
ls = "eza ";
|
||||
l = "eza -a ";
|
||||
la = "eza -lha --git";
|
||||
lg = "lazygit";
|
||||
cd = "z";
|
||||
v = "nvim";
|
||||
h = "hx";
|
||||
k = "kak";
|
||||
e = "emacs";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,13 +1,7 @@
|
|||
_: {
|
||||
imports = [
|
||||
./fish.nix
|
||||
./nh.nix
|
||||
./starship.nix
|
||||
./thefuck.nix
|
||||
./zoxide.nix
|
||||
./beets.nix
|
||||
./atuin.nix
|
||||
./zellij
|
||||
./eza.nix
|
||||
];
|
||||
}
|
||||
|
|
|
@ -1,101 +0,0 @@
|
|||
# Credits to raf, his flake is in the README.md
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
inherit (builtins) map;
|
||||
inherit (config.meta.mainUser) username;
|
||||
hmCfg = config.home-manager.users.${username};
|
||||
|
||||
inherit (lib.strings) concatStrings;
|
||||
in {
|
||||
home-manager.users.${username} = let
|
||||
elemsConcatted = concatStrings (
|
||||
map (s: "\$${s}") [
|
||||
"hostname"
|
||||
"username"
|
||||
"directory"
|
||||
"shell"
|
||||
"nix_shell"
|
||||
"git_branch"
|
||||
"git_commit"
|
||||
"git_state"
|
||||
"git_status"
|
||||
"jobs"
|
||||
"cmd_duration"
|
||||
]
|
||||
);
|
||||
in {
|
||||
home.sessionVariables = {
|
||||
STARSHIP_CACHE = "${hmCfg.home.homeDirectory}/.cache/starship";
|
||||
};
|
||||
programs.starship = {
|
||||
enable = true;
|
||||
enableFishIntegration = true;
|
||||
enableTransience = true;
|
||||
settings = {
|
||||
scan_timeout = 2;
|
||||
command_timeout = 2000; # nixpkgs makes starship implode with lower values
|
||||
add_newline = false;
|
||||
line_break.disabled = false;
|
||||
|
||||
format = "${elemsConcatted}\n$character";
|
||||
|
||||
hostname = {
|
||||
ssh_only = true;
|
||||
disabled = false;
|
||||
format = "@[$hostname](bold blue) "; # the whitespace at the end is actually important
|
||||
};
|
||||
|
||||
# configure specific elements
|
||||
character = {
|
||||
error_symbol = "[](bold red)";
|
||||
success_symbol = "[](bold green)";
|
||||
vicmd_symbol = "[](bold yellow)";
|
||||
format = "$symbol [|](bold bright-black) ";
|
||||
};
|
||||
|
||||
username = {
|
||||
format = "[$user]($style) in ";
|
||||
};
|
||||
|
||||
directory = {
|
||||
truncation_length = 2;
|
||||
|
||||
# removes the read_only symbol from the format, it doesn't play nicely with my folder icon
|
||||
format = "[ ](bold green) [$path]($style) ";
|
||||
};
|
||||
|
||||
# git
|
||||
git_commit.commit_hash_length = 7;
|
||||
git_branch.style = "bold purple";
|
||||
git_status = {
|
||||
style = "red";
|
||||
ahead = "⇡ ";
|
||||
behind = "⇣ ";
|
||||
conflicted = " ";
|
||||
renamed = "»";
|
||||
deleted = "✘ ";
|
||||
diverged = "⇆ ";
|
||||
modified = "!";
|
||||
stashed = "≡";
|
||||
staged = "+";
|
||||
untracked = "?";
|
||||
};
|
||||
|
||||
# language configurations
|
||||
# the whitespaces at the end *are* necessary for proper formatting
|
||||
lua.symbol = "[ ](blue) ";
|
||||
python.symbol = "[ ](blue) ";
|
||||
rust.symbol = "[ ](red) ";
|
||||
nix_shell.symbol = "[ ](blue) ";
|
||||
golang.symbol = "[ ](blue)";
|
||||
c.symbol = "[ ](black)";
|
||||
nodejs.symbol = "[ ](yellow)";
|
||||
|
||||
package.symbol = "📦 ";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,24 +0,0 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (config.modules.other.system) username;
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.modules.system.programs.oh-my-posh;
|
||||
in {
|
||||
config = mkIf cfg.enable {
|
||||
home-manager.users.${username} = {
|
||||
programs.thefuck = {
|
||||
enable = true;
|
||||
package = pkgs.thefuck;
|
||||
enableInstantMode = true;
|
||||
enableNushellIntegration = true;
|
||||
enableBashIntegration = true;
|
||||
enableFishIntegration = true;
|
||||
enableZshIntegration = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,24 +0,0 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (config.modules.other.system) username;
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.modules.system.programs.eza;
|
||||
in {
|
||||
config = mkIf cfg.enable {
|
||||
home-manager.users.${username} = {
|
||||
programs.zoxide = {
|
||||
enable = true;
|
||||
package = pkgs.zoxide;
|
||||
|
||||
enableNushellIntegration = true;
|
||||
enableBashIntegration = true;
|
||||
enableFishIntegration = true;
|
||||
enableZshIntegration = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -39,58 +39,5 @@ in {
|
|||
environment.systemPackages = [
|
||||
custom-kakoune
|
||||
];
|
||||
home-manager.users.${username}.programs.kakoune = mkIf false {
|
||||
enable = true;
|
||||
package = custom-kakoune;
|
||||
config = {
|
||||
autoComplete = ["insert"];
|
||||
autoReload = "yes";
|
||||
indentWidth = 4;
|
||||
tabStop = 4;
|
||||
incrementalSearch = false;
|
||||
numberLines = {
|
||||
enable = true;
|
||||
relative = true;
|
||||
highlightCursor = true;
|
||||
separator = " ";
|
||||
};
|
||||
|
||||
scrollOff = {
|
||||
lines = 4;
|
||||
columns = 4;
|
||||
};
|
||||
wrapLines = {
|
||||
enable = true;
|
||||
indent = true;
|
||||
word = true;
|
||||
};
|
||||
|
||||
ui = {
|
||||
enableMouse = true;
|
||||
assistant = "none";
|
||||
statusLine = "bottom";
|
||||
};
|
||||
};
|
||||
|
||||
plugins = with pkgs.kakounePlugins; [
|
||||
active-window-kak
|
||||
auto-pairs-kak
|
||||
byline-kak # ope
|
||||
prelude-kak # dependency of byline
|
||||
kak-ls
|
||||
kakboard
|
||||
kakoune-buffer-switcher
|
||||
kakoune-buffers
|
||||
kakoune-lsp
|
||||
kakoune-rainbow
|
||||
kakoune-registers
|
||||
kakoune-vertical-selection
|
||||
powerline-kak
|
||||
quickscope-kak
|
||||
smarttab-kak
|
||||
zig-kak
|
||||
];
|
||||
# extraConfig = ./kakrc;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -3,8 +3,6 @@ _: {
|
|||
./vesktop.nix
|
||||
./foot.nix
|
||||
./spicetify.nix
|
||||
./mpv.nix
|
||||
./zathura.nix
|
||||
./steam.nix
|
||||
./waybar.nix
|
||||
./schizofox.nix
|
||||
|
|
|
@ -1,26 +0,0 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
cfg = config.modules.usrEnv.programs.media.mpv;
|
||||
inherit (config.modules.other.system) username;
|
||||
inherit (lib) mkIf;
|
||||
in {
|
||||
config = mkIf cfg.enable {
|
||||
home-manager.users.${username} = {
|
||||
programs.mpv = {
|
||||
enable = true;
|
||||
config = {
|
||||
hwdec = "auto";
|
||||
volume = 50;
|
||||
osc = "no";
|
||||
osd-bar = "no";
|
||||
border = "no";
|
||||
};
|
||||
scripts = with pkgs.mpvScripts; [mpris thumbfast sponsorblock uosc];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,46 +0,0 @@
|
|||
{pkgs, ...}: let
|
||||
vivado-desktop-symbol = pkgs.makeDesktopItem {
|
||||
name = "vivado2019.2";
|
||||
desktopName = "Vivado";
|
||||
exec = "${pkgs.nur.repos.Nick1296.vivado-2019-2}/bin/vivado";
|
||||
};
|
||||
in {
|
||||
environment.systemPackages = [
|
||||
# this propietary software is huge, but I need it for
|
||||
# university
|
||||
pkgs.nur.repos.Nick1296.vivado-2019-2
|
||||
vivado-desktop-symbol
|
||||
];
|
||||
|
||||
# Create udev rules. Reference: https://blog.kotatsu.dev/posts/2021-09-14-vivado-on-nixos/
|
||||
services.udev.packages = [
|
||||
(pkgs.writeTextFile {
|
||||
name = "xilinx-dilligent-usb-udev";
|
||||
destination = "/etc/udev/rules.d/52-xilinx-digilent-usb.rules";
|
||||
text = ''
|
||||
ATTR{idVendor}=="1443", MODE:="666"
|
||||
ACTION=="add", ATTR{idVendor}=="0403", ATTR{manufacturer}=="Digilent", MODE:="666"
|
||||
'';
|
||||
})
|
||||
(pkgs.writeTextFile {
|
||||
name = "xilinx-pcusb-udev";
|
||||
destination = "/etc/udev/rules.d/52-xilinx-pcusb.rules";
|
||||
text = ''
|
||||
ATTR{idVendor}=="03fd", ATTR{idProduct}=="0008", MODE="666"
|
||||
ATTR{idVendor}=="03fd", ATTR{idProduct}=="0007", MODE="666"
|
||||
ATTR{idVendor}=="03fd", ATTR{idProduct}=="0009", MODE="666"
|
||||
ATTR{idVendor}=="03fd", ATTR{idProduct}=="000d", MODE="666"
|
||||
ATTR{idVendor}=="03fd", ATTR{idProduct}=="000f", MODE="666"
|
||||
ATTR{idVendor}=="03fd", ATTR{idProduct}=="0013", MODE="666"
|
||||
ATTR{idVendor}=="03fd", ATTR{idProduct}=="0015", MODE="666"
|
||||
'';
|
||||
})
|
||||
(pkgs.writeTextFile {
|
||||
name = "xilinx-ftdi-usb-udev";
|
||||
destination = "/etc/udev/rules.d/52-xilinx-ftdi-usb.rules";
|
||||
text = ''
|
||||
ACTION=="add", ATTR{idVendor}=="0403", ATTR{manufacturer}=="Xilinx", MODE:="666"
|
||||
'';
|
||||
})
|
||||
];
|
||||
}
|
|
@ -1,28 +0,0 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib; let
|
||||
cfg = config.modules.system.programs.zathura;
|
||||
inherit (config.modules.other.system) username;
|
||||
in {
|
||||
config = mkIf cfg.enable {
|
||||
home-manager.users.${username} = {
|
||||
programs.zathura = {
|
||||
enable = true;
|
||||
options = {
|
||||
selection-clipboard = "clipboard";
|
||||
adjust-open = "best-fit";
|
||||
pages-per-row = "1";
|
||||
scroll-page-aware = "true";
|
||||
scroll-full-overlap = "0.01";
|
||||
scroll-step = "100";
|
||||
zoom-min = "10";
|
||||
guioptions = "none";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue