main
Ray Publish 0.1.0 4cd2f07 15d ago
#!/usr/bin/env python3
"""Install this package's skill (adom-bluegreen) into Claude and Codex homes."""
import argparse, json, os, shutil
from pathlib import Path
ROOT=Path(__file__).resolve().parents[1]
parser=argparse.ArgumentParser();parser.add_argument('--home',type=Path,help='Isolated home for validation');args=parser.parse_args()
home=args.home or Path.home()
codex=home/'.codex' if args.home else Path(os.environ.get('CODEX_HOME',str(home/'.codex')))
for destination in [home/'.claude/skills',codex/'skills']:
    for source in sorted((ROOT/'skills').iterdir()):
        if not (source/'SKILL.md').is_file():continue
        target=destination/source.name
        target.mkdir(parents=True,exist_ok=True)
        shutil.copytree(source,target,dirs_exist_ok=True)
        print(target)