This repository has no description
0

Configure Feed

Select the types of activity you want to include in your feed.

superconfig / tools / claude / flake-module.nix
1.2 kB 40 lines
1{ self, ... }: 2{ 3 perSystem = 4 { pkgs, system, ... }: 5 let 6 # Get paths to MCP servers 7 gitMcpPath = "${self.packages.${system}.git-mcp}/bin/git-mcp"; 8 tmuxMcpPath = "${self.packages.${system}.tmux-mcp}/bin/tmux-mcp"; 9 10 # Path to CLAUDE.md 11 claudeMd = ./CLAUDE.md; 12 in 13 { 14 packages.claude = self.wrapLib.makeWrapper { 15 pkgs = pkgs; 16 package = (self.lib.halalify pkgs.claude-code); 17 wrapper = 18 { exePath, ... }: 19 '' 20 set -efu 21 set -x 22 # Configure MCP servers using Claude CLI 23 if ${exePath} mcp add git-mcp "${gitMcpPath}" 2>/dev/null && \ 24 ${exePath} mcp add tmux-mcp "${tmuxMcpPath}" 2>/dev/null; then 25 echo "MCP servers configured successfully" >&2 26 else 27 echo "Warning: Could not configure MCP servers" >&2 28 fi 29 30 # Set up CLAUDE.md if it doesn't exist 31 CLAUDE_MD_DIR="''${CLAUDE_MD_DIR:-$HOME/.claude}" 32 mkdir -p "$CLAUDE_MD_DIR" 33 if [[ ! -f "$CLAUDE_MD_DIR/CLAUDE.md" ]]; then 34 cp ${claudeMd} "$CLAUDE_MD_DIR/CLAUDE.md" 35 fi 36 exec ${exePath} "$@" 37 ''; 38 }; 39 }; 40}