[2.x] fix: Fixes the handling of special characters in dot files#8558
Merged
eed3si9n merged 7 commits intosbt:developfrom Jan 19, 2026
Merged
Conversation
Author
|
@eed3si9n Could you please review my first pr? |
Member
af42b81 to
dd4d822
Compare
Author
@eed3si9n I have added test. Please review again... |
Author
|
@eed3si9n Could you please give me tip to fix this issue? I used this command to test. |
eed3si9n
reviewed
Jan 16, 2026
launcher-package/integration-test/src/test/scala/RunnerScriptTest.scala
Outdated
Show resolved
Hide resolved
53616e8 to
6371194
Compare
6371194 to
c4fef52
Compare
Author
|
@eed3si9n I have fixed, could you please test again? |
- Replace 'eval echo $line' with 'printf "%s\n" "$line"' in loadConfigFile() - Prevents shell expansion of special characters like |, *, &, etc. - Fixes issue where properties with pipes, wildcards, and ampersands caused 'command not found' or 'unexpected' errors - Add test to verify special characters are handled correctly on all platforms - All special characters are now handled literally as expected
64fd732 to
459602b
Compare
eed3si9n
requested changes
Jan 19, 2026
launcher-package/integration-test/src/test/scala/RunnerScriptTest.scala
Outdated
Show resolved
Hide resolved
Author
|
@eed3si9n Could you please take a look again? |
eed3si9n
reviewed
Jan 19, 2026
eed3si9n
pushed a commit
to eed3si9n/sbt
that referenced
this pull request
Feb 7, 2026
…#8558) - Replace 'eval echo $line' with 'printf "%s\n" "$line"' in loadConfigFile() - Prevents shell expansion of special characters like |, *, &, etc. - Fixes issue where properties with pipes, wildcards, and ampersands caused 'command not found' or 'unexpected' errors - Add test to verify special characters are handled correctly on all platforms
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.

Handle special characters in config files safely
Replaces
eval echo $linewithprintf '%s\n' "$line"inloadConfigFile()to prevent shell expansion of special characters like|,*,&in.jvmoptsand.sbtoptsfiles.Problem:
Properties with pipes (e.g.,
-Dhttp.nonProxyHosts=host1|host2) caused "command not found" errors due to shell expansion.Solution:
Use
printfwith quoted variable to output lines literally without shell interpretation.Testing:
✅ Verified with pipes, wildcards, ampersands - all handled correctly
Fixes #7289
Contribution by Gittensor, see my contribution statistics at https://gittensor.io/miners/details?githubId=5625555