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
// ==UserScript== | |
// @name Canvas Tracking Blocker | |
// @namespace ctb | |
// @description Monkey patches toDataURL for canvas to make it non-deterministic | |
// @include * | |
// @version 1 | |
// @grant none | |
// @run-at document-start | |
// ==/UserScript== | |
var toDataURL = HTMLCanvasElement.prototype.toDataURL; |
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 ruby | |
# vim: set syntax=ruby | |
flag = false | |
files = `git diff --cached --name-only --diff-filter=ACM | grep "_spec\.rb$"`.split("\n") | |
files.each do |file| | |
results = `git diff --cached #{file} | grep "^\+[^+]" | grep ":focus => true"`.split("\n").map { |r| r.sub(/^\+[\s\t]*/, '') } | |
if $? == 0 |