Skip to content

Commit ba6e905

Browse files
fix: use \\r in qmake $$replace() to correctly strip Windows CR
Single \r in a qmake .pro file is interpreted as literal backslash+'r', not a carriage-return. Use \\r so the regex engine receives \r (CR). Agent-Logs-Url: https://github.com/MaximumTrainer/MaximumTrainer_Redux/sessions/bd8f8b60-4c5b-4989-82e6-678bf7100764 Co-authored-by: MaximumTrainer <1376575+MaximumTrainer@users.noreply.github.com>
1 parent 6038297 commit ba6e905

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

PowerVelo.pro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
GIT_VERSION = $$system(git describe --tags --match "v[0-9]*" --always)
99
# Strip any trailing carriage-return that qmake's $$system() may capture on
1010
# Windows when git writes "\r\n" to stdout.
11-
GIT_VERSION = $$replace(GIT_VERSION, \r, )
11+
GIT_VERSION = $$replace(GIT_VERSION, \\r, )
1212
# If this is not an exact tag commit, git describe appends "-N-gHASH" to the
1313
# nearest tag (e.g. "v0.0.53-3-gabcdef1"). Strip that suffix so APP_VERSION
1414
# is always a clean "vX.Y.Z" string; the extra commits are intentionally

0 commit comments

Comments
 (0)