chore: normalize opencode naming to lowercase across codebase#25
chore: normalize opencode naming to lowercase across codebase#25
Conversation
Summary of ChangesHello @iHildy, 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! This pull request focuses on a comprehensive refactoring effort to standardize the naming convention of 'OpenCode' to 'opencode' throughout the entire project. This change aims to eliminate inconsistencies, improve readability, and reduce potential confusion for both users and developers by ensuring a uniform casing across documentation, environment variables, and core code identifiers. Highlights
Ignored Files
Using Gemini Code AssistThe 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
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 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
|
There was a problem hiding this comment.
Code Review
This pull request does a great job of standardizing the naming from "OpenCode" to "opencode" throughout the project, which significantly improves consistency. The changes are extensive but well-executed. I've left a couple of suggestions to address minor inconsistencies in the new environment variable naming scheme and to improve the clarity of the documentation.
| const serverToken = toEnvToken(serverName, 'SERVER'); | ||
| const keyToken = toEnvToken(key, 'VALUE'); | ||
| return `OPENCODE_MCP_${serverToken}_${keyToken}`; | ||
| return `opencode_mcp_${serverToken}_${keyToken}`; |
There was a problem hiding this comment.
This generates a mixed-case environment variable (e.g., opencode_mcp_GITHUB_AUTHORIZATION), which is inconsistent with other variables in this PR that are fully lowercase (e.g., opencode_config_dir). For better consistency across all environment variables, consider converting the entire generated variable to lowercase. Note that this would also require updating the corresponding test expectations.
| return `opencode_mcp_${serverToken}_${keyToken}`; | |
| return `opencode_mcp_${serverToken}_${keyToken}`.toLowerCase(); |
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
This pull request standardizes the naming conventions across the codebase and documentation by replacing all instances of "OpenCode" and related uppercase environment variables with the lowercase "opencode" equivalents. This change ensures consistency and clarity for users and developers. It also updates plugin and package identifiers to match the new naming scheme.
Naming convention and documentation updates:
Replaced all references to "OpenCode" with "opencode" in user-facing documentation, including
README.md,AGENTS.md,CHANGELOG.md, and command descriptions. This includes config paths, plugin names, and usage instructions. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] [14]Updated all environment variable names from uppercase (e.g.,
OPENCODE_HOME,OPENCODE_SMOKE_TIMEOUT) to lowercase (e.g.,opencode_home,opencode_smoke_timeout) in the GitHub Actions workflow, tests, and code. [1] [2] [3] [4] [5] [6] [7] [8]Code and identifier updates:
Renamed the main plugin export from
OpencodeConfigSync/OpencodeSyncedtoopencodeConfigSync/opencodeSyncedinsrc/index.ts, and updated all related descriptions and references. [1] [2]Updated commit message generation and prompts in
src/sync/commit.tsto refer to "opencode config sync" instead of "OpenCode config sync". [1] [2]Other minor improvements:
package.jsonand.mise/tasks/local-pack-testto match the new naming and improve readability. [1] [2] [3] [4]These changes collectively improve consistency and reduce confusion for both users and contributors.