docs(common/virtual-env): pass board prop to template, fallback to 'device'#1868
Merged
Milir-Radxa merged 1 commit intoJun 23, 2026
Conversation
…evice' Switch common virtual-env templates (_conda_install, _docker_use, _conda_use) from hardcoded radxa@device$ to props?.board with 'device' fallback, matching the ROS2 install template pattern. Wrappers that already pass board="..." will render the per-board prompt; wrappers that do not pass board fall back to radxa@device$ with no behavior change. Mirror changes in i18n/en.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
将
common/radxa-os/application-dev/virtual-env/下三个公共模板文件 (_conda_install.mdx、_docker_use.mdx、_conda_use.mdx) 的代码块<NewCodeBlock tip=...>从硬编码radxa@device$切换为tip={radxa@${props?.board ?? 'device'}$},与ros-dev/ros2-dev/_install.mdx、ros-dev/ros1-dev/_install.mdx已有的传参模式保持一致。board="<board-id>"的产品 → 终端提示会渲染成radxa@<board-id>$board的 wrapper → 仍然回退到radxa@device$,行为不变中英文同步。
Files
docs/common/radxa-os/application-dev/virtual-env/_conda_install.mdxdocs/common/radxa-os/application-dev/virtual-env/_docker_use.mdxdocs/common/radxa-os/application-dev/virtual-env/_conda_use.mdxi18n/en/.../virtual-env/_conda_install.mdxi18n/en/.../virtual-env/_docker_use.mdxi18n/en/.../virtual-env/_conda_use.mdxContext
后续会有一个独立的 PR 给 Dragon Q8B 增加 Docker / Conda 虚拟环境教程,那批 wrapper 会传入
board="dragon-q8b";本次先把模板层的传参能力补齐。不修改任何 wrapper 文件。