Skip to content
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

Fix relative symlinks deep copying #151

Merged
merged 1 commit into from
Jun 15, 2024
Merged

Fix relative symlinks deep copying #151

merged 1 commit into from
Jun 15, 2024

Commits on Jun 6, 2024

  1. Fix relative symlinks copying

    All relative paths of symbolic links should be resolved from the
    directory where the link is located. The current working directory
    does not affect the resolution of the path. A symbolic link can
    be absolute or relative, and may or may not have a leading dot.
    Directory content example:
    file
    symlink -> file
    Copying of the directory with such content does not work currently.
    When copying `symlink`, `Copy` returns an error because the `file`
    does not exist in the current working directory. In the existing
    tests, there is a symbolic link named "symlink" that points to a
    file named "README.md". However, when resolving the path of the
    file, the file is located in the repository's root directory,
    not the test case directory, and copying of these dirs work fine.
    
    The solution is to check whether the resolved path is absolute
    or not. If it is not, append it to the file's directory path.
    psergee committed Jun 6, 2024
    Configuration menu
    Copy the full SHA
    1ddce65 View commit details
    Browse the repository at this point in the history