Skip to content

Instantly share code, notes, and snippets.

@dhoss
dhoss / gist:239942
Created November 21, 2009 01:19 — forked from jhannah/gist:239941
open my $in, "oma_repl_language_text.sql";
open (my $out, ">:encoding(UTF-8)", "utf8.sql");
while (<$in>) {
print $out $_;
}
package Schema;
use base qw/DBIx::Class::Schema/;
__PACKAGE__->load_namespaces;
1;
@dhoss
dhoss / gist:253513
Created December 10, 2009 17:42 — forked from jshirley/gist:253512
#!/bin/sh
# Start a Plack daemon.
PATH=/bin:/usr/bin:/sbin:/usr/sbin:$HOME/perl5/bin
DAEMON="$HOME/perl5/bin/plackup"
NAME="AppName"
CWD=`pwd`
# Defaults
RUN="no"
package SmallBoard::Script::Deploy;
use Moose;
use MooseX::Types::Moose qw/Str/;
use namespace::autoclean;
use SmallBoard::Schema;
with 'Catalyst::ScriptRole';
has dsn => (
traits => [qw(Getopt)],
12:26 -!- screen_away: Set away
12:26 [ii] -!- You have been marked as being away
12:26 [oftc] -!- You have been marked as being away
12:26 [scsys] -!- You have been marked as being away
12:26 [MagNET] -!- You have been marked as being away
12:26 [freenode] -!- You have been marked as being away
12:26 [osx86] -!- You have been marked as being away
Day changed to 01 Jan 2010
Day changed to 02 Jan 2010
22:28 -!- screen_away: Reset away
@dhoss
dhoss / REST.pm
Created January 11, 2010 19:08 — forked from jshirley/REST.pm
package My::Base::REST;
use Moose;
BEGIN { extends 'Catalyst::Controller::REST'; }
use CGI::Expand qw/expand_hash/;
__PACKAGE__->config(
'default' => 'text/html',
package Catalyst::Model::Twitter;
use Moose;
use namespace::autoclean;
use Try::Tiny;
use Net::Twitter;
use Carp;
use Data::Dumper;
extends 'Catalyst::Model';
has 'consumer_key' => (
@dhoss
dhoss / gist:298877
Created February 9, 2010 03:03 — forked from semifor/gist:297169
### The model ####
package MyApp::Model::Twitter;
use Moose;
use Carp;
use Net::Twitter;
use namespace::autoclean;
extends 'Catalyst::Component';
__PACKAGE__->config(
package TestApp::Controller::Namespace;
use Moose;
use namespace::autoclean;
BEGIN { extends 'Catalyst::Controller' }
sub main :Local {
my ($self, $c) = @_;
$c->stash( name => 'Bob' );
}
Hello students!
It's getting even closer to the deadline to submit applications and have things rounded up and in order for this year's Google Summer of Code.
Catalyst has plenty of projects for you to check out if you're interested, so please check out the wiki: http://www.perlfoundation.org/perl5/index.cgi?gsoc,
and contact a mentor: http://www.perlfoundation.org/perl5/index.cgi?gsoc_mentors. Jump on #catalyst and #catalyst-dev on irc.perl.org to get in touch with us.
Thanks!
dhoss