https://passingcuriosity.com/2013/dnsmasq-dev-osx/
http://www.sitepoint.com/set-automatic-virtual-hosts-nginx-apache/
use v5.10; | |
sub ok{ | |
print $_[0]?"OK":"FAIL"; | |
print "\n"; | |
} | |
sub make_sym{ | |
state %symbols; | |
my ($sym) = @_; | |
$symbols{$sym} = \$sym unless $symbols{$sym}; | |
return $symbols{$sym}; |
@EBean | |
public class FSM extends XFSM { | |
private static final String TAG = "FSM"; | |
@RootContext | |
Context context; | |
Thread consumerThread; | |
public RuleSet getRuleSet() { |
package pavo; | |
import java.io.*; | |
import java.util.*; | |
import javax.script.*; | |
public class ERB { | |
static ScriptEngine jruby = initializeJRuby(); | |
#!/usr/bin/env perl | |
use Mojolicious::Lite; | |
use Scalar::Util 'weaken'; | |
hook( before_dispatch => sub { | |
use Data::Dump; | |
my $self = shift; | |
my $uri = $self->req->headers->header('SCRIPT_NAME'); |
#!/bin/bash | |
# | |
# Initialize new virtual server using LXC and set up networking and HTTP proxy | |
# | |
# Written by: Deni Bertovic <[email protected]> | |
# | |
# Released into Public Domain. You may use, modify and distribute it as you | |
# see fit. | |
# | |
# This script will: |
#!/usr/bin/env perl | |
use 5.010; | |
use strict; | |
use List::MoreUtils qw/zip/; | |
use Math::Base::Convert qw(cnv); | |
use Data::Dumper; | |
my $res = 45; | |
my @nums = qw(9 2 11 13 6 3); | |
my $max = 4 ** (@nums-1); |
--- | |
database: | |
dsn: DBI:mysql:database=DBNAME;host=DBHOST | |
userid: DBUSER | |
passwd: DBPASS | |
options: | |
mysql_enable_utf8: 1 | |
mysql_auto_reconnect: 1 |
#!/usr/bin/env perl | |
use 5.010; | |
my $path = '.'; | |
my @types=qw( mov mp4 avi mkv m4v xvid divx wmv mpg mpeg ); | |
my @files = `find $path`; | |
chomp(@files); |