33 Commits

Author SHA1 Message Date
github-actions[bot]
e64a9f14d0 flake.lock: Update
Flake lock file updates:

• Updated input 'darwin':
    'github:lnl7/nix-darwin/7220b01d679e93ede8d7b25d6f392855b81dd475' (2025-08-15)
  → 'github:lnl7/nix-darwin/8df64f819698c1fee0c2969696f54a843b2231e8' (2025-08-22)
• Updated input 'disko':
    'github:nix-community/disko/8246829f2e675a46919718f9a64b71afe3bfb22d' (2025-08-12)
  → 'github:nix-community/disko/4073ff2f481f9ef3501678ff479ed81402caae6d' (2025-08-18)
• Updated input 'helix':
    'github:helix-editor/helix/a4a2b50a50971bc43952f5f75d19a56689793a6a' (2025-08-15)
  → 'github:helix-editor/helix/22a3b10dd8ab907367ae1fe57d9703e22b30d391' (2025-08-22)
• Updated input 'home-manager':
    'github:nix-community/home-manager/2a749f4790a14f7168be67cdf6e548ef1c944e10' (2025-08-16)
  → 'github:nix-community/home-manager/8b55a6ac58b678199e5bba701aaff69e2b3281c0' (2025-08-23)
• Updated input 'nix2vim':
    'github:gytis-ivaskevicius/nix2vim/94f136cece965e33aa4ccccb4ca1af04772851f4' (2025-07-15)
  → 'github:gytis-ivaskevicius/nix2vim/78467c8de07719f92397179844bf75cdf2e58b83' (2025-08-16)
• Updated input 'nixpkgs':
    'github:nixos/nixpkgs/fbcf476f790d8a217c3eab4e12033dc4a0f6d23c' (2025-08-14)
  → 'github:nixos/nixpkgs/20075955deac2583bb12f07151c2df830ef346b4' (2025-08-19)
• Updated input 'nur':
    'github:nix-community/nur/160c1c1c8737a0e2109b6181a191779ac2e42f7f' (2025-08-16)
  → 'github:nix-community/nur/1a47d83c521c098debd6d1f2c2ae313a5bb729f9' (2025-08-23)
2025-08-23 03:58:42 +00:00
Noah Masur
e2e179c0e5 Try to fix automatic timezone issues 2025-08-19 08:51:18 -04:00
Noah Masur
e975db7385 replace cloudflare caddy with exact commit 2025-08-17 20:23:22 -04:00
Noah Masur
08ec8ce4b8 reenable zellij by default in the shell 2025-08-17 20:23:17 -04:00
Noah Masur
7388eed876 disable swipe for back and forward in firefox 2025-08-17 20:04:49 -04:00
github-actions[bot]
e53d9eb1a9 flake.lock: Update
Flake lock file updates:

• Updated input 'darwin':
    'github:lnl7/nix-darwin/e04a388232d9a6ba56967ce5b53a8a6f713cdfcf' (2025-06-30)
  → 'github:lnl7/nix-darwin/7220b01d679e93ede8d7b25d6f392855b81dd475' (2025-08-15)
• Updated input 'disko':
    'github:nix-community/disko/545aba02960caa78a31bd9a8709a0ad4b6320a5c' (2025-07-21)
  → 'github:nix-community/disko/8246829f2e675a46919718f9a64b71afe3bfb22d' (2025-08-12)
• Updated input 'helix':
    'github:helix-editor/helix/18572973e6332101810169668894a99261bcd96b' (2025-08-08)
  → 'github:helix-editor/helix/a4a2b50a50971bc43952f5f75d19a56689793a6a' (2025-08-15)
• Updated input 'home-manager':
    'github:nix-community/home-manager/cc2fa2331aebf9661d22bb507d362b39852ac73f' (2025-08-08)
  → 'github:nix-community/home-manager/2a749f4790a14f7168be67cdf6e548ef1c944e10' (2025-08-16)
• Updated input 'nixpkgs':
    'github:nixos/nixpkgs/c2ae88e026f9525daf89587f3cbee584b92b6134' (2025-08-06)
  → 'github:nixos/nixpkgs/fbcf476f790d8a217c3eab4e12033dc4a0f6d23c' (2025-08-14)
• Updated input 'nur':
    'github:nix-community/nur/5df63ce98cc60ec5de75ffd36366e284995351cc' (2025-08-09)
  → 'github:nix-community/nur/160c1c1c8737a0e2109b6181a191779ac2e42f7f' (2025-08-16)
• Updated input 'wsl':
    'github:nix-community/NixOS-WSL/ca55236cd9ef3cdea29b51a0b52a9402c60e9a27' (2025-08-04)
  → 'github:nix-community/NixOS-WSL/203a7b463f307c60026136dd1191d9001c43457f' (2025-08-15)
