From b46e05fd71142ee494a09e9bee27c41064862927 Mon Sep 17 00:00:00 2001 From: Miguel Palhas Date: Wed, 19 Nov 2025 09:25:40 +0000 Subject: [PATCH] claude commands --- home/common/programs/claude-settings.json | 0 .../programs/claude/commands/worktree.md | 12 ++++----- home/common/programs/claude/default.nix | 5 ++++ home/common/programs/claude/settings.json | 26 +++++++++++++++++++ home/common/programs/kitty.nix | 3 ++- home/common/programs/zsh.nix | 4 --- 6 files changed, 38 insertions(+), 12 deletions(-) delete mode 100644 home/common/programs/claude-settings.json create mode 100644 home/common/programs/claude/settings.json diff --git a/home/common/programs/claude-settings.json b/home/common/programs/claude-settings.json deleted file mode 100644 index e69de29..0000000 diff --git a/home/common/programs/claude/commands/worktree.md b/home/common/programs/claude/commands/worktree.md index 11aa1cc..f6faafc 100644 --- a/home/common/programs/claude/commands/worktree.md +++ b/home/common/programs/claude/commands/worktree.md @@ -1,9 +1,7 @@ -Create a new worktree for the requested feature. keep the branch name concise, but starting with claude/. +In "/worktrees/" create a new worktree for the requested feature. +create the directory if it doesn't exist. +keep the branch name concise, but starting with claude/. -Do all the work for the feature in the new worktree. +do all the work for the feature in the new worktree. -Once I ask you to merge: -- start by merging back the new main branch, since I may have made changes to it. -- solve any conflicts that arise. -- merge the new worktree into the main branch. -- delete the worktree. +run "kitty @ set-tab-title" to set the tab title of this kitty sessionn to "claude//" diff --git a/home/common/programs/claude/default.nix b/home/common/programs/claude/default.nix index 48869d2..1fdd57b 100644 --- a/home/common/programs/claude/default.nix +++ b/home/common/programs/claude/default.nix @@ -5,5 +5,10 @@ ... }: { + home.file.".default-npm-packages".text = '' + @anthropic-ai/claude-code + ''; + home.file.".claude/commands".source = ./commands; + home.file.".claude/settings.json".source = ./settings.json; } diff --git a/home/common/programs/claude/settings.json b/home/common/programs/claude/settings.json new file mode 100644 index 0000000..3a3f4da --- /dev/null +++ b/home/common/programs/claude/settings.json @@ -0,0 +1,26 @@ +{ + "permissions": { + "allow": [ + "Bash(kitten @ set-tab-title:*)", + "Bash(mkdir:*)", + "Bash(rg:*)", + "Bash(chmod:*)", + "Bash(find:*)", + "Bash(rustup target:*)", + "Bash(ls:*)", + "Bash(cargo:*)", + "Bash(cp:*)", + "Bash(yarn:*)", + "Bash(sed:*)", + "Bash(gh:*)", + "Bash(git:*)", + "Bash(grep:*)", + "Bash(node:*)" + ], + "defaultMode": "acceptEdits" + }, + "feedbackSurveyState": { + "lastShownTime": 1754052643456 + }, + "$schema": "https://json.schemastore.org/claude-code-settings.json" +} diff --git a/home/common/programs/kitty.nix b/home/common/programs/kitty.nix index 29861cf..eca5205 100644 --- a/home/common/programs/kitty.nix +++ b/home/common/programs/kitty.nix @@ -22,7 +22,7 @@ tab_bar_edge = "bottom"; tab_bar_style = "powerline"; tab_powerline_style = "slanted"; - tab_title_template = "{tab.active_wd.split('/')[-1]}{' :{}'.format(num_windows) if num_windows > 1 else ''}"; + # tab_title_template = "{tab.active_wd.split('/')[-1]}{' :{}'.format(num_windows) if num_windows > 1 else ''}"; tab_bar_filter = "session:~ or session:^$"; # keys @@ -30,6 +30,7 @@ # remove control allow_remote_control = true; + listen_on = "unix:/tmp/kitty.sock"; }; keybindings = { diff --git a/home/common/programs/zsh.nix b/home/common/programs/zsh.nix index 72f0d2f..8b23c76 100644 --- a/home/common/programs/zsh.nix +++ b/home/common/programs/zsh.nix @@ -126,10 +126,6 @@ "ASDF_NODEJS_AUTO_ENABLE_COREPACK" = "true"; }; - home.file.".default-npm-packages".text = '' - @anthropic-ai/claude-code - ''; - home.sessionPath = [ "./.git/safe/../../node_modules/.bin" "./.git/safe/../../bin"