Merged
Conversation
If a path would include $, it was getting expanded during the evaluation. Reported by Fabian Thorand
SingingTree
added a commit
to SingingTree/direnv
that referenced
this pull request
Apr 8, 2023
direnv#975 had the unintended consequence of causing the `RC::Load` call to sometimes fail when running under git-bash (and some others Windows specific configs). The `RC::Load` -> `cmd.Output()` calls end up interpreting characters like \b or \t as escape sequences, which is problematic if for paths like 'myProject\buckets\test'. This patch addresses this by forcing the use of `/` as a separator, even on Windows. This works fine in my testing in git-bash. This shouldn't impact systems where `/` is already in use. This also adds a test case that covers the behaviour being adjusted. In order to run the bash tests on Windows, I had to disabled a number that appear to not play nice -- but after hacking those out I was able to verify the new test case. Fixes: - direnv#1020 - direnv#1079
zimbatm
pushed a commit
to SingingTree/direnv
that referenced
this pull request
May 19, 2023
direnv#975 had the unintended consequence of causing the `RC::Load` call to sometimes fail when running under git-bash (and some others Windows specific configs). The `RC::Load` -> `cmd.Output()` calls end up interpreting characters like \b or \t as escape sequences, which is problematic if for paths like 'myProject\buckets\test'. This patch addresses this by forcing the use of `/` as a separator, even on Windows. This works fine in my testing in git-bash. This shouldn't impact systems where `/` is already in use. This also adds a test case that covers the behaviour being adjusted. In order to run the bash tests on Windows, I had to disabled a number that appear to not play nice -- but after hacking those out I was able to verify the new test case. Fixes: - direnv#1020 - direnv#1079
zimbatm
pushed a commit
that referenced
this pull request
May 20, 2023
#975 had the unintended consequence of causing the `RC::Load` call to sometimes fail when running under git-bash (and some others Windows specific configs). The `RC::Load` -> `cmd.Output()` calls end up interpreting characters like \b or \t as escape sequences, which is problematic if for paths like 'myProject\buckets\test'. This patch addresses this by forcing the use of `/` as a separator, even on Windows. This works fine in my testing in git-bash. This shouldn't impact systems where `/` is already in use. This also adds a test case that covers the behaviour being adjusted. In order to run the bash tests on Windows, I had to disabled a number that appear to not play nice -- but after hacking those out I was able to verify the new test case. Fixes: - #1020 - #1079
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.
If a path would include $, it was getting expanded during the
evaluation.
Reported by Fabian Thorand