2025-08-16 04:04:28 +00:00
github-actions[bot]
b956f9dd82 flake.lock: Update
Flake lock file updates:

• Updated input 'helix':
    'github:helix-editor/helix/758f80a4fc9da88ab835248b646468f033162019' (2025-07-31)
  → 'github:helix-editor/helix/18572973e6332101810169668894a99261bcd96b' (2025-08-08)
• Updated input 'home-manager':
    'github:nix-community/home-manager/e102920c1becb114645c6f92fe14edc0b05cc229' (2025-08-01)
  → 'github:nix-community/home-manager/cc2fa2331aebf9661d22bb507d362b39852ac73f' (2025-08-08)
• Updated input 'nixpkgs':
    'github:nixos/nixpkgs/94def634a20494ee057c76998843c015909d6311' (2025-07-31)
  → 'github:nixos/nixpkgs/c2ae88e026f9525daf89587f3cbee584b92b6134' (2025-08-06)
• Updated input 'nur':
    'github:nix-community/nur/f10201b250cda809132a875a03e7b37faff9c0e6' (2025-08-02)
  → 'github:nix-community/nur/5df63ce98cc60ec5de75ffd36366e284995351cc' (2025-08-09)
• Updated input 'wsl':
    'github:nix-community/NixOS-WSL/58c814cc6d4a789191f9c12e18277107144b0c91' (2025-07-28)
  → 'github:nix-community/NixOS-WSL/ca55236cd9ef3cdea29b51a0b52a9402c60e9a27' (2025-08-04)
2025-08-09 04:11:30 +00:00
github-actions[bot]
d7969cc8fc flake.lock: Update
Flake lock file updates:

• Updated input 'helix':
    'github:helix-editor/helix/4281228da35b02b0dcca3b4772b93d48d79ce046' (2025-07-24)
  → 'github:helix-editor/helix/758f80a4fc9da88ab835248b646468f033162019' (2025-07-31)
• Updated input 'home-manager':
    'github:nix-community/home-manager/a1817d1c0e5eabe7dfdfe4caa46c94d9d8f3fdb6' (2025-07-25)
  → 'github:nix-community/home-manager/e102920c1becb114645c6f92fe14edc0b05cc229' (2025-08-01)
• Updated input 'nixpkgs':
    'github:nixos/nixpkgs/fc02ee70efb805d3b2865908a13ddd4474557ecf' (2025-07-23)
  → 'github:nixos/nixpkgs/94def634a20494ee057c76998843c015909d6311' (2025-07-31)
• Updated input 'nur':
    'github:nix-community/nur/dd7b97b8d11ebe7c7513d6c58e13104441862896' (2025-07-26)
  → 'github:nix-community/nur/f10201b250cda809132a875a03e7b37faff9c0e6' (2025-08-02)
• Updated input 'wsl':
    'github:nix-community/NixOS-WSL/a8dfcd2962f6e788759a75b36ca86b14aa44d8e5' (2025-07-25)
  → 'github:nix-community/NixOS-WSL/58c814cc6d4a789191f9c12e18277107144b0c91' (2025-07-28)
2025-08-02 04:16:19 +00:00
Noah Masur
21d66d2be1 adjust helix colors for the cursor theme
make it easier to see the matching parentheses and determine whether you are on the primary or matching side. also make the cursor more white and less yellow in general.
2025-07-30 15:57:26 -04:00
Noah Masur
518848181a fix git blame when there are spaces in the file name 2025-07-30 15:54:17 -04:00
Noah Masur
f9bf763f91 add shortcut to quit helix without saving 2025-07-29 21:48:29 -04:00
Noah Masur
ca20fa0732 improve commandline git blame in helix 2025-07-29 21:48:29 -04:00
Noah Masur
56d10c2765 make lazyjj basically fullscreen floating pane 2025-07-27 21:30:21 -04:00
Noah Masur
3b6b4bd2e6 update lazyjj to be a floating pane 2025-07-27 16:59:16 -04:00
Noah Masur
6f06b0a0c5 add lazyjj integration for zellij 2025-07-27 16:49:37 -04:00
Noah Masur
d3e69faf2f add quit shortcut for helix 2025-07-27 16:30:29 -04:00
Noah Masur
4755a27089 add zellij session toggle feature 2025-07-27 15:42:16 -04:00
Noah Masur
57303d61e9 add normal mode newline in helix 2025-07-27 12:56:15 -04:00
Noah Masur
b67c90dae0 add git blame inside helix 2025-07-27 10:19:52 -04:00
Noah Masur
2ff9254a0e ignore direnv files in helix 2025-07-27 10:18:31 -04:00
Noah Masur
59a8a6dc3f enable personal config on work machine for jj 2025-07-27 10:16:56 -04:00
Noah Masur
5943a6682e add nh package for better config rebuilding 2025-07-27 10:09:16 -04:00
Noah Masur
d38f767d03 allow jujutsu to monitor changes automatically 2025-07-26 21:11:05 -04:00
Noah Masur
ebd79aa348 remove jj pagination 2025-07-26 21:10:53 -04:00
Noah Masur
f778bc58ac enable jujutsu as experimental 2025-07-26 21:10:11 -04:00
Noah Masur
eb1c08f5da make sure to use sudo when rebuilding darwin 2025-07-26 16:00:51 -04:00
Noah Masur
3e7afdc0b3 move everyday programs from experimental to power-user 2025-07-26 16:00:27 -04:00
Noah Masur
45aa5d01e5 enable transient prompts in starship 2025-07-26 15:59:57 -04:00
github-actions[bot]
6a9d1c14a7 flake.lock: Update
Flake lock file updates:

