Skip to content

Commit 7efe414

Browse files
committed
add aichat
1 parent 96b50b4 commit 7efe414

7 files changed

Lines changed: 37 additions & 2 deletions

File tree

‎.claude/settings.local.json‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,11 @@
44
"Bash(nix flake check)",
55
"Bash(rg:*)",
66
"Bash(mkdir:*)",
7-
"Bash(git add:*)"
7+
"Bash(git add:*)",
8+
"WebFetch(domain:raw.githubusercontent.com)",
9+
"WebFetch(domain:github.com)",
10+
"WebSearch"
811
],
912
"deny": []
1013
}
11-
}
14+
}

‎home/programs/aichat.nix‎

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{config, ...}: {
2+
age.identityPaths = [
3+
"${config.home.homeDirectory}/.ssh/id_ed25519_agenix"
4+
];
5+
6+
age.secrets.aichat-env = {
7+
file = ../secrets/aichat-env.age;
8+
};
9+
10+
programs.aichat = {
11+
enable = true;
12+
settings = {
13+
model = "claude:claude-sonnet-4-20250514";
14+
clients = [
15+
{type = "claude";}
16+
];
17+
};
18+
};
19+
20+
programs.zsh.sessionVariables = {
21+
AICHAT_ENV_FILE = config.age.secrets.aichat-env.path;
22+
};
23+
}

‎home/programs/default.nix‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{pkgs, ...}: {
22
imports = [
3+
./aichat.nix
34
./starship.nix
45
./tmux.nix
56
./zsh.nix

‎home/secrets/aichat-env.age‎

446 Bytes
Binary file not shown.

‎lib/hosts.nix‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ inputs @ {
3434
home-manager.users.${username} = {...}: {
3535
imports =
3636
[
37+
agenix.homeManagerModules.default
3738
./../modules/home
3839
./../home
3940
]

‎lib/secrets.nix‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,10 @@ let
55
glyphSecrets = import ./secrets/glyph.nix;
66
sporeSecrets = import ./secrets/spore.nix;
77
zetaSecrets = import ./secrets/zeta.nix;
8+
homeSecrets = import ./secrets/home.nix;
89
in
910
globalSecrets
1011
// glyphSecrets
1112
// sporeSecrets
1213
// zetaSecrets
14+
// homeSecrets

‎lib/secrets/home.nix‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
let
2+
keys = with (import ../keys.nix); [home Rhizome];
3+
in {
4+
"home/secrets/aichat-env.age".publicKeys = keys;
5+
}

0 commit comments

Comments
 (0)