On Sat, May 16, 2020 at 01:29:12PM +0200, Laurent Rosenfeld via perl6-users wrote: > Hi, > > it should be: > > $ raku *-e* "your one-liner script here"
And also you might want to put some quotes around the paths to let Raku know that those are strings and not some identifiers or something. G'luck, Peter > Le sam. 16 mai 2020 à 12:16, ToddAndMargo via perl6-users < > perl6-users@perl.org> a écrit : > > > On 2020-05-15 22:30, ToddAndMargo via perl6-users wrote: > > > Hi All,. > > > > > > Windows 7, sp1, x64 > > > > > > >raku -v > > > This is Rakudo version 2020.01 built on MoarVM version > > > 2020.01.1 implementing Perl 6.d. > > > > > > > > > I am trying to get perl to tell me if a drive letter exists > > > > > > This is from Git's df command: > > > > > > >df -kPT H:\ > > > Filesystem Type 1024-blocks Used Available Capacity Mounted on > > > H: ntfs 38908 9964 28944 26% /h > > > > > > So, H:\ is there > > > > > > >raku "say H:\.IO.e" > > > Could not open say H:\.IO.e. Failed to stat file: no such file or > > directory > > > > > > And in case I need \\ > > > > > > >raku "say H:\\.IO.e" > > > Could not open say H:\\.IO.e. Failed to stat file: no such file or > > > directory > > > > > > And in case I need a forward slashL: > > > >raku "say H:/.IO.e" > > > Could not open say H:/.IO.e. Failed to stat file: no such file or > > directory > > > > > > What am I doing wrong, this time? > > > > > > -T > > > > > > > > > As far as I can tell IO.e and IO.d is completely trashed > > in Windows: > > > > K:\Windows\NtUtil>dir H: > > Volume in drive H is BACKUP > > Volume Serial Number is 00D0-CAD4 > > > > Directory of H:\ > > > > 05/15/2020 22:21 0 IAmBackup > > 05/15/2020 22:43 <DIR> MyDocsBackup > > 1 File(s) 0 bytes > > 1 Dir(s) 29,638,656 bytes free > > > > > > > > K:\Windows\NtUtil>raku "say 'h://IAmBackup'.IO.e" > > Could not open say 'h://IAmBackup'.IO.e. Failed to stat file: no such > > file or di > > rectory > > > > K:\Windows\NtUtil>raku "say 'h:/IAmBackup'.IO.e" > > Could not open say 'h:/IAmBackup'.IO.e. Failed to stat file: no such > > file or directory > > > > K:\Windows\NtUtil>raku "say 'h:\IAmBackup'.IO.e" > > Could not open say 'h:\IAmBackup'.IO.e. Failed to stat file: no such > > file or directory > > > > K:\Windows\NtUtil>raku "say 'h:\\IAmBackup'.IO.e" > > Could not open say 'h:\\IAmBackup'.IO.e. Failed to stat file: no such > > file or directory > > > > > > And that goes for IO.d too: > > > > K:\Windows\NtUtil>raku "say 'h:\\MyDocsBackup'.IO.d" > > Could not open say 'h:\\MyDocsBackup'.IO.d. Failed to stat file: no such > > file or > > directory > > > > K:\Windows\NtUtil>raku "say 'h:\MyDocsBackup'.IO.d" > > Could not open say 'h:\MyDocsBackup'.IO.d. Failed to stat file: no such > > file or directory > > > > K:\Windows\NtUtil>raku "say 'h:/MyDocsBackup'.IO.d" > > Could not open say 'h:/MyDocsBackup'.IO.d. Failed to stat file: no such > > file or directory > > > > K:\Windows\NtUtil>raku "say 'h://MyDocsBackup'.IO.d" > > Could not open say 'h://MyDocsBackup'.IO.d. Failed to stat file: no such > > file or directory > > > > This gets a TRIPLE: :'( :'( :'( > > > > > > > > And it only works slightly better under Fedora: > > > > $ p6 'say "GetOptLongTest.pl6".IO.e' > > True > > > > $ p6 'say "GetOptLongTest.pl7".IO.e' > > False > > > > $ p6 'say "p6lib".IO.d' > > True > > > > $ p6 'say "p7lib".IO.d' > > Failed to find '/home/linuxutil/p7lib' while trying to do '.d' > > in block <unit> at -e line 1 > > > > Notice that it crashed instead of returning a False. > > > > This gets a single :'( > > > > <editorial comment> AAAAAAHHHHHH!!!! </editorial comment> > > -- Peter Pentchev r...@ringlet.net r...@debian.org p...@storpool.com PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint 2EE7 A7A5 17FC 124C F115 C354 651E EFB0 2527 DF13
signature.asc
Description: PGP signature