• Updated input 'disko':
    'github:nix-community/disko/d5ad4485e6f2edcc06751df65c5e16572877db88' (2025-07-17)
  → 'github:nix-community/disko/545aba02960caa78a31bd9a8709a0ad4b6320a5c' (2025-07-21)
• Updated input 'helix':
    'github:helix-editor/helix/4418e338e8ea055663c6029080768572d159dba1' (2025-07-18)
  → 'github:helix-editor/helix/4281228da35b02b0dcca3b4772b93d48d79ce046' (2025-07-24)
• Updated input 'home-manager':
    'github:nix-community/home-manager/d0300c8808e41da81d6edfc202f3d3833c157daf' (2025-07-18)
  → 'github:nix-community/home-manager/a1817d1c0e5eabe7dfdfe4caa46c94d9d8f3fdb6' (2025-07-25)
• Updated input 'nixpkgs':
    'github:nixos/nixpkgs/6e987485eb2c77e5dcc5af4e3c70843711ef9251' (2025-07-16)
  → 'github:nixos/nixpkgs/fc02ee70efb805d3b2865908a13ddd4474557ecf' (2025-07-23)
• Updated input 'nur':
    'github:nix-community/nur/d68ea61b416a6a14c036889652a4abe2024c3359' (2025-07-19)
  → 'github:nix-community/nur/dd7b97b8d11ebe7c7513d6c58e13104441862896' (2025-07-26)
• Updated input 'wsl':
    'github:nix-community/NixOS-WSL/20001f9bf0aaf2b1c307e43a5eec8cf8f800fe14' (2025-07-16)
  → 'github:nix-community/NixOS-WSL/a8dfcd2962f6e788759a75b36ca86b14aa44d8e5' (2025-07-25)
2025-07-26 04:17:33 +00:00
Noah Masur
3fe4843032 add keybind to skip auto-comment on newline 2025-07-24 22:32:47 -04:00
Noah Masur
6a36408416 add comments to clarify helix file picker 2025-07-24 22:32:08 -04:00
Noah Masur
25c7aec532 fix: using i3 keybinds to rebuild 2025-07-24 22:31:47 -04:00
Noah Masur
b87db529ae add nixfmt to power user profile 2025-07-24 22:21:09 -04:00
15 changed files with 161 additions and 65 deletions

48
flake.lock generated
View File

