Skip to content

Latest commit

 

History

History
17 lines (10 loc) · 524 Bytes

Copy_stdin_to_stdout.md

File metadata and controls

17 lines (10 loc) · 524 Bytes

When invoked at a command line: Slightly less magical than Perl / sed. The p flag means automatically print each line of output to STDOUT. The e flag means execute what follows inside quotes. ".lines" reads lines from the assigned pipe (file handle), STDIN by default.

raku -pe'.lines'

When invoked from a file: Lines are auto-chomped, so need to re-add newlines (hence .say rather than .print)

.say for lines