[Catalyst-commits] r10838 - in
Catalyst-Runtime/5.80/branches/better_scripts:
lib/Catalyst/Script t/TestApp/script
dhoss at dev.catalyst.perl.org
dhoss at dev.catalyst.perl.org
Sat Jul 11 00:06:53 GMT 2009
Author: dhoss
Date: 2009-07-11 00:06:53 +0000 (Sat, 11 Jul 2009)
New Revision: 10838
Modified:
Catalyst-Runtime/5.80/branches/better_scripts/lib/Catalyst/Script/Server.pm
Catalyst-Runtime/5.80/branches/better_scripts/t/TestApp/script/testapp_server.pl
Log:
fixed Catalyst::Script::Server so app doesn't have to be a cmd line opt
Modified: Catalyst-Runtime/5.80/branches/better_scripts/lib/Catalyst/Script/Server.pm
===================================================================
--- Catalyst-Runtime/5.80/branches/better_scripts/lib/Catalyst/Script/Server.pm 2009-07-10 23:27:12 UTC (rev 10837)
+++ Catalyst-Runtime/5.80/branches/better_scripts/lib/Catalyst/Script/Server.pm 2009-07-11 00:06:53 UTC (rev 10838)
@@ -75,11 +75,13 @@
## broken now, WHY?!
-has app => (
- #traits => [qw(NoGetopt)],
+has _app => (
+ reader => 'app',
+ init_arg => 'app',
+ traits => [qw(NoGetopt)],
isa => 'Str',
is => 'ro',
- required => 1,
+ required => 0,
);
has restart => (
@@ -121,6 +123,7 @@
pod2usage() if $self->help;
my $app = $self->app;
+ warn "App is $app";
Class::MOP::load_class($app);
$app->run(
$self->listen, $self->host,
Modified: Catalyst-Runtime/5.80/branches/better_scripts/t/TestApp/script/testapp_server.pl
===================================================================
--- Catalyst-Runtime/5.80/branches/better_scripts/t/TestApp/script/testapp_server.pl 2009-07-10 23:27:12 UTC (rev 10837)
+++ Catalyst-Runtime/5.80/branches/better_scripts/t/TestApp/script/testapp_server.pl 2009-07-11 00:06:53 UTC (rev 10838)
@@ -10,4 +10,4 @@
## because this is a test
use lib "$Bin/../../../lib";
use Catalyst::ScriptRunner;
-Catalyst::ScriptRunner->run('Catalyst','Server');
+Catalyst::ScriptRunner->run('TestApp','Server');
More information about the Catalyst-commits
mailing list