@@ -22,11 +22,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1751313918, "lastModified": 1755825449,
"narHash": "sha256-HsJM3XLa43WpG+665aGEh8iS8AfEwOIQWk3Mke3e7nk=", "narHash": "sha256-XkiN4NM9Xdy59h69Pc+Vg4PxkSm9EWl6u7k6D5FZ5cM=",
"owner": "lnl7", "owner": "lnl7",
"repo": "nix-darwin", "repo": "nix-darwin",
"rev": "e04a388232d9a6ba56967ce5b53a8a6f713cdfcf", "rev": "8df64f819698c1fee0c2969696f54a843b2231e8",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -43,11 +43,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1752718651, "lastModified": 1755519972,
"narHash": "sha256-PkaR0qmyP9q/MDN3uYa+RLeBA0PjvEQiM0rTDDBXkL8=", "narHash": "sha256-bU4nqi3IpsUZJeyS8Jk85ytlX61i4b0KCxXX9YcOgVc=",
"owner": "nix-community", "owner": "nix-community",
"repo": "disko", "repo": "disko",
"rev": "d5ad4485e6f2edcc06751df65c5e16572877db88", "rev": "4073ff2f481f9ef3501678ff479ed81402caae6d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -156,11 +156,11 @@
"rust-overlay": "rust-overlay" "rust-overlay": "rust-overlay"
}, },
"locked": { "locked": {
"lastModified": 1752851830, "lastModified": 1755869734,
"narHash": "sha256-6MHI6FRiui4MR/Ek3s5yO84UVL7d1bPYdzF5LF0ZyCY=", "narHash": "sha256-d9hwkPwlpbih4DVbsV0zrK5i2J6cRT7ifrDYK5LZQs8=",
"owner": "helix-editor", "owner": "helix-editor",
"repo": "helix", "repo": "helix",
"rev": "4418e338e8ea055663c6029080768572d159dba1", "rev": "22a3b10dd8ab907367ae1fe57d9703e22b30d391",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -176,11 +176,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1752814804, "lastModified": 1755914636,
"narHash": "sha256-irfg7lnfEpJY+3Cffkluzp2MTVw1Uq9QGxFp6qadcXI=", "narHash": "sha256-VJ+Gm6YsHlPfUCpmRQxvdiZW7H3YPSrdVOewQHAhZN8=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "d0300c8808e41da81d6edfc202f3d3833c157daf", "rev": "8b55a6ac58b678199e5bba701aaff69e2b3281c0",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -222,11 +222,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1752588843, "lastModified": 1755344765,
"narHash": "sha256-T4vw0himO8ami5uR7cry+El9HlQkqNcy/UtIFwkcTMw=", "narHash": "sha256-k/Cvh/mzb5lSvilKdgwNBCyAyYmD8YPr1nc0sTSgwxI=",
"owner": "gytis-ivaskevicius", "owner": "gytis-ivaskevicius",
"repo": "nix2vim", "repo": "nix2vim",
"rev": "94f136cece965e33aa4ccccb4ca1af04772851f4", "rev": "78467c8de07719f92397179844bf75cdf2e58b83",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -273,11 +273,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1752687322, "lastModified": 1755615617,
"narHash": "sha256-RKwfXA4OZROjBTQAl9WOZQFm7L8Bo93FQwSJpAiSRvo=", "narHash": "sha256-HMwfAJBdrr8wXAkbGhtcby1zGFvs+StOp19xNsbqdOg=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "6e987485eb2c77e5dcc5af4e3c70843711ef9251", "rev": "20075955deac2583bb12f07151c2df830ef346b4",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -327,11 +327,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1752895120, "lastModified": 1755918818,
"narHash": "sha256-kzJ85DF2QSSDA34Pw6mh2Y2WQM1RWBjRVMD0/I3Iejg=", "narHash": "sha256-a7k/fml8k4CxIcVW26luwqVl3lsRMNXBRCyC8uSF0GA=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nur", "repo": "nur",
"rev": "d68ea61b416a6a14c036889652a4abe2024c3359", "rev": "1a47d83c521c098debd6d1f2c2ae313a5bb729f9",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -449,11 +449,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1752682362, "lastModified": 1755261305,
"narHash": "sha256-ZNIpqCG/CfhmV+TgIeyO/XbhDjSWpwWokHM44j0Mn0w=", "narHash": "sha256-EOqCupB5X5WoGVHVcfOZcqy0SbKWNuY3kq+lj1wHdu8=",
"owner": "nix-community", "owner": "nix-community",
"repo": "NixOS-WSL", "repo": "NixOS-WSL",
"rev": "20001f9bf0aaf2b1c307e43a5eec8cf8f800fe14", "rev": "203a7b463f307c60026136dd1191d9001c43457f",
"type": "github" "type": "github"
}, },
"original": { "original": {

View File

@@ -33,9 +33,6 @@ rec {
system.stateVersion = "23.05"; system.stateVersion = "23.05";
# Overrides
services.automatic-timezoned.enable = false;
# Not sure what's necessary but too afraid to remove anything # Not sure what's necessary but too afraid to remove anything
boot.initrd.availableKernelModules = [ boot.initrd.availableKernelModules = [
"xhci_pci" "xhci_pci"

View File

@@ -74,6 +74,8 @@ in
"svg.context-properties.content.enabled" = true; # Sidebery styling "svg.context-properties.content.enabled" = true; # Sidebery styling
"browser.tabs.hoverPreview.enabled" = false; # Disable tab previews "browser.tabs.hoverPreview.enabled" = false; # Disable tab previews
"browser.tabs.hoverPreview.showThumbnails" = false; # Disable tab previews "browser.tabs.hoverPreview.showThumbnails" = false; # Disable tab previews
"browser.gesture.swipe.left" = "cmd_scrollLeft"; # Disable swipe to go back
"browser.gesture.swipe.right" = "cmd_scrollRight"; # Disable swipe to go forward
}; };
userChrome = '' userChrome = ''
:root { :root {

View File

@@ -1,6 +1,5 @@
{ {
config, config,
pkgs,
lib, lib,
... ...
}: }:
@@ -66,6 +65,18 @@ in
}; };
}; };
# Personal jj config
programs.jujutsu.settings = {
"--scope" = [
{
"--when".repositories = [ "~/dev/personal" ];
user = {
name = cfg.personal.name;
email = cfg.personal.email;
};
}
];
};
}; };
} }

