secrets-env
Load secrets into a gitignored local .env from a committed .env.op reference file, using 1Password (op inject) or a loader command. Use when a task needs credentials in the environment and no .env exists.
- License 许可
- MIT
- 最近更新
- 2026-10-26
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- secrets-env
- description
- Load secrets into a gitignored local .env from a committed .env.op reference file, using 1Password (op inject) or a loader command. Use when a task needs credentials in the environment and no .env exists.
02 资源文件 2
- 脚本scripts/secrets_env.py3.5 KB
- 脚本tests/test_secrets_env.py3.8 KB
03 SKILL.md 正文
secrets-env
Writes a gitignored .env from a committed .env.op file of references
(for example TOKEN=op://vault/item/token). Tools such as mise load .env
automatically afterwards.
Check first
If .env already exists, do not regenerate it: a fresh op call can prompt the
user for biometrics. Regenerate only when secrets were rotated or the file is missing.
Run
python3 plugins/workbench-secrets/skills/secrets-env/scripts/secrets_env.py
python3 .../secrets_env.py --out path/to/local.env --ref path/to/.env.op
Loader choice:
- default:
op inject -i .env.op -o <tmp>(needs the 1Password CLIop) WORKBENCH_SECRETS_CMD=<command>: run with the reference file path as its only argument; its stdout becomes the dotenv content. Use this for any other secret store.
Guarantees
- Refuses when the output path is tracked by git or not ignored by git.
- Refuses when neither
opnorWORKBENCH_SECRETS_CMDis available. - Output file mode is 0600.
- Prints only key names and a count, never values. Do not
catthe resulting file.
04 同仓库更多 Skills
claudy
d claudy
gamma
Literal line one. Literal line two.
beta
Quoted: description with a colon.
alpha
Folded description that spans two lines and ends here.
worktree-merge
Rebases one subagent's worktree onto the base branch, optionally verifies the rebased tree, fast-forwards it into the worktree that has the base checked out (an epic integration tree or the main checkout), verifies every commit landed, and only then removes the worktree and its branch. Keeps the worktree intact on any conflict, dirty tree, or failed check. Use after a subagent returns work created with worktree-create.
worktree-create
Creates one isolated git worktree for one subagent, at <workbench>/.claude/worktrees/<name>, branched from main with the newest origin/main and local main merged in. Refuses a name already in use so two agents can never share a tree. Use once per implementation or review subagent before dispatching it; pair with worktree-merge to land the work and clean up.