Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

「优化」自定义生成文件名 #238

Open
TechQuery opened this issue Mar 1, 2024 · 2 comments · May be fixed by #363
Open

「优化」自定义生成文件名 #238

TechQuery opened this issue Mar 1, 2024 · 2 comments · May be fixed by #363

Comments

@TechQuery
Copy link
Contributor

TechQuery commented Mar 1, 2024

期待改变

@Yuyz0112 为了支持复杂项目开发,希望基于 GitHub issue form 的 YAML 配置文件,实现独立表单项填写生成代码的自定义文件名,例如:

涉及代码

大致浏览了核心代码,找出几处可能涉及的修改点,但可能不全面:

function getCurrentCode(owner: string, repo: string, branch: string) {
return getFileContent(owner, repo, branch, "preview-ui/src/Preview.jsx");
}

dewhale/prompts/ui-gen.ts

Lines 156 to 158 in 3d073f8

const result = await composeWorkflow(uiGenLabel, {
"preview-ui/src/Preview.jsx": PLACEHOLDER_CODE,
});

dewhale/prompts/ui-gen.ts

Lines 206 to 216 in 3d073f8

await applyPR(
owner,
repo,
issue.number,
branch,
{
"preview-ui/src/Preview.jsx": refineCode(code),
},
`${dewhalePrefix} prompt:\r\n${commitMsg}`,
[uiGenLabel]
);

@Yuyz0112
Copy link
Owner

Yuyz0112 commented Mar 3, 2024

很好的思路。
我先了解一下基于 yaml 的结构化 issue 配置方式。

@TechQuery
Copy link
Contributor Author

TechQuery commented May 27, 2024

我先了解一下基于 yaml 的结构化 issue 配置方式。

#306 已经实现了表单配置,接下来就需要把前端框架替换为 Next.js 这样的文件目录路由,或使用 Parcel 的 glob 加载机制

@TechQuery TechQuery linked a pull request Jul 28, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants