Skip to content

tests: generate CRLF and test data portably - #187

Open
kulikjak wants to merge 1 commit into
twaugh:masterfrom
kulikjak:tests-portable-printf
Open

kulikjak wants to merge 1 commit into
twaugh:masterfrom
kulikjak:tests-portable-printf

Conversation

@kulikjak

Copy link
Copy Markdown

Two more minor things related to prints.

First is more portable way of printing CRLF - this does similar thing like 76cde5f, but with \r rather than \t.

The second part is replacement of /usr/bin/echo -ne and the '%b' addition for printf. All other echo -ne calls were removed already. And I added the %b because the string otherwise begins with --- which printf can interpret as an option. I first encountered this on Solaris, but I can also reproduce it on MacOS when /usr/bin/printf is used.

> /usr/bin/printf "\
--- a/file1\n"
/usr/bin/printf: illegal option -- -
usage: printf format [arguments ...]

Signed-off-by: Jakub Kulik <jakub.kulik@oracle.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant