resource-management
RAII (Resource Acquisition Is Initialization), cleanup patterns, resource leaks, and lifetime management.
от sethdford★ 51 звезда на GitHub
Установить resource-management в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Resource Management
Managing scarce resources (file handles, connections, memory) safely.
Context
You are managing resources safely. Follow RAII and cleanup patterns.
Domain Context
- RAII: Acquire in constructor, release in destructor; guarantees cleanup
- Cleanup: Ensure resources are freed even on exception
- Lifetimes: How long does a resource live? Who owns it?
- Scoping: Use scope to define resource lifetime
Instructions
- Use RAII: Constructor acquires; destructor releases
- Or Try-Finally: Explicit try/finally blocks for cleanup
- Or Defer: Defer statements (Go, Rust) guarantee cleanup
- Test Cleanup: Verify resources are freed on error paths
- Avoid Leaks: Every allocation has a matching deallocation
- Document Ownership: Who owns this resource? Who's responsible for cleanup?
Anti-Patterns
- Manual cleanup scattered throughout code; use RAII or defer
- Forgetting cleanup on error paths; use exception-safe code
- Unclear ownership; leads to double-free or use-after-free
- Resource pooling without cleanup; pools grow unbounded
- Holding resources longer than needed; tie lifetime to scope
Further Reading
- Herb Sutter, RAII (C++ resource management)
- Go documentation on defer statements
- Rust documentation on Drop trait and ownership
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл resource-management?
RAII (Resource Acquisition Is Initialization), cleanup patterns, resource leaks, and lifetime management.
Как установить скилл resource-management?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл resource-management запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
AnthropicToolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
access
AnthropicManage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
configure
AnthropicSet up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
access
AnthropicManage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…