View File

@@ -130,6 +130,7 @@ in
ignores = [ ignores = [
"content/.obsidian/**" "content/.obsidian/**"
".direnv/**"
]; ];
settings = { settings = {
@@ -146,6 +147,10 @@ in
"keep_primary_selection" "keep_primary_selection"
]; ];
# Quit shortcuts
space.q = ":quit-all";
space.x = ":quit-all!";
# Enable and disable inlay hints # Enable and disable inlay hints
space.H = ":toggle lsp.display-inlay-hints"; space.H = ":toggle lsp.display-inlay-hints";
@@ -160,7 +165,7 @@ in
space.l = [ space.l = [
":write-all" ":write-all"
":new" ":new"
":insert-output ${lib.getExe pkgs.lazygit}" ":insert-output ${lib.getExe pkgs.lazygit} > /dev/tty"
":buffer-close!" ":buffer-close!"
":redraw" ":redraw"
":reload-all" ":reload-all"
@@ -168,6 +173,9 @@ in
":set mouse true" ":set mouse true"
]; ];
# 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)}";
# Open yazi # Open yazi
# https://github.com/sxyazi/yazi/pull/2461 # https://github.com/sxyazi/yazi/pull/2461
# Won't work until next Helix release # Won't work until next Helix release
@@ -195,6 +203,27 @@ in
"paste_before" "paste_before"
]; ];
A-S-ret = [
"open_above"
"normal_mode"
];
A-ret = [
"open_below"
"normal_mode"
];
};
keys.insert = {
# Allows not continuing the comment
"A-ret" = [
"insert_newline"
"extend_to_line_bounds"
"delete_selection"
"insert_newline"
"move_line_up"
"insert_mode"
];
}; };
editor = { editor = {
@@ -216,10 +245,10 @@ in
# Show hidden files # Show hidden files
file-picker = { file-picker = {
hidden = false; hidden = false; # Show hidden files
git-ignore = true; git-ignore = true; # Skip gitignore files
git-global = true; git-global = true; # Skip global gitignore files
git-exclude = true; git-exclude = true; # Skip excluded files
}; };
# Show whitespace visible to the user # Show whitespace visible to the user
@@ -322,7 +351,7 @@ in
bg = config.theme.colors.base00; bg = config.theme.colors.base00;
}; };
"ui.cursor" = { "ui.cursor" = {
fg = config.theme.colors.base0A; fg = config.theme.colors.base04;
modifiers = [ "reversed" ]; modifiers = [ "reversed" ];
}; };
"ui.cursor.insert" = { "ui.cursor.insert" = {
@@ -334,11 +363,11 @@ in
bg = config.theme.colors.base01; bg = config.theme.colors.base01;
}; };
"ui.cursor.match" = { "ui.cursor.match" = {
fg = config.theme.colors.base0A; fg = config.theme.colors.base03;
modifiers = [ "reversed" ]; modifiers = [ "reversed" ];
}; };
"ui.cursor.select" = { "ui.cursor.select" = {
fg = config.theme.colors.base0A; fg = config.theme.colors.base04;
modifiers = [ "reversed" ]; modifiers = [ "reversed" ];
}; };
"ui.gutter" = { "ui.gutter" = {

View File

@@ -1,5 +1,6 @@
{ {
config, config,
pkgs,
lib, lib,
... ...
}: }:
@@ -22,8 +23,18 @@ in
name = config.programs.git.userName; name = config.programs.git.userName;
email = config.programs.git.userEmail; email = config.programs.git.userEmail;
}; };
ui.paginate = "never";
# Automatically snapshot when files change
fsmonitor.backend = "watchman";
fsmonitor.watchman.register-snapshot-trigger = true;
}; };
}; };
home.packages = [
# Required for the fsmonitor to auto-snapshot
pkgs.watchman
];
}; };
} }

View File

