fix(install): verify_install 优先校验实际安装路径 - #27
Open
ntxf31415 wants to merge 1 commit into
Open
Conversation
自定义 WPS365_INSTALL_DIR 安装时,若 PATH 已存在旧版本二进制, command -v 会返回旧路径,导致最终提示与实际安装目录不符(wps365-open#8)。 先校验 ${INSTALL_DIR}/${BINARY_NAME},再 fallback 到 command -v。
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.
摘要
install.sh在自定义WPS365_INSTALL_DIR时,最终校验用command -v wps365-cli判断安装结果:如果 PATH 里已存在旧版本,会优先返回旧路径,导致「明明装到了自定义目录,最后却提示装到了旧路径」的误导(见 #8)。变更
verify_install()改为:${INSTALL_DIR}/${BINARY_NAME}是否存在且可执行 → 报告实际安装路径;command -v;验证
Closes #8