File Operation Patterns
SkillFiles & storageSafe file operation patterns. Use when performing bulk file operations or writing deployment scripts.
Available today. Use it from your connected AI after setup.
No other account needed.
Connect ahel once, and every AI you use reads what you have installed.
Then ask your AI: use the File Operation Patterns skill
What this skill tells your AI
The instructions your AI receives, as published by tibsfox/gsd-skill-creator in project-claude/skills/file-operation-patterns/SKILL.md and read by ahel’s review.
Safe Patterns
# Create directory tree (idempotent)
mkdir -p path/to/nested/dir
# Copy preserving permissions
cp -rp src/ dst/
# Atomic write (prevents partial reads)
tmpfile=$(mktemp "${target}.XXXXXX")
echo "$content" > "$tmpfile"
mv "$tmpfile" "$target"
# Safe deletion (guard variables)
[ -n "$DIR" ] && [ "$DIR" != "/" ] && rm -rf "$DIR"
# Incremental sync
rsync -av src/ dst/
Anti-Patterns
| Don't | Do |
|---|---|
rm -rf $DIR unguarded | Guard with [ -n "$DIR" ] |
| Write directly to target | Write to temp, then mv |
| Assume dir exists | mkdir -p first |
| Ignore permissions | cp -p or explicit chmod |
Signals
- GitHub stars
- 69
- Forks
- 9
- Last commit
- Jul 2026
Advanced
- Catalog kind
- skill
- Gateway key
file-operation-patterns- Source
- github.com/tibsfox/gsd-skill-creator