I hereby claim:
- I am sgnix on github.
- I am sge (https://keybase.io/sge) on keybase.
- I have a public key whose fingerprint is A798 AAE6 09DF 1C43 D9DE ECDF A531 6999 151B 3BAC
To claim this, I am signing this object:
javascript:location.href='https://clients2.google.com/service/update2/crx?response=redirect&acceptformat=crx2,crx3&prodversion='+(navigator.appVersion.match(/Chrome\/(\S+)/)[1])+'&x=id%'+'3D'+(document.querySelector('a[href^="https://chrome.google.com/webstore/report/"]').pathname.match(/[^\/]+\/*$/)[0])+'%'+'26installsource%'+'3Dondemand%'+'26uc'; |
I hereby claim:
To claim this, I am signing this object:
use strict; | |
use warnings; | |
use Types::Standard qw/Int Str/; | |
use Params::ValidationCompiler qw( validation_for ); | |
sub foo { | |
my ($num) = validation_for( | |
params => [ | |
{ type => Str } |
Verifying my Blockstack ID is secured with the address 1GgERwbnszgZMeb4G837tMAA5aqPR49Y1V https://explorer.blockstack.org/address/1GgERwbnszgZMeb4G837tMAA5aqPR49Y1V |
package Kelp::Config; | |
use strict; | |
use warnings; | |
use base 'Kelp'; | |
sub new { | |
my $self = shift->SUPER::new(@_); | |
$self->_load_config(); | |
return $self; |
get '/fortunes' => sub { | |
my $self = shift; | |
$sth1->execute(); | |
my $fortunes = $sth1->fetchall_arrayref({}); | |
push @$fortunes, { id => 0, message => 'Additional fortune added at request time.' }; | |
$self->template( 'fortunes', { fortunes => [ sort { $a->{message} cmp $b->{message} } @$fortunes] } ); | |
}; |
#!/usr/bin/env perl | |
use strict; | |
use warnings; | |
my $xrandr = '/usr/bin/xrandr'; | |
my $LVDS = 'LVDS-1'; | |
my @a = `$xrandr -q`; | |
my %connected = (); |
package MyApp; | |
use Kelp::Base 'Kelp'; | |
use DBI; | |
# Lazy attribute with DBI handle | |
attr _dbh => sub { | |
$_[0]->_dbi_connect; | |
}; | |
# Private sub to connect |
get '/put/:x/:y' => sub { | |
my ( $self, $x, $y ) = @_; | |
{ x => $x, y => $y }; | |
}; |
my %rules = ( | |
fields => [ 'name', 'email', 'pass' ], # What fields | |
filters => [ | |
name => sub { ... }, # Filter name | |
email => sub { ... }, # Filter email | |
pass => sub { ... } # Filter pass | |
], | |
checks => [ | |
name => sub { ... }, # Check if name is good | |
email => sub { ... }, # Check email |