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
tell application "Mail" | |
set m to (selection) | |
set s to (extract address from sender of item 1 of m) | |
set r to rule "Archive" | |
tell r to make new rule condition at end of rule conditions with properties {rule type:from header, qualifier:does contain value, expression:s} | |
end tell |
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
tell application "Finder" | |
set sel to the selection as text | |
set fPath to quoted form of POSIX path of sel | |
do shell script ("cat " & fPath & " | pbcopy && pbpaste") | |
end tell |
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
tell application "Finder" to set filePath to quoted form of (POSIX path of (the selection as alias)) | |
do shell script "cat " & filePath & " | pbcopy" |
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
{ | |
"extensions": | |
[ | |
"md", | |
"mdown", | |
"mmd" | |
], | |
"trim_trailing_white_space_on_save": false, | |
"font_face": "Pitch Medium", | |
"font_size": 15, |
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
html { | |
background-color: #f2f2f2; | |
color: #333; | |
} | |
body { | |
margin: 10%; | |
padding: 0; | |
border: 0; | |
font-size: 16px; | |
line-height: 1.6; |
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
tell application "Safari" to set recipetitle to name of front document | |
tell application "Safari" to set recipeurl to URL of front document | |
set ingredients to (do shell script "curl http://recipedistiller.com/recipe/classify/?recipeurl=" & recipeurl & " | textutil -convert txt -stdin -stdout | grep '.' | sed 's/ • DELETE //g' | sed '$d'") | |
set my text item delimiters to "VIEW RECIPE" | |
set ingredients to text item 2 of ingredients | |
set my text item delimiters to "©" | |
set ingredients to text item 1 of ingredients |
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
{ "keys": ["super+ctrl+1"], "command": "insert_snippet", "args": {"contents": "# $0"}, "context": | |
[ | |
{ "key": "setting.auto_match_enabled", "operator": "equal", "operand": true }, | |
{ "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, | |
{ "key": "following_text", "operator": "regex_contains", "operand": "^(?:\t| |\\)|]|\\}|$)", "match_all": true }, | |
{ "key": "preceding_text", "operator": "not_regex_contains", "operand": "['a-zA-Z0-9_]$", "match_all": true }, | |
{ "key": "eol_selector", "operator": "not_equal", "operand": "string.quoted.single", "match_all": true }, | |
{ "key": "selector", "operator": "equal", "operand": "text.html.markdown", "match_all": true } | |
] | |
}, |
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
Add this to ~/Library/Application Support/Sublime Text 2/Packages/MarkdownEditing/Default (OSX).sublime-keymap | |
Will surround selected text with <del> tags when you type a tilde (~). Only works when text is selected. | |
Get Brett Terpstra's MarkdownEditing here: http://ttscoff.github.com/MarkdownEditing/ | |
{ "keys": ["~"], "command": "insert_snippet", "args": {"contents": "<del>${0:$SELECTION}</del>"}, "context": | |
[ | |
{ "key": "setting.auto_match_enabled", "operator": "equal", "operand": true }, | |
{ "key": "selection_empty", "operator": "equal", "operand": false, "match_all": true }, | |
{ "key": "selector", "operator": "equal", "operand": "text.html.markdown", "match_all": true } |
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
# Easy Planter | |
# by Jonathan Poritsky http://candlerblog.com | |
# | |
# Run script to walk you through creating new file trees with Brett terpstra's Planter.rb | |
# For more info on Planter see Brett's original post: | |
# http://brettterpstra.com/planter-tree-planting-for-your-filesystem/ | |
# | |
# Note: Script does an mdfind to locate "planter.rb". If you've renamed planter then this will not work. Noted below how to change. | |
tell application "Finder" |
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
{ | |
"cmd": ["dayone new < $file"], | |
"path": "/usr/local/bin/", | |
"shell": "true" | |
} |