Skip to content

Commit c3f0017

Browse files
collinfunkjnavila
authored andcommitted
completion: Make sed command that generates config-list.h portable.
The OpenBSD 'sed' command does not support '\n' to represent newlines in sed expressions. This leads to the follow compiler error: In file included from builtin/help.c:15: ./config-list.h:282:18: error: use of undeclared identifier 'n' "gitcvs.dbUser",n "gitcvs.dbPass", ^ 1 error generated. gmake: *** [Makefile:2821: builtin/help.o] Error 1 We can use a backslash followed by a newline to fix this. This portably issue was introduced in e1b81f5 (completion: take into account the formatting backticks for options, 2025-03-19) Signed-off-by: Collin Funk <[email protected]>
1 parent b32feae commit c3f0017

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

generate-configlist.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ EOF
1919
s/::$//;
2020
s/`//g;
2121
s/^.*$/ "&",/;
22-
s/, */",\n "/g;
22+
s/, */",\
23+
"/g;
2324
p;};
2425
d' \
2526
"$SOURCE_DIR"/Documentation/*config.adoc \

0 commit comments

Comments
 (0)