Pugs::Doc::Run

Pugs::Doc::Run is a tutorial about how to run pugs.
Download

Pugs::Doc::Run Ranking & Summary

Advertisement

  • Rating:
  • License:
  • GPL
  • Price:
  • FREE
  • Publisher Name:
  • Pugs::Doc::Run Team
  • Publisher web site:
  • http://search.cpan.org/~audreyt/Perl6-Pugs-6.2.13/docs/Pugs/Doc/Run.pod

Pugs::Doc::Run Tags


Pugs::Doc::Run Description

Pugs::Doc::Run is a tutorial about how to run pugs. Pugs::Doc::Run is a tutorial about how to run pugs.SYNOPSYSpugs ] ] ] ] ] The normal way to run a Perl program is by making it directly executable, or else by passing the name of the source file as an argument on the command line. An interactive Pugs environment is also available when pugs is started with no program source. Upon startup, Pugs looks for your program in one of the following places:WRITEMECommand line optionsYou can pass various command line options to Pugs.-e programcauses Pugs to not look for any program files in the command line options, but instead run the one-line program specified. Multiple -e commands work too.-ncauses Pugs to assume the following loop around your program, which makes it iterate over filename arguments somewhat like sed -n or awk: while = { ...your program here... }-pcauses Pugs to assume the following loop around your program, which makes it iterate over filename arguments somewhat like sed: while = { ...your program here... say; }-ccauses Pugs to not run the program, but merely check its syntax.Note that BEGIN {...} and CHECK {...} blocks, as well as use Module, are still executed, because these might change the grammar or create new operators, etc. So the following is not safe: pugs -c 'BEGIN { system "evil command" }'If you want to run a potentially unsafe program safely, see the safemode Pugs provides.-Bbackendcauses Pugs to execute the program using backend. Currently, valid backends are PIR (execution via Parrot), JS (JavaScript), and Pugs.To start the interactive shell of a backend, run pugs -Bbackend, but note that currently only the Perl 5 and JavaScript backends provide interactive shells.The normal runcore supports more features than the other runcores, the Parrot backend is quite fast, the JavaScript backend is good on binding and references, and Perl 6 on Perl 5 offers excellent support for laziness.-Cbackendcauses Pugs to compile the program using backend. Currently, valid backends are Pugs, PIR, GHC, JS, and various variants of PIL: PIL1, PIL1-Binary, PIL1-JSON, PIL1-Perl5 (and PIL2-...).Note that, as with -c, BEGIN {...} and CHECK {...} blocks, as well as use Module statements, are still executed. So don't try to compile potentially unsafe code!-Mmodulecauses Pugs to load module before executing your program: use module; ...your code here...-h or --helpdisplays a short summary of the available command line options. No programs are executed.-Vdisplays the version of Pugs you're running and long configuration information.-V:itemdisplays short configuration information for item. $ pugs -V:pugs_versnum pugs_versnum: 6.2.6-v or --versiondisplays the version of Pugs you're running.-l, -d, and -ware ignored for compatibility with Perl 5. Requirements: · Perl


Pugs::Doc::Run Related Software