Feature request: Sync repo/org secrets to local .env for local development
还没有人认领这个 Issue。
评估
- 难度
- 5/5
- 预计耗时
- 一周以上
- 新手友好度
- 35/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 冷清
- 技术栈
- github, github-actions, typescript, vscode
调研方向
未指定任何文件或测试。首先跟踪现有的 Secrets 和 Variables 视图以及 GitHub 登录流程,然后验证是否安全支持所提议的 secret 值检索。完成的标准是:该命令预览作用域内的 secret 名称,在写入 workspace 根目录下的 .env 前进行确认,并在 .gitignore 不存在时将其添加进去。
由索引模型根据 Issue 内容生成。
描述
Problem
Developers working locally must manually copy secrets into .env. Error-prone. Painful at scale. Drift between CI and local dev.
Extension already lists secret names in "Secrets" and "Variables" views. Cannot bridge to local env.
Proposed solution
Add command: "GitHub Actions: Pull Secrets to .env"
- Authenticate via existing GitHub login
- Fetch secret names for current repo + environments (same scope as Secrets view)
- Preview available secrets (names only)
- On confirm, fetch decrypted values (workflow-execution approach or new API endpoint)
- Write
.envat workspace root (configurable)
Alternatives
| Option | Gap |
|---|---|
Manual .env |
Current flow — time-consuming, drift-prone |
act + secret file |
Need values already local. No help sourcing |
| GitHub Codespaces | Auto-injects. But only for Codespaces, not local |
gh extension |
Separate tool, extra auth context |
Constraints
- GitHub API does not expose secret plaintext (encrypted at rest by design)
- Needs either: new API endpoint OR one-time workflow that echoes base64-encoded secret values
- Solution parallel to how Codespaces injects secrets into the environment
Prior art
- Codespaces: already auto-injects secrets into dev environment. This request brings parity to local dev.
- #222 (500+ reactions): clear demand for improved secrets UX in extension
Success criteria
- Open local repo in VS Code → run "Pull Secrets to .env"
- GitHub auth (once) → see available secrets by scope
- Confirm →
.envwritten at workspace root .envauto-.gitignore-d if absent
- 主要语言
- TypeScript
- 星标
- 661
- 派生
- 214
- PR 合并指标
- 30 天内没有已合并 PR
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
github/vscode-github-actions 的其他 Issue
-
enhancement
难度 2/5 1-3 小时 新手友好度 76/100
github/vscode-github-actions#627 · 1 个 reaction ·
-
long work 未关闭
难度 4/5 3-5 天 新手友好度 25/100
github/vscode-github-actions#628 ·
-
bug
难度 3/5 1-2 天 新手友好度 55/100
github/vscode-github-actions#625 ·
-
bug
难度 3/5 1-2 天 新手友好度 64/100
github/vscode-github-actions#621 · 3 条评论 ·
-
难度 3/5 1-2 天 新手友好度 50/100
github/vscode-github-actions#619 ·
查看 github/vscode-github-actions 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 75/100
safetrustcr/dApp-SafeTrust#426 ·
-
area:workflow bug ready-for-agent
难度 2/5 1-3 小时 新手友好度 75/100
fil-donadoni/tolaria#4409 ·
-
难度 2/5 1-3 小时 新手友好度 70/100
Fission-AI/OpenSpec#1960 ·
-
Add dependabot 未关闭
难度 2/5 1-3 小时 新手友好度 70/100
-
难度 2/5 1-3 小时 新手友好度 75/100
corsairdev/corsair#1764 ·