Skip to content

Instantly share code, notes, and snippets.

View yanick's full-sized avatar
🏠
Working from home

Yanick Champoux yanick

🏠
Working from home
View GitHub Profile
@yanick
yanick / azkaban_flow.pl
Created August 6, 2014 15:00
command-line Azkaban flow graphing
#!/usr/bin/env perl -s
=head1 SYNOPSIS
$ azkaban_flow -f=<format> path/to/final/job
=head1 DESCRIPTION
The script reads the Azkaban job file, figure out all its dependencies, traverses them,
and generates the resulting graph.
@yanick
yanick / MyJSONY.pm
Created July 25, 2014 14:14
A Parse::RecDescent implementation of JSONY
use 5.12.0;
package MyJSONY;
use Parse::RecDescent;
use JSON qw/ to_json from_json /;
use Scalar::Util qw/ looks_like_number /;
use 5.20.0;
use experimental 'postderef';
use HTTP::Proxy;
use HTTP::Proxy::HeaderFilter::simple;
use Ubic;
use CHI;
# Cluster:
cluster {
color 'local';
description '';
name 'local';
interfaces (
"hftp://localhost:41110" => { type => 'readonly', version => "0.20.2" },
"hftp://localhost:41021" => { type => 'execute', version => "0.20.2" },
);
@yanick
yanick / DualLived.vimpl
Created April 9, 2014 14:11
Vim::X script coming with its own vim config
""; <<finish;
map ,dl :call DualLived()<CR>
finish
use Vim::X;
sub DualLived :Vim {
vim_msg "hello there";
@yanick
yanick / automoo.pl
Created April 8, 2014 16:42
automoo
use 5.10.0;
sub create_moo {
my ( $class, $prototype ) = @_;
eval join "\n", "package $class;", 'use Moo;',
map { "has $_ => ( is => 'ro' );" } keys %$prototype;
return $class;
@yanick
yanick / INSTALL.md
Created February 25, 2014 14:56 — forked from namuol/INSTALL.md

rage-quit support for bash

HOW TO INSTALL

Put flip somewhere in your $PATH and chmod a+x it.

Copy fuck into ~/.bashrc.

@yanick
yanick / gist:9146512
Created February 22, 2014 00:18
Yanick's CPAN releases
$ cpan-release-counts --user YANICK
2005 ( 3) #
2006 ( 17) ######
2007 ( 22) ########
2008 ( 28) ###########
2009 ( 15) ######
2010 ( 45) ##################
2011 ( 57) ######################
2012 ( 76) ##############################
2013 (125) ##################################################
@yanick
yanick / autodie_koan.txt
Created October 8, 2013 14:47
An 'autodie' koan
"How can I seek Death?" asked the disciple to the master.
The master smiled. "How can you make mountains rise? How
do you make the sea ebbs at tides? How do you make time flow?"
The disciple frowned. And frowned some more. And then,
in a moment of enlightenment, thought of 'autodie', had
an aneurysm, and died.
@yanick
yanick / LockedLockFile.pm
Created April 30, 2013 19:13
Lock the lockfiles
package LockedLockFile;
use strict;
use warnings;
use Moose;
use Path::Tiny;
use File::Flock::Tiny;