01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
41: // 登録する 42: run "rcs \"-t-"+$rev+"\" -i \"" + $f + "\" >con";
41: // 登録する 42: runsync2 "rcs -t-\'" + $rev + "\' -i \"" + basename; 43: runsync2 "rcs -U " + basename;
56: // チェックイン 57: run "ci \"-m"+$rev+"\" "+$mode+"\"" + $f + "\" >con";
56: // チェックイン 57: runsync2 "ci -m\'" + $rev + "\' " + $mode + basename;
C:\Documents and Settings\わしじゃ> set USERNAME USERNAME=わしじゃ
56: // チェックイン 57: runsync2 "ci -wName -m\'" + $rev + "\' " + $mode + basename;
run "rlog \"" + basename + "\" >con";
$r1 = input("リビジョンを指定してください"); $rev = "-r"+ $r1; run "co -p "+$rev+" " + basename + " >con";
$Id: remoteclog.txt,v 1.2 2004/12/06 08:58:45 zuihu Exp $ RCSのテスト テスト続行 おっとしくじった。
RCS/citest.txt,v --> standard output revision 1.1 $Id: remoteclog.txt,v 1.2 2004/12/06 08:58:45 zuihu Exp $ RCSのテスト
$Id: remoteclog.txt,v 1.2 2004/12/06 08:58:45 zuihu Exp $ RCSのテスト
$Id: remoteclog.txt,v 1.2 2004/12/06 08:58:45 zuihu Exp $ RCSのテスト
$Id: remoteclog.txt,v 1.2 2004/12/06 08:58:45 zuihu Exp $ RCSのテスト テスト続行
$Id: remoteclog.txt,v 1.2 2004/12/06 08:58:45 zuihu Exp $ RCSのテスト テスト続行
RCS file: RCS/citest.txt,v Working file: citest.txt head: 1.2 branch: locks: access list: symbolic names: keyword substitution: kv total revisions: 2; selected revisions: 2 description: test ---------------------------- revision 1.2 date: 2004/12/03 02:47:46; author: zuihu; state: Exp; lines: +2 -1 rev2 ---------------------------- revision 1.1 date: 2004/12/03 02:47:17; author: zuihu; state: Exp; init ============================================
====================================================== RCS file: RCS/citest.txt,v retrieving revision 1.1 retrieving revision 1.2 diff -r1.1 -r1.2 1c1 < $Id: remoteclog.txt,v 1.2 2004/12/06 08:58:45 zuihu Exp $ --- > $Id: remoteclog.txt,v 1.2 2004/12/06 08:58:45 zuihu Exp $ 2a3 > テスト続行
my $ex1 = "John Due 12 Admitted."; my $reg1 = $ex1; $reg1 =~ s/[A-Z]+/\(\[A-Z\]\+\)/og; $reg1 =~ s/[a-z]+/\(\[a-z\]\+\)/og; $reg1 =~ s/\t/\(\\t\)/og; $reg1 =~ s/ +/\( \+\)/og; $reg1 =~ s/\d+/\(\\d\+\)/og; $reg1 =~ s/\.+/\(\.\+\)/og; print $reg1, "\n";
例示:John Due[tab]12[tab]Admitted.
正規表現: ([A-Z]+)([a-z]+)( +)([A-Z]+)([a-z]+)(\t)(\d+)(\t)([A-Z]+)([a-z]+)(.+)
#!/usr/bin/perl -w
# $Id: genreg2.pl,v 1.1 2004/12/16 08:12:38 zuihu Exp $
use strict;
use utf8;
use Encode qw(encode);
my $text = '漢字カナ混じり文をinputする';
$text =~ s/\p{InBasicLatin}+/\(\\p\{InBasicLatin\}\+\)/og;
$text =~ s/\p{InHalfwidthAndFullwidthForms}+/\(\\p\{InHalfwidthAndFullwidthForms\}\+\)/og;
$text =~ s/\p{Hiragana}+/\(\\p\{Hiragana}\+\)/og;
$text =~ s/\p{Katakana}+/\(\\p\{Katakana}\+\)/og;
$text =~ s/\p{Han}+/\(\\p\{Han}\+\)/og;
print encode('Shift_JIS', $text), "\n";
例示:漢字カナ混じり文をinputする
正規表現: (\p{Han}+)(\p{Katakana}+)(\p{Han}+)(\p{Hiragana}+)(\p{Han}+)(\p{Hiragana}+)(\p{InBasicLatin}+)(\p{Hiragana}+)
#!/usr/bin/perl -w
# $Id: genreg3.pl,v 1.1 2004/12/17 04:33:44 zuihu Exp $
# This script should be saved in UTF-8.
require 5.008;
use strict;
use utf8;
use Encode qw(encode);
# ここからユーザー指定項目 #
# 例示文字列
my $ex = "\t* CGI 開発ツール KCatch.pm [perl]:";
# 制約
my @separators = qw( \[ \] ); # 文字列として一般化しない記号
my $head = '\t\* '; # 頭部指定
my $tail = '\:'; # 尾部指定
# ここまでユーザー指定項目 #
print encode('Shift_JIS', $ex), "\n";
# 下準備
my $text = $ex;
$text =~ s/^($head)// if ($head && $head ne "");
$text =~ s/($tail)$// if ($tail && $tail ne "");
# 本作業
$text =~ s/([^\[\]]+)/(\.\*)/og;
for my $s (@separators)
{
$text =~ s/$s/\\$s/g;
$text =~ s/\\\\/\\/g;
}
my $pat = '^(' . $head . ')' if ($head && $head ne "");
$pat .= $text;
$pat .= $tail . '$' if ($tail && $tail ne "");
print encode('Shift_JIS', $pat), "\n";
# できあがった正規表現をテスト
$ex = "Regex NG." unless $ex =~ s/$pat/Regex OK./;
print encode('Shift_JIS', $ex), "\n";
\t* CGI 開発ツール KCatch.pm [perl]:
^(\t\* )(.*)\[(.*)\]\:$
Regex OK.
The regular expression: (?i-msx:reg(ular\s+)?exp?(ression)?) matches as follows: NODE EXPLANATION --------------------------------------------------------- (?i-msx: group, but do not capture (case-insensitive) (with ^ and $ matching normally) (with . not matching \n) (matching whitespace and # normally): --------------------------------------------------------- reg 'reg' --------------------------------------------------------- ( group and capture to \1 (optional (matching the most amount possible)): --------------------------------------------------------- ular 'ular' --------------------------------------------------------- \s+ whitespace (\n, \r, \t, \f, and " ") (1 or more times (matching the most amount possible)) --------------------------------------------------------- )? end of \1 (NOTE: because you're using a quantifier on this capture, only the LAST repetition of the captured pattern will be stored in \1) --------------------------------------------------------- ex 'ex' --------------------------------------------------------- p? 'p' (optional (matching the most amount possible)) --------------------------------------------------------- ( group and capture to \2 (optional (matching the most amount possible)): --------------------------------------------------------- ression 'ression' --------------------------------------------------------- )? end of \2 (NOTE: because you're using a quantifier on this capture, only the LAST repetition of the captured pattern will be stored in \2) --------------------------------------------------------- ) end of grouping ---------------------------------------------------------(2004-12-20 12:32:38)
C:> ppm.bat ppm> install DBI ppm> install DBD-SQLite ppm> install DBD-SQLite2 ppm> install HTML-Template ppm> quit
SQL-Abstract-1.17.tar.gz Class-DBI-AsForm-2.41.tar.gz Class-DBI-Plugin-0.03.tar.gz Class-DBI-Plugin-Type-0.02.tar.gz Class-DBI-Plugin-RetrieveAll-1.01.tar.gz Class-DBI-Plugin-AbstractCount-0.03.tar.gz Class-DBI-AbstractSearch-0.05.tar.gz
データベースに接続してデータベース・ハンドラーを生成 SQL文をprepare SELECT Title FROM mov1 WHERE Title LIKE 'F%' LIMIT 0,2; SQL実行 結果表示
map { print $_->Title, "\n" } Film->search_where(Title => [ { like => 'F%' } ]) ->slice(0,2) ;