This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cosimo@ubuntu:~/src/web$ export PERL6LIB=/home/cosimo/src/perl6-sqlite/lib:/home/cosimo/src/web/lib | |
cosimo@ubuntu:~/src/web$ perl6 t/squerl/01-sqlite-write.t | |
invoke() not implemented in class 'Undef' | |
in sub SQLite3::sqlite_open (/home/cosimo/src/perl6-sqlite/lib/SQLite3.pm:50) | |
called from method Squerl::Database::open (/home/cosimo/src/web/lib/Squerl.pm:334) | |
called from method Squerl::Database::create_table (/home/cosimo/src/web/lib/Squerl.pm:360) | |
called from Main (t/squerl/01-sqlite-write.t:12) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
# | |
# Convert Opera contacts file (.adr) into | |
# mutt aliases file format. | |
# | |
# Usage: | |
# perl opera-adr-to-mutt-aliases.pl < ~/.opera/contacts.adr >> ~/.mutt/aliases | |
# | |
# Cosimo, 31/Jan/2011 | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Per Buer's code, "Re: Lots of configs" | |
* http://pastebin.com/a68y15hp | |
*/ | |
#include <stdio.h> | |
#include <string.h> | |
#include <pcre.h> | |
int main() { | |
const char *error; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Convert remote tags imported from SVN to real git tags | |
# | |
REMOTE_TAGS=$(git branch -r | grep 'tags/' | cut -f2 -d/) | |
GIT=$(which git) | |
for t in $REMOTE_TAGS | |
do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# purge-cache: Script to purge varnish cache. Defaults are defined in | |
# /etc/default/varnish. | |
# | |
# Cosimo <[email protected]> | |
# Based on reload-vcl, by Stig Sandbeck Mathisen <ssm at debian dot org> | |
# Settings | |
defaults=/etc/default/varnish |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
# | |
# Fires HTTP request batches at the specified hostname | |
# and analyzes the response times. | |
# | |
# If you have suspicious frequency of 3.00x, 9.00x, 21.00x | |
# seconds, then most probably you have a problem of packet loss | |
# in your network. | |
# | |
# [email protected], sometime in 2011 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
connect(3, {sa_family=AF_INET, sin_port=htons(11211), sin_addr=inet_addr("127.0.0.1")}, 16) = 0 | |
sendto(3, "get trololol\r\n", 14, 0, NULL, 0) = 14 | |
# ite(1, "# Sent 'get trololol\r# \n# '. Wai"..., 50# Sent 'get trololol | |
# '. Waiting a response...) = 50 | |
write(1, "\n", 1 | |
) = 1 | |
recvfrom(3, "END\r\n", 2048, 0, NULL, NULL) = 5 | |
recvfrom(3, <stuck-here> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
connect(3, {sa_family=AF_INET, sin_port=htons(80), sin_addr=inet_addr("127.0.0.1")}, 16) = 0 | |
sendto(3, "GET /ping.html HTTP/1.1\r\n\r\n", 27, 0, NULL, 0) = 27 | |
# ite(1, "# Sent 'GET /ping.html HTTP/1.1\r"..., 67# Sent 'GET /ping.html HTTP/1.1 | |
# | |
# '. Waiting a response...) = 67 | |
write(1, "\n", 1 | |
) = 1 | |
mmap(NULL, 1052672, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fc31ca1c000 | |
recvfrom(3, "HTTP/1.1 400 Bad Request\r\nDate: "..., 2048, 0, NULL, NULL) = 515 | |
recvfrom(3, "", 2048, 0, NULL, NULL) = 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/Mojo/Cookie.pm b/lib/Mojo/Cookie.pm | |
index 6a67e42..ed42fe5 100644 | |
--- a/lib/Mojo/Cookie.pm | |
+++ b/lib/Mojo/Cookie.pm | |
@@ -22,6 +22,7 @@ my $NAME_RE = qr/ | |
/x; | |
my $SEPARATOR_RE = qr/^\s*\;\s*/; | |
my $VALUE_RE = qr/^([^\;\,]+)\s*/; | |
+my $VALUE_NOCOMMA_RE = qr/^([^\;]+)\s*/; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# | |
# Tells the Debian version reading the OpenSSH banner | |
# Requires OpenSSH to be running and ssh port to be open. | |
# | |
# Usage: $0 <hostname> | |
# | |
# Cosimo, 23/11/2011 | |
HOST=$1 |
OlderNewer