96 |
$path =~ m{/editor(.+?)\+(\d+)} |
$path =~ m{/editor(.+?)\+(\d+)} |
97 |
) { |
) { |
98 |
my $editor = $ENV{VISUAL} || $ENV{EDITOR} || 'vi'; |
my $editor = $ENV{VISUAL} || $ENV{EDITOR} || 'vi'; |
99 |
my $cmd = "$editor -R +$2 $1"; |
# FIXME SECURITY path verification for $1 |
100 |
|
my $cmd = "$editor +$2 $1"; |
101 |
warn "# $path -> system $cmd"; |
warn "# $path -> system $cmd"; |
102 |
$req->print( $cmd ); |
$req->print( $cmd ); |
103 |
system( $cmd ); |
system( $cmd ); |
107 |
) { |
) { |
108 |
my $class = rest2class $1; |
my $class = rest2class $1; |
109 |
warn "# run $class $2\n"; |
warn "# run $class $2\n"; |
110 |
$f = Frey::Run->new( class => $class, params => \%params, run => $2 ); |
$f = Frey::Run->new( class => $class, params => \%params, run => $2, request_url => $req->request->url ); |
111 |
} elsif ( |
} elsif ( |
112 |
$path =~ m{/([^/]+)/?$} |
$path =~ m{/([^/]+)/?$} |
113 |
) { |
) { |
114 |
my $class = rest2class $1; |
my $class = rest2class $1; |
115 |
warn "# introspect $class"; |
warn "# introspect $class"; |
116 |
$f = Frey::Run->new( class => 'Frey::Introspect', params => { class => $class } ); |
$f = Frey::Run->new( class => 'Frey::Introspect', params => { class => $class }, request_url => $req->request->url ); |
117 |
} else { |
} else { |
118 |
$f = Frey::Run->new( class => 'Frey::ClassBrowser' ); |
$f = Frey::Run->new( class => 'Frey::ClassBrowser' ); |
119 |
} |
} |