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 pathconv issues related to relative paths in path lists #213

Commits on Jul 2, 2024

  1. fixup! Add functionality for converting UNIX paths in arguments and e…

    …nvironment variables to Windows form for native Win32 applications.
    
    When we fixed MSYS2's automatic Unix <-> Windows path conversion to
    identify and skip Git-style `<rev>:<path>` arguments (and incidentally
    also scp-style `<host>:<path>` ones), we assumed that path lists
    containing relative paths would be a rare scenario.
    
    My, was this assumption wrong!
    
    Let's add another heuristic that detects absolute paths at the beginning
    of path lists, and relative ones starting with either `./` or `../`,
    neither of which match those Git-style nor scp-style arguments, and then
    prevent the detection of the latter style from kicking in.
    
    This addresses msys2#208
    
    Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
    dscho authored and ReinhardBiegelIntech committed Jul 2, 2024
    Configuration menu
    Copy the full SHA
    8ef78d5 View commit details
    Browse the repository at this point in the history
  2. pathconv: Also skip git/scp path list conversion for environment vari…

    …ables assigned on command line
    
    This restores parts of the previous behavior of path_conv, fixing an
    issue where the paths of the path list in `VARIABLE=.:../foo/bar
    ./my-script.sh` weren't convertet to windows paths. The path conversion
    was skipped due to interpretation as a Git style reference. The Git
    detection is now excluded for this kind of variable assignments.
    ReinhardBiegelIntech committed Jul 2, 2024
    Configuration menu
    Copy the full SHA
    222fa6e View commit details
    Browse the repository at this point in the history
  3. pathconv: Check for end of input when determining potential path list

    Suggested-by: Richard Copley <buster@buster.me.uk>
    ReinhardBiegelIntech committed Jul 2, 2024
    Configuration menu
    Copy the full SHA
    a907109 View commit details
    Browse the repository at this point in the history