fix: improve parsing of escaped symbols inside string

This commit is contained in:
arcanis committed 2026-10-30 16:16:50 +02:00
1 parent c56a319267
commit 5ad8a2a7d0
3 files changed
+68 -36

No files matched your search

+12
View File
@@ -113,3 +113,15 @@ pkgver() {
_ver="$(cat CMakeLists.txt | grep -e SO_MAJOR_VERSION -e SO_MINOR_VERSION -e SO_BUILD_VERSION | cut -d '"' -f2 | head -n3)"
echo "$(echo ${_ver} | tr ' ' .).r$(git rev-list --count HEAD).$(git rev-parse --short HEAD)"
}
# escapes and newlines inside double-quoted assignments
var="say \"hello\""
var="a\\b"
var="\$name"
var="\`date\`"
var="first\
second"
var="a\qb"
var="\\\\$name"
var="first
second"