mirror of
https://github.com/nmasur/dotfiles
synced 2025-12-17 03:42:43 +00:00
Compare commits
2 Commits
d79c1ba7df
...
ebbc9c5a5d
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ebbc9c5a5d | ||
|
|
aea3e95ef5 |
42
flake.lock
generated
42
flake.lock
generated
@@ -153,7 +153,9 @@
|
|||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
],
|
],
|
||||||
"rust-overlay": "rust-overlay"
|
"rust-overlay": [
|
||||||
|
"rust-overlay"
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1761920229,
|
"lastModified": 1761920229,
|
||||||
@@ -322,11 +324,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_3": {
|
"nixpkgs_3": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1728538411,
|
"lastModified": 1744536153,
|
||||||
"narHash": "sha256-f0SBJz1eZ2yOuKUr5CA9BHULGXVSn6miBuUWdTyhUhU=",
|
"narHash": "sha256-awS2zRgF4uTwrOKwwiJcByDzDOdo3Q1rPZbiHQg/N38=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "b69de56fac8c2b6f8fd27f2eca01dcda8e0a4221",
|
"rev": "18dd725c29603f582cf1900e0d25f9f1063dbf11",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -369,42 +371,22 @@
|
|||||||
"nixpkgs": "nixpkgs_2",
|
"nixpkgs": "nixpkgs_2",
|
||||||
"nixpkgs-stable": "nixpkgs-stable",
|
"nixpkgs-stable": "nixpkgs-stable",
|
||||||
"nur": "nur",
|
"nur": "nur",
|
||||||
|
"rust-overlay": "rust-overlay",
|
||||||
"wsl": "wsl",
|
"wsl": "wsl",
|
||||||
"zellij-switch": "zellij-switch",
|
"zellij-switch": "zellij-switch",
|
||||||
"zenyd-mpv-scripts": "zenyd-mpv-scripts"
|
"zenyd-mpv-scripts": "zenyd-mpv-scripts"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"rust-overlay": {
|
"rust-overlay": {
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"helix",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1759631821,
|
|
||||||
"narHash": "sha256-V8A1L0FaU/aSXZ1QNJScxC12uP4hANeRBgI4YdhHeRM=",
|
|
||||||
"owner": "oxalica",
|
|
||||||
"repo": "rust-overlay",
|
|
||||||
"rev": "1d7cbdaad90f8a5255a89a6eddd8af24dc89cafe",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "oxalica",
|
|
||||||
"repo": "rust-overlay",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"rust-overlay_2": {
|
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": "nixpkgs_3"
|
"nixpkgs": "nixpkgs_3"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1736476219,
|
"lastModified": 1762051177,
|
||||||
"narHash": "sha256-+qyv3QqdZCdZ3cSO/cbpEY6tntyYjfe1bB12mdpNFaY=",
|
"narHash": "sha256-pESNTx/m3WnrYx+OujBtDP5Bj0/mAyHa4MgEwzkgkLE=",
|
||||||
"owner": "oxalica",
|
"owner": "oxalica",
|
||||||
"repo": "rust-overlay",
|
"repo": "rust-overlay",
|
||||||
"rev": "de30cc5963da22e9742bbbbb9a3344570ed237b9",
|
"rev": "08c33e87c4829bbdd42b5af247cf7a19e126369f",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -502,7 +484,9 @@
|
|||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
],
|
],
|
||||||
"rust-overlay": "rust-overlay_2",
|
"rust-overlay": [
|
||||||
|
"rust-overlay"
|
||||||
|
],
|
||||||
"systems": "systems_3"
|
"systems": "systems_3"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
|
|||||||
@@ -64,16 +64,22 @@
|
|||||||
flake = false;
|
flake = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
rust-overlay = {
|
||||||
|
url = "github:oxalica/rust-overlay";
|
||||||
|
};
|
||||||
|
|
||||||
# Zellij Switcher
|
# Zellij Switcher
|
||||||
zellij-switch = {
|
zellij-switch = {
|
||||||
url = "github:mostafaqanbaryan/zellij-switch";
|
url = "github:mostafaqanbaryan/zellij-switch";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
inputs.rust-overlay.follows = "rust-overlay";
|
||||||
};
|
};
|
||||||
|
|
||||||
# Text editor
|
# Text editor
|
||||||
helix = {
|
helix = {
|
||||||
url = "github:helix-editor/helix";
|
url = "github:helix-editor/helix";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
inputs.rust-overlay.follows = "rust-overlay";
|
||||||
};
|
};
|
||||||
|
|
||||||
# # Nextcloud Apps
|
# # Nextcloud Apps
|
||||||
|
|||||||
@@ -0,0 +1,25 @@
|
|||||||
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
|
||||||
|
let
|
||||||
|
cfg = config.nmasur.presets.programs.chawan;
|
||||||
|
in
|
||||||
|
|
||||||
|
{
|
||||||
|
|
||||||
|
options.nmasur.presets.programs.chawan.enable = lib.mkEnableOption "chawan TUI web browser";
|
||||||
|
|
||||||
|
config = lib.mkIf cfg.enable {
|
||||||
|
|
||||||
|
# Set Chawan as the default app for manual pages
|
||||||
|
home.sessionVariables = {
|
||||||
|
MANPAGER = "${lib.getExe pkgs.chawan} -T text/x-ansi";
|
||||||
|
};
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
||||||
@@ -22,7 +22,7 @@ in
|
|||||||
# Set Neovim as the default app for text editing and manual pages
|
# Set Neovim as the default app for text editing and manual pages
|
||||||
home.sessionVariables = {
|
home.sessionVariables = {
|
||||||
EDITOR = lib.mkForce "${lib.getExe pkgs.helix}";
|
EDITOR = lib.mkForce "${lib.getExe pkgs.helix}";
|
||||||
MANPAGER = lib.mkForce "sh -c 'col -bx | ${lib.getExe pkgs.helix}'";
|
# MANPAGER = lib.mkForce "sh -c 'col -bx | ${lib.getExe pkgs.helix}'";
|
||||||
MANWIDTH = 87;
|
MANWIDTH = 87;
|
||||||
MANROFFOPT = "-c";
|
MANROFFOPT = "-c";
|
||||||
};
|
};
|
||||||
@@ -181,17 +181,6 @@ in
|
|||||||
# Commandline git blame
|
# Commandline git blame
|
||||||
space.B = ":echo %sh{git log -n1 --date=short --pretty=format:'%%h %%ad %%s' $(git blame -L %{cursor_line},+1 \"%{buffer_name}\" | cut -d' ' -f1)}";
|
space.B = ":echo %sh{git log -n1 --date=short --pretty=format:'%%h %%ad %%s' $(git blame -L %{cursor_line},+1 \"%{buffer_name}\" | cut -d' ' -f1)}";
|
||||||
|
|
||||||
# Open yazi
|
|
||||||
# https://github.com/sxyazi/yazi/pull/2461
|
|
||||||
# Won't work until next Helix release
|
|
||||||
C-y = [
|
|
||||||
":sh rm -f /tmp/unique-file"
|
|
||||||
":insert-output ${lib.getExe pkgs.yazi} %{buffer_name} --chooser-file=/tmp/unique-file"
|
|
||||||
":insert-output echo \\x1b[?1049h\\x1b[?2004h > /dev/tty"
|
|
||||||
":open %sh{cat /tmp/unique-file}"
|
|
||||||
":redraw"
|
|
||||||
];
|
|
||||||
|
|
||||||
# Extend selection above
|
# Extend selection above
|
||||||
X = "select_line_above";
|
X = "select_line_above";
|
||||||
|
|
||||||
@@ -256,6 +245,10 @@ in
|
|||||||
git-exclude = true; # Skip excluded files
|
git-exclude = true; # Skip excluded files
|
||||||
};
|
};
|
||||||
|
|
||||||
|
completion-replace = true; # Replace whole word with completion
|
||||||
|
trim-trailing-whitespace = true;
|
||||||
|
rainbow-brackets = true; # Make it easier to match parentheses
|
||||||
|
|
||||||
# Show whitespace visible to the user
|
# Show whitespace visible to the user
|
||||||
# Waiting for trailing whitespace option ideally
|
# Waiting for trailing whitespace option ideally
|
||||||
whitespace = {
|
whitespace = {
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ in
|
|||||||
# Set Neovim as the default app for text editing and manual pages
|
# Set Neovim as the default app for text editing and manual pages
|
||||||
home.sessionVariables = {
|
home.sessionVariables = {
|
||||||
EDITOR = "${lib.getExe cfg.package}";
|
EDITOR = "${lib.getExe cfg.package}";
|
||||||
MANPAGER = "${lib.getExe cfg.package} +Man!";
|
# MANPAGER = "${lib.getExe cfg.package} +Man!";
|
||||||
};
|
};
|
||||||
|
|
||||||
# Create quick aliases for launching Neovim
|
# Create quick aliases for launching Neovim
|
||||||
|
|||||||
@@ -198,6 +198,19 @@ in
|
|||||||
height = "99%";
|
height = "99%";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
"bind \"Alt Shift y\"" = {
|
||||||
|
Run = {
|
||||||
|
_args = [
|
||||||
|
(lib.getExe pkgs.yazi)
|
||||||
|
];
|
||||||
|
close_on_exit = true;
|
||||||
|
floating = true;
|
||||||
|
x = "1%";
|
||||||
|
y = "1%";
|
||||||
|
width = "99%";
|
||||||
|
height = "99%";
|
||||||
|
};
|
||||||
|
};
|
||||||
"bind \"Super Shift ]\"" = {
|
"bind \"Super Shift ]\"" = {
|
||||||
GoToNextTab = { };
|
GoToNextTab = { };
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -33,6 +33,7 @@ in
|
|||||||
nmasur.presets = {
|
nmasur.presets = {
|
||||||
programs = {
|
programs = {
|
||||||
bat.enable = lib.mkDefault true;
|
bat.enable = lib.mkDefault true;
|
||||||
|
chawan.enable = lib.mkDefault true;
|
||||||
fd.enable = lib.mkDefault true;
|
fd.enable = lib.mkDefault true;
|
||||||
ripgrep.enable = lib.mkDefault true;
|
ripgrep.enable = lib.mkDefault true;
|
||||||
starship.enable = lib.mkDefault true;
|
starship.enable = lib.mkDefault true;
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ in
|
|||||||
pkgs.delta # Fancy diffs
|
pkgs.delta # Fancy diffs
|
||||||
pkgs.difftastic # Other fancy diffs
|
pkgs.difftastic # Other fancy diffs
|
||||||
pkgs.doggo # DNS client (dig)
|
pkgs.doggo # DNS client (dig)
|
||||||
pkgs.du-dust # Disk usage tree (ncdu)
|
pkgs.dust # Disk usage tree (ncdu)
|
||||||
pkgs.dua # File sizes (du)
|
pkgs.dua # File sizes (du)
|
||||||
pkgs.duf # Basic disk information (df)
|
pkgs.duf # Basic disk information (df)
|
||||||
pkgs.jless # JSON viewer
|
pkgs.jless # JSON viewer
|
||||||
@@ -42,7 +42,7 @@ in
|
|||||||
|
|
||||||
programs.fish.shellAliases = {
|
programs.fish.shellAliases = {
|
||||||
"du" = lib.mkDefault (lib.getExe pkgs.dua);
|
"du" = lib.mkDefault (lib.getExe pkgs.dua);
|
||||||
"ncdu" = lib.mkDefault (lib.getExe pkgs.du-dust);
|
"ncdu" = lib.mkDefault (lib.getExe pkgs.dust);
|
||||||
"df" = lib.mkDefault (lib.getExe pkgs.duf);
|
"df" = lib.mkDefault (lib.getExe pkgs.duf);
|
||||||
|
|
||||||
# Use eza (exa) instead of ls for fancier output
|
# Use eza (exa) instead of ls for fancier output
|
||||||
|
|||||||
Reference in New Issue
Block a user