Skip to content

Instantly share code, notes, and snippets.

View daniel-barrows's full-sized avatar

Daniel Barrows daniel-barrows

View GitHub Profile
@daniel-barrows
daniel-barrows / Copy direct link to Gmail email.md
Last active August 18, 2023 16:54 — forked from alangrainger/Copy direct link to Gmail email.md
Copy a direct link to a Gmail email to your clipboard
@daniel-barrows
daniel-barrows / anbox-dependencies.control
Created April 12, 2019 16:22
anbox build dependencies installer deb control file (for equivs)
### Commented entries have reasonable defaults.
### Uncomment to edit them.
# Source: <source package name; defaults to package name>
Section: misc
Priority: optional
Homepage: http://anbox.io/
Standards-Version: 3.9.2
Package: anbox-dependencies
Version: 0.1.0
@daniel-barrows
daniel-barrows / colorTable.js
Last active March 22, 2019 11:56
Change background color of cells in a table containing boolean values
/*
Author: Daniel Barrows
Copyright: 2019
License: Public Domain
Status: beta
*/
function color_table( selector = '.markdown-body td' ){
Array.from(document.querySelectorAll(selector)).forEach(function(i){
switch(i.innerText){
@daniel-barrows
daniel-barrows / rtm-thunderbird.js
Last active February 21, 2019 16:08
The beginnings of a Thunderbird extension to convert an email to a RememberTheMilk task.
// License: GPLv3+
// Author: 2019 Daniel Barrows
// Status: pre-alpha
// Canonical URL: https://gist.github.com/daniel-barrows/c4345cfc22f3e8e6032d130ab11cbdf4
// require jquery
// Tested with jquery 1.12.4 and jquery-ui 1.12.1 at https://jqueryui.com/resources/demos/dialog/default.html
// Require Thunderlink
// Feature request:
@daniel-barrows
daniel-barrows / firefox-cookie-settings
Last active October 25, 2020 11:35
Export domain-specific cookie preservation settings from Firefox to a readable CSV format.
@daniel-barrows
daniel-barrows / ubygems-workaround.sh
Last active October 22, 2018 19:37
Workaround for ubygems.rb / -rubygems parameter feature abruptly removed from Ruby. See https://bugs.ruby-lang.org/issues/14322
#!/bin/sh
# Copyright:: 2018 Daniel Barrows
# License:: zlib/libpng
# https://gist.github.com/daniel-barrows/ca8359b76ad9bb84b37593a9f7b695fc
#
# Workaround for feature abruptly removed from Ruby.
# See https://bugs.ruby-lang.org/issues/14322
# Leave warn variable empty to not output the deprecation warning.
warn=true
@daniel-barrows
daniel-barrows / gtk-icon-path.py
Last active September 24, 2018 15:05
Output the filepath(s) of any GTK icon names provided as arguments.
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# https://gist.github.com/daniel-barrows/3a42d6ac96559534a7a52172083730c2
__copyright__ = "2018 Daniel Barrows"
__license__ = "Public Domain"
__status__ = "production"
import sys
import gi
gi.require_version('Gtk', '3.0')
@daniel-barrows
daniel-barrows / speedcrunch-color-update.sh
Last active September 23, 2018 16:16
Download the latest SpeedCrunch color schemes and install them for the current user. Workaround for an Ubuntu bug: https://bugs.launchpad.net/ubuntu/+source/speedcrunch/+bug/1729575
#!/bin/bash
# Name:: speedcrunch-color-update.sh
# Copyright:: 2018 Daniel Barrows
# Licence:: zlib/libpng
# Status:: beta
mv_args="$@"
branch_url=https://bitbucket.org/heldercorreia/speedcrunch.git
tmpdir="$( mktemp --directory speedcrunch-color-update-XXX )"
@daniel-barrows
daniel-barrows / .block
Last active December 1, 2017 23:04 — forked from ChrisManess/.block
Criminal Procedures
license: gpl-3.0
@daniel-barrows
daniel-barrows / mailman-subscribers.py
Last active November 27, 2017 14:02
Scrape mailman web pages to list subscribers. Mirror of http://fog.ccsf.edu/~msapiro/scripts/mailman-subscribers.py
#!/usr/bin/env python
# vi: set et sw=4 st=4:
#
# 2004-08-27 Jim Tittsler <jwt@starship.python.net>
# 2004-10-03 jwt change authentication
# 2004-10-04 jwt remove dependency on ClientCookie
# 2004-10-07 jwt use getopt to retrieve host, list, password from command
# 2004-10-10 jwt return to using ClientCookie
# 2004-10-13 jwt add --fullnames option
# 2005-02-15 jwt switch on RFC2965 cookie support when newer version