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
#!/bin/sh | |
# Implementation of http://tantek.pbworks.com/NewBase60 | |
# License: http://creativecommons.org/licenses/by-sa/3.0/ | |
n="$1" | |
s='' | |
m='0123456789ABCDEFGHJKLMNPQRSTUVWXYZ_abcdefghijkmnopqrstuvwxyz' | |
if [ -z "$n" ] || [ "$n" -eq "0" ]; then | |
echo 0 |
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
#!/usr/bin/env ruby | |
# 1. export your RIL bookmarks | |
# 2. save this file to the same directory where your ril_export.html is | |
# 3. change username and password in the script bellow | |
# 4. run 'ruby ril_to_instapaper.rb' in terminal | |
require "cgi" | |
require "net/http" | |
require "net/https" |
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
(* | |
Jered Benoit | |
jeredb.com | |
Omnifocus -> Day One Daily Completed Task Log | |
Based upon [Version 1.0] [1] of [OmniFocus - Weekly Project Report Generator] [2] | |
Originally Authored by Chris Brogan and Rob Trew | |
February 5, 2012 |
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
# LICENSE: public domain | |
def calculate_initial_compass_bearing(pointA, pointB): | |
""" | |
Calculates the bearing between two points. | |
The formulae used is the following: | |
θ = atan2(sin(Δlong).cos(lat2), | |
cos(lat1).sin(lat2) − sin(lat1).cos(lat2).cos(Δlong)) |
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
#!/bin/sh | |
# | |
# Shell script that configures gnome-terminal to use solarized theme | |
# colors. Written for Ubuntu 11.10, untested on anything else. | |
# | |
# Solarized theme: http://ethanschoonover.com/solarized | |
# | |
# Adapted from these sources: | |
# https://gist.github.com/1280177 | |
# http://xorcode.com/guides/solarized-vim-eclipse-ubuntu/ |
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
#!/bin/sh | |
TODAY=$(date +%m) | |
FILE=~/.duesoon | |
# This may be more complex than need be, but it permits months with or without leading zeroes | |
let THISMO=$TODAY-0 | |
if [ $THISMO = 12 ]; then | |
let NEXTMO=01 | |
else |
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
tell application "OmniFocus" | |
tell document 1 | |
tell (first document window whose index is 1) | |
set SelectedItemInMainView to selected trees of content | |
repeat with i from 1 to (count of SelectedItemInMainView) | |
set theSelectedTask to value of item i of SelectedItemInMainView |
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
property newContextName : "txfr" --context the item will change to if changeContext = true | |
tell application "Finder" | |
set the clipboard to "" | |
end tell | |
tell application "OmniFocus" | |
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
/** | |
* Extend Recent Posts Widget | |
* | |
* Adds different formatting to the default WordPress Recent Posts Widget | |
*/ | |
Class My_Recent_Posts_Widget extends WP_Widget_Recent_Posts { | |
function widget($args, $instance) { | |
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
RED="\[\033[0;31m\]" | |
YELLOW="\[\033[0;33m\]" | |
GREEN="\[\033[0;32m\]" | |
BLUE="\[\033[0;34m\]" | |
LIGHT_RED="\[\033[1;31m\]" | |
LIGHT_GREEN="\[\033[1;32m\]" | |
WHITE="\[\033[1;37m\]" | |
LIGHT_GRAY="\[\033[0;37m\]" | |
COLOR_NONE="\[\e[0m\]" |
OlderNewer