Last active
July 7, 2019 16:37
-
-
Save nd3i/80e5da536fa73bb14a42371d32ce7dc7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use v6; | |
sub MAIN (*@files, :$fmt='%d', :$sep=': ') { | |
my $nl = 1; | |
@files = '-' unless @files; | |
for @files>>.IO -> $f { | |
$nl = 1; | |
for $f.lines -> $line { | |
say join($sep, $f.basename, $nl.fmt($fmt), $line); | |
++$nl; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment