-
Notifications
You must be signed in to change notification settings - Fork 63
chore: change deploy path #200
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
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Walkthrough将构建产物目录 dist 新增到 .gitignore;在 package.json 中把 docs:deploy 脚本的发布目录从 .doc 改为 dist。无其他变更。 Changes
Sequence Diagram(s)sequenceDiagram
autonumber
actor Dev as Developer
participant NPM as npm scripts
participant GH as gh-pages CLI
participant Pages as GitHub Pages
Dev->>NPM: run docs:deploy
NPM->>GH: gh-pages -d dist
GH->>Pages: Publish contents of dist branch/dir
Note right of Pages: 站点内容来自 dist
Note over Dev,GH: .gitignore 新增 dist(仅影响版本控制)
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests
Tip 👮 Agentic pre-merge checks are now available in preview!Pro plan users can now enable pre-merge checks in their settings to enforce checklists before merging PRs.
Please see the documentation for more information. Example: reviews:
pre_merge_checks:
custom_checks:
- name: "Undocumented Breaking Changes"
mode: "warning"
instructions: |
Pass/fail criteria: All breaking changes to public APIs, CLI flags, environment variables, configuration keys, database schemas, or HTTP/GraphQL endpoints must be documented in the "Breaking Change" section of the PR description and in CHANGELOG.md. Exclude purely internal or private changes (e.g., code not exported from package entry points or explicitly marked as internal).Please share your feedback with us on this Discord post. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Summary of Changes
Hello @EmilyyyLiu, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
此拉取请求旨在优化文档部署流程。它通过将 docs:deploy 命令的部署路径从旧的 .doc 目录更新为新的 dist 目录来实现这一目标。同时,为了保持仓库的整洁并避免提交生成的文件,dist 目录也被添加到了 .gitignore 中。这些更改共同简化了文档的发布工作流。
Highlights
- 部署路径变更: 将
docs:deploy命令的部署源目录从.doc更改为dist。 - Git 忽略文件更新: 在
.gitignore文件中添加了dist目录,以确保构建输出文件不会被版本控制系统跟踪。
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in pull request comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
本次 PR 修改了文档的部署路径,将 docs:deploy 命令的目标目录从 .doc 改为 dist,并相应地将 dist 目录添加到了 .gitignore 中。这些改动是正确的,使项目配置与 dumi 的默认行为保持一致。
我只在 .gitignore 文件中发现了一个可以改进的小地方,建议为目录条目添加斜杠以提高清晰度。总体来说,这是一个不错的清理和标准化改动。
| package-lock.json | ||
| .doc/ | ||
|
|
||
| dist |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #200 +/- ##
=======================================
Coverage 96.95% 96.95%
=======================================
Files 4 4
Lines 164 164
Branches 54 54
=======================================
Hits 159 159
Misses 5 5 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (2)
.gitignore (1)
30-30: 忽略 dist 没问题;建议使用目录形式以与现有规则更一致。当前文件中既有
build/lib/es(无斜杠)也有.doc/(带斜杠)。为清晰起见,推荐改为目录形式:-dist +dist/可选:同时清理
.doc/与.doc的重复规则,统一成一种风格,减少维护成本。package.json (1)
31-31: 确认 dumi 输出目录并建议在部署脚本中加入构建dumi 2.x 默认输出目录为 dist;可在 .dumi.ts / .umirc.ts 等配置中用 outputPath 自定义。若项目未自定义 outputPath,则将 docs:deploy 指向 dist 合理。建议改为:
- "docs:deploy": "gh-pages -d dist", + "docs:deploy": "dumi build && gh-pages -d dist", - "postpublish": "npm run docs:build && npm run docs:deploy", + "postpublish": "npm run docs:deploy",若仍希望职责分离,请在 CI 中确保先执行 docs:build 再 docs:deploy,以避免 dist 缺失导致发布失败。
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
.gitignore(1 hunks)package.json(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Socket Security: Pull Request Alerts
修改 docs:deploy 命令执行路径为dist
增加dist 文件到.gitignore
Summary by CodeRabbit