This file contains hidden or 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
def table_at(selector) | |
Nokogiri::HTML(page.body).css(selector).map do |table| | |
table.css('tr').map do |tr| | |
tr.css('td').map { |td| td.text.strip } | |
end | |
end[0].reject(&:empty?) | |
end |
This file contains hidden or 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 | |
if [ `which perl` = "/usr/bin/perl" ]; then | |
echo -n -e "\e[1;31mUSING SYSTEM PERL OK? [y/n]\e[m: " | |
read ANSWER | |
if [ "$ANSWER" != "y" ]; then | |
exit 255 | |
fi | |
PERL_CPANM_OPT="$PERL_CPANM_OPT --sudo" | |
fi |
This file contains hidden or 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 | |
use strict; | |
use warnings; | |
use FindBin::libs; | |
use YAML; | |
use Sniffer::RTMP; | |
my $dev = $ARGV[0] or die 'require device name'; |