⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 cpan.3

📁 视频监控网络部分的协议ddns,的模块的实现代码,请大家大胆指正.
💻 3
📖 第 1 页 / 共 5 页
字号:
.Vb 1\&    cpan> notest install Tk.Ve.SpA \f(CW\*(C`clean\*(C'\fR command results in a.Sp.Vb 1\&  make clean.Ve.Spbeing executed within the distribution file's working directory..ie n .IP """readme""\fR, \f(CW""perldoc""\fR, \f(CW""look"" module or distribution" 2.el .IP "\f(CWreadme\fR, \f(CWperldoc\fR, \f(CWlook\fR module or distribution" 2.IX Item "readme, perldoc, look module or distribution"\&\f(CW\*(C`readme\*(C'\fR displays the \s-1README\s0 file of the associated distribution.\&\f(CW\*(C`Look\*(C'\fR gets and untars (if not yet done) the distribution file,changes to the appropriate directory and opens a subshell process inthat directory. \f(CW\*(C`perldoc\*(C'\fR displays the pod documentation of themodule in html or plain text format..ie n .IP """ls"" author" 2.el .IP "\f(CWls\fR author" 2.IX Item "ls author".PD 0.ie n .IP """ls"" globbing_expression" 2.el .IP "\f(CWls\fR globbing_expression" 2.IX Item "ls globbing_expression".PDThe first form lists all distribution files in and below an author's\&\s-1CPAN\s0 directory as they are stored in the \s-1CHECKUMS\s0 files distributed on\&\s-1CPAN\s0. The listing goes recursive into all subdirectories..SpThe second form allows to limit or expand the output with shellglobbing as in the following examples:.Sp.Vb 3\&      ls JV/make*\&      ls GSAR/*make*\&      ls */*make*.Ve.SpThe last example is very slow and outputs extra progress indicatorsthat break the alignment of the result..SpNote that globbing only lists directories explicitly asked for, forexample FOO/* will not list FOO/bar/Acme\-Sthg\-n.nn.tar.gz. This may beregarded as a bug and may be changed in future versions..ie n .IP """failed""" 2.el .IP "\f(CWfailed\fR" 2.IX Item "failed"The \f(CW\*(C`failed\*(C'\fR command reports all distributions that failed on one of\&\f(CW\*(C`make\*(C'\fR, \f(CW\*(C`test\*(C'\fR or \f(CW\*(C`install\*(C'\fR for some reason in the currentlyrunning shell session..IP "Persistence between sessions" 2.IX Item "Persistence between sessions"If the \f(CW\*(C`YAML\*(C'\fR or the \f(CW\*(C`YAML::Syck\*(C'\fR module is installed a record ofthe internal state of all modules is written to disk after each step.The files contain a signature of the currently running perl versionfor later perusal..SpIf the configurations variable \f(CW\*(C`build_dir_reuse\*(C'\fR is set to a truevalue, then \s-1CPAN\s0.pm reads the collected \s-1YAML\s0 files. If the storedsignature matches the currently running perl the stored state isloaded into memory such that effectively persistence between sessionsis established..ie n .IP "The ""force""\fR and the \f(CW""fforce"" pragma" 2.el .IP "The \f(CWforce\fR and the \f(CWfforce\fR pragma" 2.IX Item "The force and the fforce pragma"To speed things up in complex installation scenarios, \s-1CPAN\s0.pm keepstrack of what it has already done and refuses to do some things asecond time. A \f(CW\*(C`get\*(C'\fR, a \f(CW\*(C`make\*(C'\fR, and an \f(CW\*(C`install\*(C'\fR are not repeated.A \f(CW\*(C`test\*(C'\fR is only repeated if the previous test was unsuccessful. Thediagnostic message when \s-1CPAN\s0.pm refuses to do something a second timeis one of \fIHas already been \fR\f(CW\*(C`unwrapped|made|tested successfully\*(C'\fR orsomething similar. Another situation where \s-1CPAN\s0 refuses to act is an\&\f(CW\*(C`install\*(C'\fR if the according \f(CW\*(C`test\*(C'\fR was not successful..SpIn all these cases, the user can override the goatish behaviour byprepending the command with the word force, for example:.Sp.Vb 4\&  cpan> force get Foo\&  cpan> force make AUTHOR/Bar\-3.14.tar.gz\&  cpan> force test Baz\&  cpan> force install Acme::Meta.Ve.SpEach \fIforced\fR command is executed with the according part of itsmemory erased..SpThe \f(CW\*(C`fforce\*(C'\fR pragma is a variant that emulates a \f(CW\*(C`force get\*(C'\fR whicherases the entire memory followed by the action specified, effectivelyrestarting the whole get/make/test/install procedure from scratch..IP "Lockfile" 2.IX Item "Lockfile"Interactive sessions maintain a lockfile, per default \f(CW\*(C`~/.cpan/.lock\*(C'\fR.Batch jobs can run without a lockfile and do not disturb each other..SpThe shell offers to run in \fIdegraded mode\fR when another process isholding the lockfile. This is an experimental feature that is not yettested very well. This second shell then does not write the historyfile, does not use the metadata file and has a different prompt..IP "Signals" 2.IX Item "Signals"\&\s-1CPAN\s0.pm installs signal handlers for \s-1SIGINT\s0 and \s-1SIGTERM\s0. While you arein the cpan-shell it is intended that you can press \f(CW\*(C`^C\*(C'\fR anytime andreturn to the cpan-shell prompt. A \s-1SIGTERM\s0 will cause the cpan-shellto clean up and leave the shell loop. You can emulate the effect of a\&\s-1SIGTERM\s0 by sending two consecutive SIGINTs, which usually means bypressing \f(CW\*(C`^C\*(C'\fR twice..Sp\&\s-1CPAN\s0.pm ignores a \s-1SIGPIPE\s0. If the user sets \f(CW\*(C`inactivity_timeout\*(C'\fR, a\&\s-1SIGALRM\s0 is used during the run of the \f(CW\*(C`perl Makefile.PL\*(C'\fR or \f(CW\*(C`perlBuild.PL\*(C'\fR subprocess..Sh "CPAN::Shell".IX Subsection "CPAN::Shell"The commands that are available in the shell interface are methods inthe package CPAN::Shell. If you enter the shell command, all yourinput is split by the \fIText::ParseWords::shellwords()\fR routine whichacts like most shells do. The first word is being interpreted as themethod to be called and the rest of the words are treated as argumentsto this method. Continuation lines are supported if a line ends with aliteral backslash..Sh "autobundle".IX Subsection "autobundle"\&\f(CW\*(C`autobundle\*(C'\fR writes a bundle file into the\&\f(CW\*(C`$CPAN::Config\->{cpan_home}/Bundle\*(C'\fR directory. The file containsa list of all modules that are both available from \s-1CPAN\s0 and currentlyinstalled within \f(CW@INC\fR. The name of the bundle file is based on thecurrent date and a counter..Sh "hosts".IX Subsection "hosts"Note: this feature is still in alpha state and may change in futureversions of \s-1CPAN\s0.pm.PPThis commands provides a statistical overview over recent downloadactivities. The data for this is collected in the \s-1YAML\s0 file\&\f(CW\*(C`FTPstats.yml\*(C'\fR in your \f(CW\*(C`cpan_home\*(C'\fR directory. If no \s-1YAML\s0 module isconfigured or \s-1YAML\s0 not installed, then no stats are provided..Sh "mkmyconfig".IX Subsection "mkmyconfig"\&\fImkmyconfig()\fR writes your own CPAN::MyConfig file into your ~/.cpan/directory so that you can save your own preferences instead of thesystem wide ones..Sh "recent ***EXPERIMENTAL COMMAND***".IX Subsection "recent ***EXPERIMENTAL COMMAND***"The \f(CW\*(C`recent\*(C'\fR command downloads a list of recent uploads to \s-1CPAN\s0 anddisplays them \fIslowly\fR. While the command is running \f(CW$SIG\fR{\s-1INT\s0} isdefined to mean that the loop shall be left after having displayed thecurrent item..PP\&\fBNote\fR: This command requires XML::LibXML installed..PP\&\fBNote\fR: This whole command currently is a bit klunky and willprobably change in future versions of \s-1CPAN\s0.pm but the generalapproach will likely stay..PP\&\fBNote\fR: See also smoke.Sh "recompile".IX Subsection "recompile"\&\fIrecompile()\fR is a very special command in that it takes no argument andruns the make/test/install cycle with brute force over all installeddynamically loadable extensions (aka \s-1XS\s0 modules) with 'force' ineffect. The primary purpose of this command is to finish a networkinstallation. Imagine, you have a common source tree for two differentarchitectures. You decide to do a completely independent freshinstallation. You start on one architecture with the help of a Bundlefile produced earlier. \s-1CPAN\s0 installs the whole Bundle for you, butwhen you try to repeat the job on the second architecture, \s-1CPAN\s0responds with a \f(CW"Foo up to date"\fR message for all modules. So youinvoke \s-1CPAN\s0's recompile on the second architecture and you're done..PPAnother popular use for \f(CW\*(C`recompile\*(C'\fR is to act as a rescue in case yourperl breaks binary compatibility. If one of the modules that \s-1CPAN\s0 usesis in turn depending on binary compatibility (so you cannot run \s-1CPAN\s0commands), then you should try the CPAN::Nox module for recovery..Sh "report Bundle|Distribution|Module".IX Subsection "report Bundle|Distribution|Module"The \f(CW\*(C`report\*(C'\fR command temporarily turns on the \f(CW\*(C`test_report\*(C'\fR configvariable, then runs the \f(CW\*(C`force test\*(C'\fR command with the givenarguments. The \f(CW\*(C`force\*(C'\fR pragma is used to re-run the tests and repeatevery step that might have failed before..Sh "smoke ***EXPERIMENTAL COMMAND***".IX Subsection "smoke ***EXPERIMENTAL COMMAND***"\&\fB*** \s-1WARNING:\s0 this command downloads and executes software from \s-1CPAN\s0 toyour computer of completely unknown status. You should never dothis with your normal account and better have a dedicated wellseparated and secured machine to do this. ***\fR.PPThe \f(CW\*(C`smoke\*(C'\fR command takes the list of recent uploads to \s-1CPAN\s0 asprovided by the \f(CW\*(C`recent\*(C'\fR command and tests them all. While thecommand is running \f(CW$SIG\fR{\s-1INT\s0} is defined to mean that the current itemshall be skipped..PP\&\fBNote\fR: This whole command currently is a bit klunky and willprobably change in future versions of \s-1CPAN\s0.pm but the generalapproach will likely stay..PP\&\fBNote\fR: See also recent.Sh "upgrade [Module|/Regex/]...".IX Subsection "upgrade [Module|/Regex/]..."The \f(CW\*(C`upgrade\*(C'\fR command first runs an \f(CW\*(C`r\*(C'\fR command with the givenarguments and then installs the newest versions of all modules thatwere listed by that..ie n .Sh "The four ""CPAN::*"" Classes: Author, Bundle, Module, Distribution".el .Sh "The four \f(CWCPAN::*\fP Classes: Author, Bundle, Module, Distribution".IX Subsection "The four CPAN::* Classes: Author, Bundle, Module, Distribution"Although it may be considered internal, the class hierarchy does matterfor both users and programmer. \s-1CPAN\s0.pm deals with above mentioned fourclasses, and all those classes share a set of methods. A classicalsingle polymorphism is in effect. A metaclass object registers allobjects of all kinds and indexes them with a string. The stringsreferencing objects have a separated namespace (well, not completelyseparated):.PP.Vb 1\&         Namespace                         Class\&\&   words containing a "/" (slash)      Distribution\&    words starting with Bundle::          Bundle\&          everything else            Module or Author.Ve.PPModules know their associated Distribution objects. They always referto the most recent official release. Developers may mark their releasesas unstable development versions (by inserting an underbar into themodule version number which will also be reflected in the distributionname when you run 'make dist'), so the really hottest and newestdistribution is not always the default.  If a module Foo circulateson \s-1CPAN\s0 in both version 1.23 and 1.23_90, \s-1CPAN\s0.pm offers a convenientway to install version 1.23 by saying.PP.Vb 1\&    install Foo.Ve.PPThis would install the complete distribution file (sayBAR/Foo\-1.23.tar.gz) with all accompanying material. But if you wouldlike to install version 1.23_90, you need to know where thedistribution file resides on \s-1CPAN\s0 relative to the authors/id/directory. If the author is \s-1BAR\s0, this might be BAR/Foo\-1.23_90.tar.gz;so you would have to say.PP.Vb 1\&    install BAR/Foo\-1.23_90.tar.gz.Ve.PPThe first example will be driven by an object of the classCPAN::Module, the second by an object of class CPAN::Distribution..Sh "Integrating local directories".IX Subsection "Integrating local directories"Note: this feature is still in alpha state and may change in futureversions of \s-1CPAN\s0.pm.PPDistribution objects are normally distributions from the \s-1CPAN\s0, butthere is a slightly degenerate case for Distribution objects, too, ofprojects held on the local disk. These distribution objects have thesame name as the local directory and end with a dot. A dot by itselfis also allowed for the current directory at the time \s-1CPAN\s0.pm wasused. All actions such as \f(CW\*(C`make\*(C'\fR, \f(CW\*(C`test\*(C'\fR, and \f(CW\*(C`install\*(C'\fR are applieddirectly to that directory. This gives the command \f(CW\*(C`cpan .\*(C'\fR aninteresting touch: while the normal mantra of installing a \s-1CPAN\s0 modulewithout \s-1CPAN\s0.pm is one of.PP.Vb 5\&    perl Makefile.PL                 perl Build.PL\&           ( go and get prerequisites )\&    make                             ./Build\&    make test                        ./Build test\&    make install                     ./Build install.Ve.PPthe command \f(CW\*(C`cpan .\*(C'\fR does all of this at once. It figures out whichof the two mantras is appropriate, fetches and installs allprerequisites, cares for them recursively and finally finishes theinstallation of the module in the current directory, be it a \s-1CPAN\s0module or not..PPThe typical usage case is for private modules or working copies ofprojects from remote repositories on the local disk..SH "CONFIGURATION".IX Header "CONFIGURATION"When the \s-1CPAN\s0 module is used for the first time, a configurationdialog tries to determine a couple of site specific options. Theresult of the dialog is stored in a hash reference \f(CW $CPAN::Config \fRin a file CPAN/Config.pm..PPThe default values defined in the CPAN/Config.pm file can beoverridden in a user specific file: CPAN/MyConfig.pm. Such a file isbest placed in \f(CW$HOME\fR/.cpan/CPAN/MyConfig.pm, because \f(CW$HOME\fR/.cpan isadded to the search path of the \s-1CPAN\s0 module before the \fIuse()\fR or\&\fIrequire()\fR statements. The mkmyconfig command writes this file for you..PPThe \f(CW\*(C`o conf\*(C'\fR command has various bells and whistles:.IP "completion support" 4.IX Item "completion support"

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -