Skip to content

canonicalize file path before check excluding #569

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

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

tinyleolin
Copy link
Contributor

Fix #551

@CppCXY CppCXY marked this pull request as draft July 2, 2025 06:57
@CppCXY
Copy link
Member

CppCXY commented Jul 2, 2025

  1. 处理方式欠妥, 重新考虑.
  2. 不要定义函数内的函数, 如果你不捕获任何东西

@tinyleolin
Copy link
Contributor Author

对第一点有什么建议吗

@CppCXY
Copy link
Member

CppCXY commented Jul 2, 2025

不要支持相对路径

@tinyleolin
Copy link
Contributor Author

通常项目配置都是以相对路径方式配置的吧,除非是引用的第三方库,你的最佳实践是什么呢

@CppCXY
Copy link
Member

CppCXY commented Jul 2, 2025

默认情况下, 整个路径是相对于主工作区的, 我反对的是在路径中使用 ...
rust的canonicalize 并非简单的绝对路径化: 在 Windows 上,这会将路径转换为使用扩展长度路径语法.这一点可能会影响包路径的分析.

另外如果如果相关文件在工作区外面, 那么应该使用绝对路径指向它而不是使用 .., 如果项目使用统一配置, 那么应该使用环境变量指向它, 并在配置中使用环境变量

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 this pull request may close these issues.

support '..' in ignoreDir
2 participants