@@ -24,7 +24,7 @@ in
# These are useful for triggering from zellij (rather than running directly in the shell) # These are useful for triggering from zellij (rather than running directly in the shell)
nmasur.presets.programs.nixpkgs.commands.rebuildNixos = pkgs.writeShellScriptBin "rebuild-darwin" '' nmasur.presets.programs.nixpkgs.commands.rebuildNixos = pkgs.writeShellScriptBin "rebuild-darwin" ''
git -C ${config.nmasur.presets.programs.dotfiles.path} add --intent-to-add --all git -C ${config.nmasur.presets.programs.dotfiles.path} add --intent-to-add --all
darwin-rebuild switch --flake "${config.nmasur.presets.programs.dotfiles.path}#${config.nmasur.settings.host}" sudo darwin-rebuild switch --flake "${config.nmasur.presets.programs.dotfiles.path}#${config.nmasur.settings.host}"
''; '';
programs.fish = { programs.fish = {
@@ -40,13 +40,13 @@ in
rebuild-darwin = { rebuild-darwin = {
body = '' body = ''
git -C ${config.nmasur.presets.programs.dotfiles.path} add --intent-to-add --all git -C ${config.nmasur.presets.programs.dotfiles.path} add --intent-to-add --all
echo "darwin-rebuild switch --flake ${config.nmasur.presets.programs.dotfiles.path}#lookingglass" echo "sudo darwin-rebuild switch --flake ${config.nmasur.presets.programs.dotfiles.path}#lookingglass"
''; '';
}; };
rebuild-darwin-offline = { rebuild-darwin-offline = {
body = '' body = ''
git -C ${config.nmasur.presets.programs.dotfiles.path} add --intent-to-add --all git -C ${config.nmasur.presets.programs.dotfiles.path} add --intent-to-add --all
echo "darwin-rebuild switch --option substitute false --flake ${config.nmasur.presets.programs.dotfiles.path}#lookingglass" echo "sudo darwin-rebuild switch --option substitute false --flake ${config.nmasur.presets.programs.dotfiles.path}#lookingglass"
''; '';
}; };
rebuild-home = lib.mkForce { rebuild-home = lib.mkForce {

View File

@@ -35,6 +35,7 @@ in
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
home.packages = [ home.packages = [
pkgs.nh # Allows rebuilding with a cleaner TUI
cfg.commands.rebuildHome cfg.commands.rebuildHome
cfg.commands.rebuildNixos cfg.commands.rebuildNixos
]; ];

View File

@@ -19,6 +19,7 @@ in
enable = true; enable = true;
enableFishIntegration = true; enableFishIntegration = true;
enableBashIntegration = true; enableBashIntegration = true;
enableTransience = true; # Replace previous prompts with custom string
settings = { settings = {
add_newline = false; # Don't print new line at the start of the prompt add_newline = false; # Don't print new line at the start of the prompt
format = lib.concatStrings [ format = lib.concatStrings [
@@ -80,6 +81,17 @@ in
}; };
}; };
}; };
programs.fish = {
functions = {
# Adjust the prompt in previous commands
starship_transient_prompt_func = {
body = "echo '$ '";
};
starship_transient_rprompt_func = {
body = "echo ' '";
};
};
};
}; };
} }

View File

