-
Notifications
You must be signed in to change notification settings - Fork 4
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
Support escaping commas in extra flags #443
Conversation
save-common/src/commonMain/kotlin/com/saveourtool/save/core/plugin/ExtraFlagsExtractor.kt
Fixed
Show fixed
Hide fixed
save-common/src/commonMain/kotlin/com/saveourtool/save/core/plugin/ExtraFlagsExtractor.kt
Fixed
Show fixed
Hide fixed
save-common/src/commonMain/kotlin/com/saveourtool/save/core/plugin/ExtraFlagsExtractor.kt
Fixed
Show fixed
Hide fixed
save-common/src/commonMain/kotlin/com/saveourtool/save/core/plugin/ExtraFlagsExtractor.kt
Fixed
Show fixed
Hide fixed
save-common/src/commonMain/kotlin/com/saveourtool/save/core/plugin/ExtraFlagsExtractor.kt
Fixed
Show fixed
Hide fixed
save-common/src/commonMain/kotlin/com/saveourtool/save/core/plugin/ExtraFlagsExtractor.kt
Fixed
Show fixed
Hide fixed
save-common/src/commonNonJsTest/kotlin/com/saveourtool/save/core/ExtraFlagsExtractorTest.kt
Fixed
Show fixed
Hide fixed
save-common/src/commonNonJsTest/kotlin/com/saveourtool/save/core/ExtraFlagsExtractorTest.kt
Fixed
Show fixed
Hide fixed
save-common/src/commonNonJsTest/kotlin/com/saveourtool/save/core/ExtraFlagsExtractorTest.kt
Fixed
Show fixed
Hide fixed
Codecov Report
@@ Coverage Diff @@
## main #443 +/- ##
============================================
+ Coverage 46.61% 47.00% +0.38%
Complexity 150 150
============================================
Files 53 53
Lines 1772 1785 +13
Branches 331 332 +1
============================================
+ Hits 826 839 +13
Misses 814 814
Partials 132 132
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
@@ -29,7 +29,8 @@ class ExtraFlagsExtractor(private val generalConfig: GeneralConfig, | |||
* @return [ExtraFlags] or null if no match occurred | |||
*/ | |||
internal fun extractExtraFlagsFrom(line: String) = line | |||
.split(",", ", ") | |||
.splitByNonEscaped(',') | |||
.map { it.replace("\\,", ",") } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
case with escaping of a single slash won't work here:
aaa\\,bbb\\,
-> usually it is converted to aaa\,bbb\,
No description provided.