Skip to content

Instantly share code, notes, and snippets.

@maripo
maripo / createnote.applescript
Created March 5, 2013 02:22
Evernote Local API Command Line Proxy
--------------------------------------------------
-- createnote.applescript
-- Evernote Command Line Proxy
-- by Maripo Goda <goda.mariko[at]gmail.com>
-- Required:
-- Mac OS X + AppleScript
-- Evernote for Mac OS X
-- Perl + JSON.pm
-- Usage:
-- Create a note with text
@colindean
colindean / get_prices_db.rb
Created March 4, 2013 06:00
Get BTC price history from BitcoinCharts and output in ledger prices_db format
#!/usr/bin/env ruby
# Set these to what you'd like
symbol = "mtgoxUSD"
ledger_currency = "$"
ledger_btc = "BTC"
start_date = "2013-01-01"
end_date = Time.now.to_i
# shouldn't really need to change anything after here
require 'open-uri'
@gavrix
gavrix / gist:5054182
Created February 28, 2013 04:28
Script integrating OCLint into XCode. Put it in "Run script" build phase.
source ~/.bash_profile
hash oclint &> /dev/null
if [ $? -eq 1 ]; then
echo >&2 "oclint not found, analyzing stopped"
exit 1
fi
@tlehman
tlehman / viscosity_connect.applescript
Created February 26, 2013 19:06
Connect Viscosity VPN client for current user FROM THE COMMAND LINE
#!/usr/bin/env osascript
on run argv
tell application "Viscosity"
Connect argv
end
end
@ttscoff
ttscoff / mailplane.css
Created February 17, 2013 13:59
MailPlane CSS for GMail grey theme
/* This stylesheet is designed to work with the grey theme for GMail
- hides the top bar and Google+ notifications
- simplifies buttons (remove border/background, add hover state back)
- dim Rapportive until hovered
This is only partially tested at this point and may cause some issues
Please let me know if you find problems: <http://brettterpstra.com/contact/>
Brett Terpstra 2013 <http://brettterpstra.com> /*
@mfcabrera
mfcabrera / thingsexporttodos.rb
Last active December 13, 2015 17:38
A script using MacRuby to export all the todos from Things projects into text files (my goal is to "copy and paste" them into 2DO.
#make sure you use macruby
framework "ScriptingBridge" #let's use the scripting bridge framework
# this is aweful - maybe a wrapper would be nice
# you can ge this BundleIdentifier using the mdls
# mdls -name kMDItemCFBundleIdentifier /Applications/Things.app
things = SBApplication.applicationWithBundleIdentifier("com.culturedcode.things")
tell application "Safari"
set vURL to URL of current tab of window 1
end tell
tell application "Google Chrome"
if windows ≠ {} then
make new tab at the end of window 1 with properties {URL:vURL}
else
make new window
set URL of (active tab of window 1) to vURL
@dakotasmith
dakotasmith / geeklet_mgr.scpt
Created January 30, 2013 18:51
Applescript which activates and deactivates groups of Geeklets within Geektool, depending on resolution width.
tell application "Finder"
set _b to bounds of window of desktop
set _width to item 3 of _b
set _height to item 4 of _b
end tell
tell application "GeekTool Helper"
if _width > 1367 then
set visible of group "Desk" to true
set visible of group "11 inch screen" to false
@mrbanzai
mrbanzai / hack.sh
Last active December 11, 2015 22:29 — forked from DAddYE/hack.sh
#!/bin/sh
##
# This is a script with usefull tips taken from:
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
#
# Run in interactive mode with:
# $ sh -c "$(curl -sL https://raw.github.com/gist/2108403/hack.sh)"
#
# or run it without prompt questions:
@poritsky
poritsky / gist:4660217
Created January 28, 2013 23:20
Copy contents of file. (For use with copying contents of text files)
tell application "Finder" to set filePath to quoted form of (POSIX path of (the selection as alias))
do shell script "cat " & filePath & " | pbcopy"