Skip to content

Instantly share code, notes, and snippets.

@giuliano108
giuliano108 / README.md
Last active December 28, 2015 09:58
d3.layout.colgrid

d3.layout.colgrid

Takes a list of columns (a matrix where the columns can have different lengths) and arranges every element on a grid. Inspired by d3.layout.grid.

Click for a demo.

@giuliano108
giuliano108 / phonesonoff.rb
Created June 12, 2013 23:02
Given a Cisco switch, enable/disable power on every PoE port that has an IP Phone connected to it.
#!/usr/bin/env ruby
# - Connects to a Cisco switch
# - Asks CDP which ports have an "IP Phone" connected to them
# - On every such port, turn PoE on or off
#
# -- [email protected]
require 'greenletters'
require 'trollop'