Skip to content

Instantly share code, notes, and snippets.

@muffinresearch
muffinresearch / toggle-finder-hidden-files.sh
Created April 16, 2014 10:52
Shell Script Toggle hidden files OSX
#!/usr/bin/env bash
if [ "$(defaults read com.apple.finder AppleShowAllFiles)" == 'TRUE' ]; then
defaults write com.apple.finder AppleShowAllFiles FALSE
else
defaults write com.apple.finder AppleShowAllFiles TRUE
fi
killall Finder
exit 0
// INSTALL THE ADD-ON
let data = {
noscript: {
id: '{73a6fe31-595d-460b-a920-fcc0f8843232}',
installURL: 'https://addons.mozilla.org/firefox/downloads/latest/722/addon-722-latest.xpi?src=dp-btn-primary'
},
mutetabs: {
id: 'mute-all-inactive-tabs@evilpie.tomschuster.name',
installURL: 'https://addons.mozilla.org/firefox/downloads/file/394320/mute_all_inactive_tabs-0.1.1.xpi?src=ss',
@muffinresearch
muffinresearch / spotify_dbus_screensaver.py
Last active April 7, 2016 12:58
Dbus Spotify Screensaver Toggle
#!/usr/bin/env python
"""
Spotify Screensaver Toggle
By Stuart Colville
http://muffinresearch.co.uk/
Requires Spotify Linux Preview.
"""
diff --git a/static/js/common/fxa-login.js b/static/js/common/fxa-login.js
index 2f6428b..9ff32c4 100644
--- a/static/js/common/fxa-login.js
+++ b/static/js/common/fxa-login.js
@@ -32,13 +32,20 @@ function enableFxALogin() {
});
}
+ // utf-8 handling from https://mzl.la/1LwX2Zx
+ function utf8Tob64(str) {
env:
- SLIMERJSLAUNCHER=$(which firefox) DISPLAY=:99.0 PATH=$TRAVIS_BUILD_DIR/slimerjs:$PATH
addons:
firefox: "24.0"
before_script:
- "sh -e /etc/init.d/xvfb start"
- "echo 'Installing Slimer'"
- "wget http://download.slimerjs.org/v0.8/slimerjs-0.8.3.zip"
- "unzip slimerjs-0.8.3.zip"
- "mv slimerjs-0.8.3 ./slimerjs"
ro.secure=0
ro.allow.mock.location=1
ro.debuggable=1
persist.usb.serialno=full_inari
persist.sys.usb.config=adb
From ad155917679b816451cbfeeec69865ab7506119d Mon Sep 17 00:00:00 2001
From: Daniel Sabelnikov <dsabelnikov@gmail.com>
Date: Sun, 3 May 2015 22:59:14 +0300
Subject: [PATCH] Add "libtermkey" key bindings preset
---
plists/PresetKeyMappings.plist | 381 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 381 insertions(+)
diff --git a/plists/PresetKeyMappings.plist b/plists/PresetKeyMappings.plist
@muffinresearch
muffinresearch / gplus-noyoutube.user.js
Created November 8, 2011 12:02
This script adds styles to remove the youtube link widget from G+
// ==UserScript==
// @name Remove Youtube Links from Google+
// @namespace http://muffinresearch.co.uk
// @author Stuart Colville
// @match https://plus.google.com/*
// @description This script adds styles to remove the youtube link widget from G+
// ==/UserScript==
window.addEventListener("load", function(e) {
var sheetNode = document.createElement('style');
@muffinresearch
muffinresearch / svg2png.js
Created July 16, 2015 13:42
svg2png config example
module.exports = {
all: {
// specify files in array format with multiple src-dest mapping
files: [
// rasterize all SVG files in "img" and its subdirectories to "img/png"
{ cwd: 'public/svg/', src: ['**/*.svg'], dest: 'public/img/' }
]
}
};