pugs - Perl6 User's Golfing System
pugs [OPTIONS]
perl -e 'use pugs; # perl 6 code here...'
This manual describes Pugs, an experimental (but useful) implementation of the Perl6 language.
Perl is a language optimized for scanning arbitrary text files, extracting information from those text files, and printing reports based on that information. It's also a good language for many system management tasks. The language is intended to be practical (easy to use, efficient, complete) rather than beautiful (tiny, elegant, minimal).
If you're new to Pugs, you should start with pugs::intro (yet to be written), which is a general intro for beginners and provides some background to help you navigate the rest of Perl's extensive documentation.
(pugs is also a Perl5 pragma for using Perl6 code inline. See "The pugs pragma" below.)
For ease of access, the Pugs manual has been split up into several sections. Those marked with an asterix haven't been written yet.
pugs Perl overview (this section) pugs::intro * Perl introduction for beginners pugs::toc * Perl documentation table of contents
pugs::run Perl execution and options * (many others)
pugs::hack An overview of the Pugs source tree
You should be able to view Perl's documentation with your man(1) program or perldoc(1).
[This section describes a Perl 5 pragma named pugs. Hopefully this is not too confusing.]
#!/usr/bin/perl use pugs; # Here is some Perl 6 code... sub postfix:<!> { [*] 1..$_ } sub sum_factorial { [+] 0..$_! } no pugs; # Here is some Perl 5 code... print sum_factorial(3); # 21
The (Perl 5) pugs module lets you put Perl 6 code in Perl 5 source code after a line of:
use pugs;
To switch back to Perl 5:
no pugs;
See also Perl6::Pugs. The pugs pragma was written by Brian Ingerson <INGY@cpan.org> .
<INGY@cpan.org>
Pugs is available for most operating systems to which GHC has been ported, including many Unix-like platforms as well as (with several limitations) Windows. See "Supported Platforms" in perl::port for a listing (to be written), and the README file in the source distribution.
See pugs::run.
Perl was conceived and nurtured by Larry Wall <larry@wall.org>.
<larry@wall.org>
Pugs was written by Autrijus Tang <autrijus@autrijus.org>, with the help of oodles of other folks; see the AUTHORS file.
<autrijus@autrijus.org>
Pugs is still under heavy development. If you find a bug, please report it (with a test case, if possible -- see t/README) on #perl6 on irc.freenode.org.
#perl6
irc.freenode.org
To install Perl6::Pugs, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Perl6::Pugs
CPAN shell
perl -MCPAN -e shell install Perl6::Pugs
For more information on module installation, please visit the detailed CPAN module installation guide.