conan.tools.files.symlinks
conan.tools.files.symlinks.absolute_to_relative_symlinks()
- absolute_to_relative_symlinks(conanfile, base_folder)
Convert the symlinks with absolute paths into relative ones if they are pointing to a file or directory inside the
base_folder. Any absolute symlink pointing outside thebase_folderwill be ignored.- 參數:
conanfile – 目前的配方物件。一律使用
self。base_folder – Folder to be scanned.
conan.tools.files.symlinks.remove_external_symlinks()
- remove_external_symlinks(conanfile, base_folder)
Remove the symlinks to files that point outside the
base_folder, no matter if relative or absolute.- 參數:
conanfile – 目前的配方物件。一律使用
self。base_folder – Folder to be scanned.
conan.tools.files.symlinks.remove_broken_symlinks()
- remove_broken_symlinks(conanfile, base_folder=None)
Remove the broken symlinks, no matter if relative or absolute.
- 參數:
conanfile – 目前的配方物件。一律使用
self。base_folder – Folder to be scanned.