This file contains 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
require 'lib/ruby-des' | |
class TDES | |
class << self | |
def en_des plain, key | |
ret = '' | |
blocks = plain.scan(/.{16}/) | |
blocks.each do |block| | |
ret = ret + en_des_block(block, key) | |
end |
This file contains 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
buts = document.getElementsByClassName("mNa nNa EFc"); | |
// loop from last to first | |
buts[i].click() // that selects it | |
// you'll need to get out of the big window | |
document.getElementsByClassName("cra")[0].click() |
This file contains 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
// Bookmark url (remember to update the https link inside it for your fork): | |
// javascript:(function(){var d=document,s=d.createElement('script');s.src='https://cdn.rawgit.com/sadasant/1d51bd8d26b5fd94f9f3/raw/read.js';d.body.appendChild(s);}()) | |
if (window.READING) { | |
alert("READ is already available :)"); | |
} else { | |
(function() { | |
var READING = window.READING = {}; | |
READING.delay = 100; | |
READING.extra = 100; | |
READING.top = 100; |
This file contains 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
# To compile `mrbc -o mrbc_fail.mrb mrbc_fail.rb` | |
class_decation_error T | |
def self.a | |
puts "aa" | |
end | |
end |
This file contains 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
// From: https://stackoverflow.com/a/14041378 | |
function toUserTimeZone(utc_date, offset){ | |
if (utc_date.slice(-3) !== "UTC") { | |
utc_date += " UTC"; | |
} | |
var local_date = new Date(utc_date); | |
var local_offset = local_date.getTimezoneOffset() * 60000; | |
var utc_time = local_date.getTime() + local_offset; | |
return new Date(utc_time + (3600000 * offset)); |
This file contains 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
var request = require("request"); | |
var qstr = require("querystring").stringify; | |
var Args = require("args-js"); | |
var utils = require("../utils"); | |
var etcd = module.exports = {}; | |
var watchers = etcd.watchers = {}; | |
var timeout_code = "ESOCKETTIMEDOUT"; |
This file contains 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
class FileDb < Hash | |
attr_accessor :path | |
def initialize | |
super | |
end | |
def self.open(path) | |
f = self.new |
This file contains 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
module T | |
def self.display | |
puts "display 1" | |
end | |
end | |
T.display | |
def T.display | |
puts "display 2" |
This file contains 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
// UTF8 Module | |
// | |
// Cleaner and modularized utf-8 encoding and decoding library for javascript. | |
// | |
// copyright: MIT | |
// author: Nijiko Yonskai, @nijikokun, nijikokun@gmail.com | |
(function (name, definition, context, dependencies) { | |
if (typeof context['module'] !== 'undefined' && context['module']['exports']) { if (dependencies && context['require']) { for (var i = 0; i < dependencies.length; i++) context[dependencies[i]] = context['require'](dependencies[i]); } context['module']['exports'] = definition.apply(context); } | |
else if (typeof context['define'] !== 'undefined' && context['define'] === 'function' && context['define']['amd']) { define(name, (dependencies || []), definition); } | |
else { context[name] = definition.apply(context); } |
This file contains 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
MotionNotify 569 286 | |
KeyStrPress Shift_L | |
KeyStrPress semicolon | |
KeyStrRelease semicolon | |
KeyStrRelease Shift_L | |
KeyStrPress Shift_L | |
KeyStrPress 1 | |
KeyStrRelease 1 | |
KeyStrPress 3 | |
KeyStrRelease 3 |