feat: add init-agent-ops.sh and update skill documentation
This commit is contained in:
parent
e8d61d77aa
commit
14976fc9f1
2 changed files with 55 additions and 0 deletions
47
agent-ops/bin/init-agent-ops.sh
Executable file
47
agent-ops/bin/init-agent-ops.sh
Executable file
|
|
@ -0,0 +1,47 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# agent-ops/bin/init-agent-ops.sh
|
||||||
|
# 프로젝트에 agent-ops 스캐폴드를 초기화하는 스크립트
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
if [ -z "$1" ]; then
|
||||||
|
echo "Usage: $0 <target_directory>"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
TARGET_DIR=$(realpath "$1")
|
||||||
|
SOURCE_DIR=$(realpath "$(dirname "$0")/..")
|
||||||
|
|
||||||
|
echo "Initializing agent-ops in: $TARGET_DIR"
|
||||||
|
echo "Source agent-ops: $SOURCE_DIR"
|
||||||
|
|
||||||
|
# 1. 대상 폴더 생성
|
||||||
|
mkdir -p "$TARGET_DIR/agent-ops/rules/project/domain"
|
||||||
|
mkdir -p "$TARGET_DIR/agent-ops/rules/private"
|
||||||
|
mkdir -p "$TARGET_DIR/agent-ops/skills/project"
|
||||||
|
|
||||||
|
# 2. 공통 요소 복사 (프로젝트 전용 설정은 제외)
|
||||||
|
cp "$SOURCE_DIR/.version" "$TARGET_DIR/agent-ops/"
|
||||||
|
cp -r "$SOURCE_DIR/rules/common" "$TARGET_DIR/agent-ops/rules/"
|
||||||
|
cp -r "$SOURCE_DIR/skills/common" "$TARGET_DIR/agent-ops/skills/"
|
||||||
|
|
||||||
|
# 3. 에이전트 진입 파일 생성 (common/rules.md 복사)
|
||||||
|
COMMON_RULES="$SOURCE_DIR/rules/common/rules.md"
|
||||||
|
cp "$COMMON_RULES" "$TARGET_DIR/GEMINI.md"
|
||||||
|
cp "$COMMON_RULES" "$TARGET_DIR/CLAUDE.md"
|
||||||
|
cp "$COMMON_RULES" "$TARGET_DIR/AGENTS.md"
|
||||||
|
cp "$COMMON_RULES" "$TARGET_DIR/.cursorrules"
|
||||||
|
cp "$COMMON_RULES" "$TARGET_DIR/.clinerules"
|
||||||
|
|
||||||
|
# 4. .gitignore 설정
|
||||||
|
TOUCH_GITIGNORE="$TARGET_DIR/.gitignore"
|
||||||
|
touch "$TOUCH_GITIGNORE"
|
||||||
|
if ! grep -q "agent-ops/rules/private/" "$TOUCH_GITIGNORE"; then
|
||||||
|
echo "" >> "$TOUCH_GITIGNORE"
|
||||||
|
echo "# Agent-Ops Private Rules" >> "$TOUCH_GITIGNORE"
|
||||||
|
echo "agent-ops/rules/private/" >> "$TOUCH_GITIGNORE"
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Successfully initialized agent-ops in $TARGET_DIR"
|
||||||
|
echo "Note: agent-ops/rules/project and agent-ops/skills/project are initialized as empty."
|
||||||
|
|
@ -149,6 +149,14 @@ common/rules.md와 내용이 중복되지 않도록 한다.
|
||||||
|
|
||||||
도메인은 실제 폴더, 모듈, 패키지, 책임 경계와 연결되어야 한다.
|
도메인은 실제 폴더, 모듈, 패키지, 책임 경계와 연결되어야 한다.
|
||||||
|
|
||||||
|
## 실행 (Execution)
|
||||||
|
|
||||||
|
지정한 대상 디렉토리에 agent-ops 스캐폴드를 생성한다.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
./agent-ops/bin/init-agent-ops.sh <target_directory>
|
||||||
|
```
|
||||||
|
|
||||||
## 실행 절차
|
## 실행 절차
|
||||||
|
|
||||||
1. **상태 판별**
|
1. **상태 판별**
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue