| 1 |
Created on: Thu 10 Dec 2009 10:32:58 PM |
| 2 |
Last saved: Tue 09 Jul 2013 08:51:39 AM |
| 3 |
|
| 4 |
|
| 5 |
+-----------------------------------------------------------+ |
| 6 |
| OS/Platforms supported: ALL | |
| 7 |
+-----------------------------------------------------------+ |
| 8 |
|
| 9 |
This directory contains development efforts for a new and |
| 10 |
improved perldl shell (Perldl2). |
| 11 |
|
| 12 |
You need to install the version 1.003011 of Devel::REPL |
| 13 |
and have installed either Term::ReadLine::Perl or |
| 14 |
Term::ReadLine::Gnu in order to use the new Perldl2 shell |
| 15 |
capabilities. |
| 16 |
|
| 17 |
|
| 18 |
+-----------------------------------------------------------+ |
| 19 |
| CONTENTS | |
| 20 |
+-----------------------------------------------------------+ |
| 21 |
|
| 22 |
README |
| 23 |
This file |
| 24 |
|
| 25 |
TODO |
| 26 |
Development list for Perldl2 shell |
| 27 |
|
| 28 |
Makefile.PL |
| 29 |
Perl configuration/build script for Perldl2 |
| 30 |
|
| 31 |
Plugin/ |
| 32 |
Profile/ |
| 33 |
Script.pm |
| 34 |
Perl modules and directories with modules for Perldl2 |
| 35 |
|
| 36 |
pdl2 |
| 37 |
A perl script for starting the Perldl2 shell. |
| 38 |
(Falls back to the original perldl if either Devel::REPL |
| 39 |
or neither Term::ReadLine::Gnu nor Term::ReadLine::Perl |
| 40 |
are installed.) |
| 41 |
|
| 42 |
|
| 43 |
+-----------------------------------------------------------+ |
| 44 |
| INSTALLATION | |
| 45 |
+-----------------------------------------------------------+ |
| 46 |
|
| 47 |
By default, the Perldl2 shell is always built and the |
| 48 |
pdl2 script installed. |
| 49 |
|
| 50 |
You will need to install Devel::REPL version 1.003011 |
| 51 |
or greater and either of Term::ReadLine::Gnu or |
| 52 |
Term::ReadLine::Perl to access the new pdl2 capabilities. |
| 53 |
|
| 54 |
|
| 55 |
+-----------------------------------------------------------+ |
| 56 |
| USE | |
| 57 |
+-----------------------------------------------------------+ |
| 58 |
|
| 59 |
To use the Perldl2 shell, from the PDL build directory |
| 60 |
run the following: |
| 61 |
|
| 62 |
perl -Mblib Perldl2/pdl2 |
| 63 |
|
| 64 |
If you have installed the just built PDL, you should |
| 65 |
be able to run: |
| 66 |
|
| 67 |
pdl2 |
| 68 |
|
| 69 |
To exit the Perldl2 shell from the 'pdl> ' prompt, type |
| 70 |
Ctrl-D or quit, (q, x, and exit shortcuts are also |
| 71 |
available). If Devel::REPL is not installed (or you |
| 72 |
don't have either TR::Gnu or TR::Perl), pdl2 will use |
| 73 |
perldl instead but the new Perldl2 features will not |
| 74 |
be available. |
| 75 |
|
| 76 |
The idea is that one just uses pdl2 where you used to |
| 77 |
use perldl. At some point, the development will be |
| 78 |
complete and there will be only one PDL shell. |
| 79 |
|
| 80 |
|
| 81 |
+-----------------------------------------------------------+ |
| 82 |
| NOTES | |
| 83 |
+-----------------------------------------------------------+ |
| 84 |
|
| 85 |
Supported functionality from Devel::REPL and PDL: |
| 86 |
* DDS (pretty prints output using Data::Dump::Streamer) |
| 87 |
* History (redo commands with !-1 and !<num> syntax) |
| 88 |
* Interrupt (interrupt with Ctrl-C; not on MSWin32) |
| 89 |
* LexEnv (e.g., my $x = zeros(10) works) |
| 90 |
* MultiLine::PPI (handles multiline input like perldl) |
| 91 |
* NiceSlice (PDL::NiceSlice works too!) |
| 92 |
* Packages (keeps track of current user package) |
| 93 |
* PDLCommands (perldl shell v1 convenience routines) |
| 94 |
* ReadLineHistory |
| 95 |
* Save and restore command history to file |
| 96 |
* CompletionDrivers |
| 97 |
* Globals (completion for globals) |
| 98 |
* INC (completion for use module::name) |
| 99 |
* Keywords (completion for perl keywords) |
| 100 |
* LexEnv (completion for lexical vars) |
| 101 |
* Methods (completion of method names) |
| 102 |
|
| 103 |
Default PDL modules loaded: |
| 104 |
* PDL |
| 105 |
* PDL::Dbg |
| 106 |
* PDL::Doc::Perldl |
| 107 |
* PDL::IO::Dumper |
| 108 |
* PDL::IO::FlexRaw |
| 109 |
* PDL::IO::Pic |
| 110 |
* PDL::Image2D |
| 111 |
* PDL::AutoLoader |
| 112 |
|
| 113 |
? and ?? are aliases for help and apropos |
| 114 |
|
| 115 |
Arguments to help|usage|apropos|sig|badinfo|demo are autoquoted |
| 116 |
|
| 117 |
Shell escapes start with $PERLDL::ESCAPE as the first character |
| 118 |
of a line ('#' by default). |
| 119 |
|
| 120 |
l <num> prints the last <num> lines of history, default 20. |
| 121 |
|
| 122 |
p prints the following args separated by space (i.e., $,=' ') |
| 123 |
|
| 124 |
demo as a command by itself lists the possible demos available. |
| 125 |
Otherwise it runs the specified demo. |
| 126 |
|
| 127 |
By default, leading patterns matching the pdl2 shell |
| 128 |
prompt ('pdl> ' with possible surrounding white space) |
| 129 |
are stripped from the input. That allows for easy |
| 130 |
cut-and-paste of pdl2 sessions from examples, demos, |
| 131 |
or docs. |
| 132 |
|
| 133 |
The Perldl2 shell, pdl2, loads/saves from the same history |
| 134 |
file as perldl. |
| 135 |
|
| 136 |
The Perldl2 shell, pdl2, loads your .perldlrc file |
| 137 |
from the same location as the perldl shell does. It also |
| 138 |
accepts .pdlrc as the name---looking forward to the new |
| 139 |
naming scheme for the interactive shell. A local.pdlrc |
| 140 |
or local.perldlrc are run if present as well. |