I hereby claim:
- I am james on github.
- I am abscond (https://keybase.io/abscond) on keybase.
- I have a public key whose fingerprint is 2440 6B38 61ED 4BD1 61B2 5F6F 3866 9EBB 7B84 70DA
To claim this, I am signing this object:
desc "Will replace i18n references in specs with actual text from default locale" | |
task undo_i18n_in_specs: :environment do | |
Dir[Rails.root.join("spec/features/**/*.rb")].collect do |file_name| | |
file_text = File.read(file_name) | |
file_text.scan(/\Wt\("([\w\.]+)"\)/).each do |match| | |
file_text.gsub!("t(\"#{match.first}\")", "\"#{I18n.t(match.first)}\"") | |
end | |
File.open(file_name, "w") { |file| file.puts file_text } | |
end | |
end |
# Install raspbian lite | |
# run `sudo raspi-config` and enable camera | |
# sudo apt-get update | |
# sudo apt-get upgrade | |
# sudo apt-get install python3-picamera | |
# sudo apt-get install python3-rpi.gpio | |
from picamera.array import PiYUVArray | |
from picamera import PiCamera | |
from time import sleep |
require 'csv' | |
require 'date' | |
require 'chronic' | |
HEADERS_TO_KEEP = ['MembershipNumber', 'Title', 'LastName', 'PreferredFirstName', 'DateOfBirth', 'AddressLine1', 'AddressLine2', 'AddressLine3', 'Town', 'Country Code', 'County', 'PostCode', 'Email', 'MobilePhoneNumber', 'PhoneNumber', 'RegionName', 'ConstituencyName', 'TradeUnion', 'PrimaryStatus'] #, 'JoinedDate' | |
Dir.entries('to_convert')[2..999].each do |file| | |
members = CSV.read("to_convert/#{file}", headers: true, :encoding => 'windows-1251:utf-8') | |
# remove unused columns |
I hereby claim:
To claim this, I am signing this object:
require 'twitter' | |
require 'csv' | |
@client = Twitter::REST::Client.new do |config| | |
config.consumer_key = "" | |
config.consumer_secret = "" | |
config.access_token = "" | |
config.access_token_secret = "" | |
end |
// ==UserScript== | |
// @name Highlight italics | |
// @version 0.1 | |
// @namespace abscond | |
// @include * | |
// ==/UserScript== | |
arr = document.getElementsByTagName('i'); | |
var length = arr.length; |
// ==UserScript== | |
// @name Right Move Price per Bedroom | |
// @version 0.1.4 | |
// @namespace abscond | |
// @include http://*rightmove.co.uk/*/find* | |
// ==/UserScript== | |
function addJQuery(callback) { | |
var script = document.createElement("script"); |
require 'twitter' | |
Twitter.configure do |config| | |
config.consumer_key = YOUR_CONSUMER_KEY | |
config.consumer_secret = YOUR_CONSUMER_SECRET | |
config.oauth_token = YOUR_OAUTH_TOKEN | |
config.oauth_token_secret = YOUR_OAUTH_TOKEN_SECRET | |
end | |
s = nil | |
while true | |
if IO.popen('pbpaste', 'r+').read != s |