Skip to content

Commit 81ede89

Browse files
2 parents be9bdf4 + c04ab41 commit 81ede89

8 files changed

Lines changed: 114 additions & 14 deletions

File tree

agents/.skill-lock.json

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,25 @@
88
"skillPath": "dg/SKILL.md",
99
"skillFolderHash": "fcbfa793d2e40c0a84fef9cb97b84919f1c51442",
1010
"installedAt": "2026-04-03T13:22:15.516Z",
11-
"updatedAt": "2026-04-03T13:22:15.516Z"
11+
"updatedAt": "2026-04-03T15:23:45.081Z"
12+
},
13+
"diataxis": {
14+
"source": "alpha/dotfiles",
15+
"sourceType": "git",
16+
"sourceUrl": "https://git.kejadlen.dev/alpha/dotfiles.git",
17+
"skillPath": "ai/skills/diataxis/SKILL.md",
18+
"skillFolderHash": "",
19+
"installedAt": "2026-04-06T15:37:40.760Z",
20+
"updatedAt": "2026-04-06T15:37:40.760Z"
21+
},
22+
"technical-writing": {
23+
"source": "alpha/dotfiles",
24+
"sourceType": "git",
25+
"sourceUrl": "https://git.kejadlen.dev/alpha/dotfiles.git",
26+
"skillPath": "ai/skills/technical-writing/SKILL.md",
27+
"skillFolderHash": "",
28+
"installedAt": "2026-04-06T15:37:40.762Z",
29+
"updatedAt": "2026-04-06T15:37:40.762Z"
1230
}
1331
},
1432
"dismissed": {

bin/pickletown

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
#!/usr/bin/env bash
2+
#
3+
# Wrapper for pickletown CLI
4+
#
5+
# Resolves pt_root from ~/.config/pickletown/config.yml and execs
6+
# the real binary. Supports a special "root" subcommand that prints
7+
# the resolved pt_root path (exits non-zero if unavailable).
8+
9+
config="$HOME/.config/pickletown/config.yml"
10+
11+
if [[ ! -f "$config" ]]; then
12+
echo "pickletown: config not found at $config" >&2
13+
exit 1
14+
fi
15+
16+
# Extract pt_root from config.yml (simple grep, no yq dependency)
17+
pt_root=$(grep '^pt_root:' "$config" | awk '{print $2}')
18+
pt_root="${pt_root/#\~/$HOME}"
19+
20+
if [[ -z "$pt_root" ]]; then
21+
echo "pickletown: pt_root not set in $config" >&2
22+
exit 1
23+
fi
24+
25+
# "root" subcommand: print pt_root and exit
26+
if [[ "$1" == "root" ]]; then
27+
if [[ -d "$pt_root" ]]; then
28+
echo "$pt_root"
29+
exit 0
30+
else
31+
echo "pickletown: pt_root directory not found: $pt_root" >&2
32+
exit 1
33+
fi
34+
fi
35+
36+
# Pass through to real binary
37+
exec "$pt_root/cli/bin/pickletown" "$@"

claude/README.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ When you run `./claudeconfig.sh`:
9797
2. **Active role** (`roles/$ROLE.jsonc`): settings deep-merged on top of base. Permissions and sandbox arrays concatenated (not deep-merged, which would replace arrays)
9898
3. **Stacks** (`stacks/*.jsonc`, sorted alphabetically): permissions and sandbox arrays concatenated
9999
4. **Deduplication**: all arrays sorted and deduplicated
100-
5. **Local keys**: `model`, `enabledPlugins`, `extraKnownMarketplaces` preserved from existing `~/.claude/settings.json`
100+
5. **Local keys**: `enabledPlugins`, `extraKnownMarketplaces` preserved from existing `~/.claude/settings.json`
101101
6. **Validation and write**
102102

103103
## Common Tasks
@@ -211,14 +211,13 @@ When you notice you're repeatedly approving the same permission across projects:
211211

212212
These keys in `~/.claude/settings.json` are preserved across regenerations:
213213

214-
- `model`: machine-specific model preference
215214
- `enabledPlugins`: plugin activation state (tracked in gt-1bil)
216215
- `extraKnownMarketplaces`: managed by `configure_marketplaces()` in claudeconfig.sh
217216

218217
## Files NOT to Edit
219218

220219
- `~/.claude/settings.json`: generated by `claudeconfig.sh`, will be overwritten
221-
- Exception: `model`, `enabledPlugins`, and `extraKnownMarketplaces` are preserved
220+
- Exception: `enabledPlugins` and `extraKnownMarketplaces` are preserved
222221

223222
## Debugging
224223

claude/roles/base.jsonc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
22
// Base settings
3+
"model": "opus[1m]",
34
"defaultMode": "acceptEdits",
45
"statusLine": {
56
"type": "command",
@@ -10,6 +11,7 @@
1011

1112
// Permissions: base safety rules
1213
"permissions": {
14+
"defaultMode": "acceptEdits"
1315
"allow": [
1416
"Bash(rm -rf .DS_Store)",
1517
"Bash(rm -rf .cache)",
@@ -107,7 +109,9 @@
107109
"allowWrite": [
108110
// interactive terminals for things like lefthook interactive
109111
"/dev/ptmx",
110-
"/dev/ttys*"
112+
"/dev/ttys*",
113+
// plugin hooks use uv run which needs to create .venv in cache
114+
"~/.claude/plugins/cache"
111115
]
112116
}
113117
},

claudeconfig.sh

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ generate_settings() {
7575
local temp_file="$(mktemp)"
7676

7777
# Local-only keys preserved from existing settings across regenerations
78-
local local_keys=("model" "enabledPlugins" "extraKnownMarketplaces")
78+
local local_keys=("enabledPlugins" "extraKnownMarketplaces")
7979

8080
# Extract local-only settings from existing file
8181
local local_settings="{}"
@@ -286,5 +286,4 @@ echo "✓ Claude Code configuration complete"
286286
echo " Settings: $HOME/.claude/settings.json"
287287
echo " Role: $ROLE"
288288
echo ""
289-
echo "Note: Skills are now installed per-project via craftdesk."
290-
echo " Run 'craftdesk-setup' in a project to configure skills."
289+
echo "Note: Global skills are restored from ~/.agents/.skill-lock.json via skills.sh"

home/.markdownlint-cli2.yaml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Global markdownlint-cli2 configuration
2+
# Symlinked to ~/.markdownlint-cli2.yaml via dotfiles
3+
#
4+
# markdownlint-cli2 searches for .markdownlint-cli2.yaml walking up from the
5+
# file being linted. Placing this in ~ makes it the global fallback.
6+
# Per-repo configs still take precedence.
7+
8+
config:
9+
# Line length: nobody hard-wraps prose at 80 anymore
10+
MD013: false
11+
12+
# Inline HTML: common in GitHub markdown (details, summary, br, etc)
13+
MD033: false
14+
15+
# First line should be a heading: breaks with frontmatter, metadata blocks
16+
MD041: false
17+
18+
# Table column style: cosmetic pipe spacing, let formatters handle it
19+
MD060: false

home/.tmux.conf

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ bind -N "open Claude Code" C new-window -c "#{pane_current_path}" "claude"
5656
# replacing undefined vars with empty strings. $(cmd) is safe - tmux doesn't
5757
# process command substitution syntax. If fzf is cancelled, --connect gets an
5858
# empty arg which falls through to the interactive selector (harmless).
59-
bind -N "workspace picker (via pickletown)" N run-shell "pickletown workspaces --connect \"$(pickletown workspaces --color | fzf-tmux -p 80%,70% --ansi --prompt 'workspace> ' | awk '{print $1}')\""
59+
bind -N "workspace picker (via pickletown)" N run-shell "~/pickleton/cli/bin/pickletown workspaces --connect \"$(~/pickleton/cli/bin/pickletown workspaces --color | fzf-tmux -p 80%,70% --ansi --prompt 'workspace> ' | awk '{print $1}')\""
6060

6161
# Keybinding command palette (fuzzy find all bindings with descriptions)
6262
bind -N "command palette" ? run-shell -b "~/.pickles/bin/tmux-command-palette"
@@ -81,8 +81,9 @@ bind -T copy-mode-vi Escape send-keys -X cancel
8181
# Mouse selection copies but stays in copy mode (for tmux-open 'o' to work)
8282
bind -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-selection-no-clear
8383

84-
# Double-click selects word, copies, and opens if URL (otherwise just copies)
85-
bind -n DoubleClick1Pane select-pane \; copy-mode -M \; send-keys -X select-word \; send-keys -X copy-pipe-and-cancel '~/.pickles/bin/tmux-smart-open'
84+
# Double-click selects word (native tmux behavior with mouse on)
85+
# To open a URL: double-click to select, then press 'o' (tmux-open plugin)
86+
unbind -n DoubleClick1Pane
8687

8788
# Auto-name new sessions after the directory they're started in
8889
# Skips if session was explicitly named (non-numeric name)

skills.sh

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,33 @@ if ! command -v npx &>/dev/null; then
1717
exit 0
1818
fi
1919

20-
# Restore globally installed skills from the lock file
21-
jq -r '.skills | to_entries[] | .value.source' "$HOME/.agents/.skill-lock.json" | while read -r source; do
22-
echo " 📦 installing $source"
20+
LOCK_FILE="$HOME/.agents/.skill-lock.json"
21+
22+
# Restore GitHub-sourced skills (simple: one skill per source)
23+
jq -r '.skills | to_entries[] | select(.value.sourceType == "github") | .value.source' "$LOCK_FILE" | while read -r source; do
24+
echo " 📦 installing $source (github)"
2325
npx -y skills add "$source" -g -y
2426
done
2527

28+
# Restore git-sourced skills (grouped by sourceUrl, with -s flags per skill)
29+
# Skip LFS smudge since remote repos may have LFS objects we don't need
30+
jq -r '
31+
[.skills | to_entries[] | select(.value.sourceType == "git")]
32+
| group_by(.value.sourceUrl)[]
33+
| { url: .[0].value.sourceUrl, skills: [.[].key] }
34+
| @json
35+
' "$LOCK_FILE" | while read -r group; do
36+
url=$(echo "$group" | jq -r '.url')
37+
mapfile -t skill_names < <(echo "$group" | jq -r '.skills[]')
38+
39+
skill_flags=""
40+
for name in "${skill_names[@]}"; do
41+
skill_flags="$skill_flags -s $name"
42+
done
43+
44+
echo " 📦 installing ${skill_names[*]} from $url"
45+
# shellcheck disable=SC2086
46+
GIT_LFS_SKIP_SMUDGE=1 npx -y skills add "$url" $skill_flags -g -y
47+
done
48+
2649
echo

0 commit comments

Comments
 (0)