@@ -7,6 +7,15 @@
let let
cfg = config.nmasur.presets.programs.zellij; cfg = config.nmasur.presets.programs.zellij;
zellij-switch-to-last = pkgs.writeShellScriptBin "zellij-switch-to-last" ''
TARGET_SESSION=$(cat ~/.local/state/zellij-last-session)
if [ -z "$TARGET_SESSION" ]; then
return 1
fi
echo "$ZELLIJ_SESSION_NAME" > ~/.local/state/zellij-last-session
zellij pipe --plugin file:$(which zellij-switch.wasm) -- "--session $TARGET_SESSION"
'';
in in
{ {
@@ -31,6 +40,7 @@ in
if test "$TARGET_DIR" = $(pwd) if test "$TARGET_DIR" = $(pwd)
return 1 return 1
end end
echo "$ZELLIJ_SESSION_NAME" > ~/.local/state/zellij-last-session
zellij pipe --plugin file:$(which zellij-switch.wasm) -- "--cwd $TARGET_DIR --layout default --session $(basename $TARGET_DIR)" zellij pipe --plugin file:$(which zellij-switch.wasm) -- "--cwd $TARGET_DIR --layout default --session $(basename $TARGET_DIR)"
''; '';
}; };
@@ -69,13 +79,13 @@ in
programs.zellij = { programs.zellij = {
enable = true; enable = true;
# Auto start on shell init
enableBashIntegration = true; enableBashIntegration = true;
enableFishIntegration = true; enableFishIntegration = true;
enableZshIntegration = true; enableZshIntegration = true;
attachExistingSession = true;
# Not yet available in unstable exitShellOnExit = false;
# attachExistingSession = true;
# exitShellOnExit = true;
settings = { settings = {
default_mode = "locked"; default_mode = "locked";
@@ -109,6 +119,14 @@ in
}; };
}; };
shared = { shared = {
"bind \"Alt Shift s\"" = {
Run = {
_args = [
(lib.getExe zellij-switch-to-last)
];
close_on_exit = true;
};
};
"bind \"Alt Shift p\"" = { "bind \"Alt Shift p\"" = {
Run = { Run = {
_args = [ _args = [
@@ -167,6 +185,19 @@ in
]; ];
}; };
}; };
"bind \"Alt Shift j\"" = {
Run = {
_args = [
(lib.getExe pkgs.lazyjj)
];
close_on_exit = true;
floating = true;
x = "1%";
y = "1%";
width = "99%";
height = "99%";
};
};
"bind \"Super Shift ]\"" = { "bind \"Super Shift ]\"" = {
GoToNextTab = { }; GoToNextTab = { };
}; };
@@ -190,11 +221,6 @@ in
_args = [ "scroll" ]; _args = [ "scroll" ];
}; };
}; };
"bind \"Alt k\"" = lib.mkIf pkgs.stdenv.isLinux {
SwitchToMode = {
_args = [ "scroll" ];
};
};
"bind \"Super Shift e\"" = lib.mkIf pkgs.stdenv.isDarwin { "bind \"Super Shift e\"" = lib.mkIf pkgs.stdenv.isDarwin {
EditScrollback = { }; EditScrollback = { };
SwitchToMode = { SwitchToMode = {

View File

@@ -214,9 +214,9 @@ in
cfg.commands.lockScreen != null cfg.commands.lockScreen != null
) "exec ${cfg.commands.lockScreen}"; ) "exec ${cfg.commands.lockScreen}";
"${modifier}+Mod1+h" = "${modifier}+Mod1+h" =
''exec --no-startup-id ${lib.getExe cfg.terminal} --command sh -c "${pkgs.home-manager}/bin/home-manager switch --flake ${config.nmasur.presets.programs.dotfiles.path}#''${hostname} || read" ''; ''exec --no-startup-id ${lib.getExe cfg.terminal} --command="${pkgs.home-manager}/bin/home-manager switch --flake ${config.nmasur.presets.programs.dotfiles.path}#''${hostname} || read" '';
"${modifier}+Mod1+r" = "${modifier}+Mod1+r" =
"exec --no-startup-id ${lib.getExe cfg.terminal} --command sh -c 'doas nixos-rebuild switch --flake ${config.nmasur.presets.programs.dotfiles.path} || read'"; "exec --no-startup-id ${lib.getExe cfg.terminal} --command='doas nixos-rebuild switch --flake ${config.nmasur.presets.programs.dotfiles.path} || read'";
# Window options # Window options
"${modifier}+q" = "kill"; "${modifier}+q" = "kill";

View File

@@ -17,10 +17,7 @@ in
nmasur.presets.programs = { nmasur.presets.programs = {
zed-editor.enable = lib.mkDefault true; zed-editor.enable = lib.mkDefault true;
ghostty.enable = lib.mkDefault true; jujutsu.enable = lib.mkDefault true;
helix.enable = lib.mkDefault true;
zellij.enable = lib.mkDefault true;
lazygit.enable = lib.mkDefault true;
}; };
home.packages = [ home.packages = [
@@ -32,8 +29,6 @@ in
pkgs.charm # Manage account and filesystem pkgs.charm # Manage account and filesystem
pkgs.pop # Send emails from a TUI pkgs.pop # Send emails from a TUI
pkgs.yazi # TUI file explorer
]; ];
programs.gh-dash.enable = lib.mkDefault true; programs.gh-dash.enable = lib.mkDefault true;

View File

@@ -25,16 +25,19 @@ in
pkgs.jless # JSON viewer pkgs.jless # JSON viewer
pkgs.jo # JSON output pkgs.jo # JSON output
pkgs.mpd # TUI slideshows pkgs.mpd # TUI slideshows
pkgs.nixfmt-rfc-style # Format Nix code
pkgs.nmasur.jqr # FZF fq JSON tool pkgs.nmasur.jqr # FZF fq JSON tool
pkgs.nmasur.osc # Clipboard over SSH pkgs.nmasur.osc # Clipboard over SSH
# pkgs.nmasur.ren-find # Rename files pkgs.nmasur.ren-find # Rename files
# pkgs.nmasur.rep-grep # Replace text in files pkgs.nmasur.rep-grep # Replace text in files
pkgs.pandoc # Convert text documents pkgs.pandoc # Convert text documents
pkgs.qrencode # Generate qr codes pkgs.qrencode # Generate qr codes
pkgs.spacer # Output lines in terminal pkgs.spacer # Output lines in terminal
pkgs.tealdeer # Cheatsheets pkgs.tealdeer # Cheatsheets
pkgs.tree # Print tree in terminal pkgs.tree # Print tree in terminal
pkgs.vimv-rs # Batch rename files pkgs.vimv-rs # Batch rename files
pkgs.yazi # TUI file explorer
]; ];
programs.fish.shellAliases = { programs.fish.shellAliases = {
@@ -57,8 +60,10 @@ in
fd.enable = lib.mkDefault true; fd.enable = lib.mkDefault true;
fish.enable = lib.mkDefault true; fish.enable = lib.mkDefault true;
fzf.enable = lib.mkDefault true; fzf.enable = lib.mkDefault true;
ghostty.enable = lib.mkDefault true;
git.enable = lib.mkDefault true; git.enable = lib.mkDefault true;
helix.enable = lib.mkDefault true; helix.enable = lib.mkDefault true;
lazygit.enable = lib.mkDefault true;
neovim.enable = lib.mkDefault true; neovim.enable = lib.mkDefault true;
nix-index.enable = lib.mkDefault true; nix-index.enable = lib.mkDefault true;
nixpkgs.enable = lib.mkDefault true; nixpkgs.enable = lib.mkDefault true;
@@ -67,6 +72,7 @@ in
ripgrep.enable = lib.mkDefault true; ripgrep.enable = lib.mkDefault true;
weather.enable = lib.mkDefault true; weather.enable = lib.mkDefault true;
yt-dlp.enable = lib.mkDefault true; yt-dlp.enable = lib.mkDefault true;
zellij.enable = lib.mkDefault true;
zoxide.enable = lib.mkDefault true; zoxide.enable = lib.mkDefault true;
}; };

