Since I haven't done this for a long time, let me remind you the
possibility of posting, if you will, your questions _also_ in
StackOverflow. You'll (possibly) get more answers (or just different ones),
and will help spread the word about Perl 6 (which lately has gone back to
the usual regime of one or none questions a day in SO).

El mar., 14 ago. 2018 a las 12:17, Timo Paulssen (<t...@wakelift.de>)
escribió:

> You can just put -I lib on your commandline, but what's more important
> is that you forgot to pass -e, so it was taking your code and
> interpreting it as a filename. It's very unlikely that you have a file
> called 'PrintBlue( "Blue\n" );' in the current directory, though.
>
> perl6 -Ilib -MPrintColors -e 'PrintBlue( "Blue\n");' should do what you
> meant to do.
>
> HTH
>   - Timo
>
>
> On 14/08/18 12:01, ToddAndMargo wrote:
> > Hi All,
> >
> >
> > I presume this is failing as the current directory is not
> > in the "lib" path:
> >
> >
> > $ perl6 -MPrintColors 'PrintBlue( "Blue\n" );'
> > Could not open PrintBlue( "Blue" ). Failed to stat file: no such
> > file or directory
> >
> >
> > This does work, but what a lot of extra work:
> >
> > $ perl6 -e 'use lib "/home/linuxutil"; use PrintColors; PrintBlue(
> > "Blue\n" );'
> > Blue
> >
> >
> >
> > What are the rules for calling modules from the command line?
> >
> >
> > Many thanks,
> > -T
>


-- 
JJ

Reply via email to