Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am mikefaille on github.
  • I am mikefaille (https://keybase.io/mikefaille) on keybase.
  • I have a public key ASA1rf21Xu9jTvn3fwNyaRLHV_EfpDh2klogAevLr5jDOQo

To claim this, I am signing this object:

Keybase proof

I hereby claim:

  • I am mikefaille on github.
  • I am mikefaille (https://keybase.io/mikefaille) on keybase.
  • I have a public key ASC-wtReGqZA9YYT9SoDZhwW-aqGfIttLWK4abuxE4h6MAo

To claim this, I am signing this object:

#!/bin/bash
declare -A SEASON_COUNTER
for fn in `cat comptagevelo2009-20162.csv`; do
RAW_BIKE_COUNTER=$(echo $fn | awk -F '/' '{print $3}' | cut -b 12-)
MY_DATE_STR=$(cut --output-delimiter=" " -f 3,2,1 -d '/' <(echo $fn | head -c 10) )
MY_DATE=($MY_DATE_STR)
;;; ox-confluence-en.el --- Enhanced Confluence Wiki Back-End for Org Export Engine
;; Copyright (C) 2015, Correl Roush
;; Author: Correl Roush <correl@gmail.com>
;; Keywords: outlines, confluence, wiki
;; This file is not part of GNU Emacs.
;; This program is free software: you can redistribute it and/or modify
@mikefaille
mikefaille / vagrant.py
Created November 9, 2016 21:02 — forked from lorin/vagrant.py
Vagrant dynamic inventory script for Ansible
#!/usr/bin/env python
# Adapted from Mark Mandel's implementation
# https://github.com/ansible/ansible/blob/devel/plugins/inventory/vagrant.py
import argparse
import json
import paramiko
import subprocess
import sys
@mikefaille
mikefaille / pedantically_commented_playbook.yml
Created May 31, 2016 12:23 — forked from marktheunissen/pedantically_commented_playbook.yml
Insanely complete Ansible playbook, showing off all the options
---
# ^^^ YAML documents must begin with the document separator "---"
#
#### Example docblock, I like to put a descriptive comment at the top of my
#### playbooks.
#
# Overview: Playbook to bootstrap a new host for configuration management.
# Applies to: production
# Description:
# Ensures that a host is configured for management with Ansible.
@mikefaille
mikefaille / System Design.md
Created April 18, 2016 11:17 — forked from vasanthk/System Design.md
System Design Cheatsheet

#System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

##Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
test
@mikefaille
mikefaille / HSVandRGBtest.java
Created September 16, 2014 16:12
HSVtoRGB and vice versa test
public class HSVtoRGB {
public static void main(String[] args) {
float []hsbVal = null;
hsbVal = RGBtoHSBfloat(180, 58, 58, hsbVal );
int rgb = HSBtoRGB(hsbVal[0], hsbVal[1], hsbVal[2]);
int red = (rgb >> 16) & 0xFF;
@mikefaille
mikefaille / Linc-Ctrl-RemoveFlows
Created April 27, 2013 07:51
This my flow deletion :
RemoveFlows = #ofp_message{
version = 3,
xid = 200,
body = #ofp_flow_mod{
cookie = <<0:64>>,
cookie_mask = <<0:64>>,
table_id = 1,
command = delete,
idle_timeout = 30000,
hard_timeout = 60000,