^M 符號的產生,大多是由於Windows 平台的文件,在上傳檔案至Linux/Unix平台的過程中,其換行符號沒有做適當的轉換所致。
以下這個命令列選項可以得知Perl 的版本代碼 ...
ºô¸ôºÞ²z»y¨¥Perl¤Jªù»P¹ê§@:<<>>3.3Perlªº©R¥O¦C¿ï¶µ°£¤F¥Î«e¤@¸`ªº¤è¦¡°õ¦æPerlscript¤§¥~¡AÁÙ¥i¥H§Q¥ÎPerlªº©R¥O¦C¿ï¶µ¡G[ols3@p4sample]$perl-e'print"HelloPerl!!\n";'
HelloPerl!!
³oºØ¤è¦¡¡A¥Dn¬O§Q¥Î-e¿ï¶µ¡A±N±ý°õ¦æªºz±Ô©ñ¦b''³æ¤Þ¸¹¤§¶¡¡C¤ñ¦p¡A¥H¤U¤èªk¥i¥H¥h±¼¤å¥ó¤¤ªº^M²Å¸¹¡Gperl-pi.bak-e's/\r//g;'index.html^M²Å¸¹ªº²£¥Í¡A¤j¦h¬O¥Ñ©óWindows¥¥xªº¤å¥ó¡A¦b¤W¶ÇÀɮצÜLinux/Unix¥¥xªº¹Lµ{¤¤¡A¨ä´«¦æ²Å¸¹¨S¦³°µ¾A·íªºÂà´«©ÒP¡C¥H¤U³oÓ©R¥O¦C¿ï¶µ¥i¥H±oª¾Perlªºª©¥»¥N½X¡Gperl-v
µ²ªG¡G
Thisisperl,v5.8.0builtfori386-linux-thread-multi
Copyright1987-2002,LarryWall
PerlmaybecopiedonlyunderthetermsofeithertheArtisticLicenseorthe
GNUGeneralPublicLicense,whichmaybefoundinthePerl5sourcekit.
CompletedocumentationforPerl,includingFAQlists,shouldbefoundon
thissystemusing`manperl'or`perldocperl'.Ifyouhaveaccesstothe
Internet,pointyourbrowserathttp://www.perl.com/,thePerlHomePage.¥Ñ¤W¥iª¾¡A©Ò¥ÎªºPerlª©¥»¬O5.8.0¦Ü©óperl-c³oӿﶵ¡A¦b«e¤@¸`¤¤¤w´£¨ì¡A¥i¥Î¨ÓÀˬdPerlscript»yªkªº¥¿½T©Ê¡G[ols3@p4sample]$perl-chello.pl
hello.plsyntaxOK
PerlÁÙ¦³«D±`¦hªº©R¥O¦C¿ï¶µ¡A±ýª¾¸Ô±¡¡A½Ð¤U¡G[ols3@p4perl_intro]$perl-h
Usage:perl[switches][--][programfile][arguments]
-0[octal]specifyrecordseparator(\0,ifnoargument)
-aautosplitmodewith-nor-p(splits$_into@F)
-Cenablenativewidecharactersysteminterfaces
-cchecksyntaxonly(runsBEGINandCHECKblocks)
-d[:debugger]runprogramunderdebugger
-D[number/list]setdebuggingflags(argumentisabitmaskoralphabets)
-e'command'onelineofprogram(several-e'sallowed,omitprogramfile)
-F/pattern/split()patternfor-aswitch(//'sareoptional)
-i[extension]edit<>filesinplace(makesbackupifextensionsupplied)
-Idirectoryspecify@INC/#includedirectory(several-I'sallowed)
-l[octal]enablelineendingprocessing,specifieslineterminator
-[mM][-]moduleexecute`use/nomodule...'beforeexecutingprogram
-nassume'while(<>){...}'looparoundprogram
-passumelooplike-nbutprintlinealso,likesed
-PrunprogramthroughCpreprocessorbeforecompilation
-senablerudimentaryparsingforswitchesafterprogramfile
-SlookforprogramfileusingPATHenvironmentvariable
-Tenabletaintingchecks
-tenabletaintingwarnings
-udumpcoreafterparsingprogram
-Uallowunsafeoperations
-vprintversion,subversion(includesVERYIMPORTANTperlinfo)
-V[:variable]printconfigurationsummary(orasingleConfig.pmvariable)
-wenablemanyusefulwarnings(RECOMMENDED)
-Wenableallwarnings
-Xdisableallwarnings
-x[directory]stripofftextbefore#!perllineandperhapscdtodirector°£¤F-e-c-v-h¤§¥~¡A¤Wz¿ï¶µ¤¤¤ñ¸û±`¥ÎªºÁÙ¦³-w(¥´¶}ĵ§i°T®§)-T(¦w¥þÀˬd)¡A©¹«á§ÚÌ·|¦A¥[¥H»¡©ú¡C<<>>3.2HelloPerl!Up3.4²ßÃD