View File

@@ -67,7 +67,7 @@ in
# Tell Caddy to use Cloudflare DNS for ACME challenge validation # Tell Caddy to use Cloudflare DNS for ACME challenge validation
services.caddy.package = pkgs.caddy.withPlugins { services.caddy.package = pkgs.caddy.withPlugins {
plugins = [ "github.com/caddy-dns/cloudflare@v0.2.1" ]; plugins = [ "github.com/caddy-dns/cloudflare@8cbec3f04d5b4a768c52941a5468c4b71436509e" ]; # v0.2.1
hash = "sha256-2D7dnG50CwtCho+U+iHmSj2w14zllQXPjmTHr6lJZ/A="; hash = "sha256-2D7dnG50CwtCho+U+iHmSj2w14zllQXPjmTHr6lJZ/A=";
}; };
nmasur.presets.services.caddy.tlsPolicies = [ nmasur.presets.services.caddy.tlsPolicies = [
@@ -159,12 +159,13 @@ in
requires = [ "cloudflare-api-secret.service" ]; requires = [ "cloudflare-api-secret.service" ];
script = script =
let let
args = args = [
[ "--cache-file /var/lib/cloudflare-dyndns/ip.cache" ] "--cache-file /var/lib/cloudflare-dyndns/ip.cache"
++ (if config.services.cloudflare-dyndns.ipv4 then [ "-4" ] else [ "-no-4" ]) ]
++ (if config.services.cloudflare-dyndns.ipv6 then [ "-6" ] else [ "-no-6" ]) ++ (if config.services.cloudflare-dyndns.ipv4 then [ "-4" ] else [ "-no-4" ])
++ lib.optional config.services.cloudflare-dyndns.deleteMissing "--delete-missing" ++ (if config.services.cloudflare-dyndns.ipv6 then [ "-6" ] else [ "-no-6" ])
++ lib.optional config.services.cloudflare-dyndns.proxied "--proxied"; ++ lib.optional config.services.cloudflare-dyndns.deleteMissing "--delete-missing"
++ lib.optional config.services.cloudflare-dyndns.proxied "--proxied";
in in
lib.mkForce '' lib.mkForce ''
export CLOUDFLARE_API_TOKEN=$(cat ''${CREDENTIALS_DIRECTORY}/apiToken) export CLOUDFLARE_API_TOKEN=$(cat ''${CREDENTIALS_DIRECTORY}/apiToken)

View File

@@ -24,6 +24,11 @@ in
# Enable automatic timezone updates based on location # Enable automatic timezone updates based on location
services.automatic-timezoned.enable = lib.mkDefault true; services.automatic-timezoned.enable = lib.mkDefault true;
services.geoclue2 = {
# see: https://github.com/NixOS/nixpkgs/issues/68489#issuecomment-1484030107
enableDemoAgent = lib.mkForce true;
geoProviderUrl = "https://beacondb.net/v1/geolocate";
};
# Allow reading from Windows drives # Allow reading from Windows drives
boot.supportedFilesystems = [ "ntfs" ]; boot.supportedFilesystems = [ "ntfs" ];