#MindNode URL Schemes
###Launch MindNode mindnode://
####Examples mindnode://
###Open Document
| #!/usr/bin/env ruby -wKU | |
| # Adapted from Brett Terpstra’s original “Markdown to Evernote” service (http://brettterpstra.com/a-better-os-x-system-service-for-evernote-notes-with-multimarkdown/) | |
| # Martin Kopischke 2011 – License: Creative Commons Attribution Share-Alike (CC BY-SA) 3.0 Unported (http://creativecommons.org/licenses/by-sa/3.0/) | |
| # Changes: – create only one Evernote note per (Multi)Markdown input passed (instead of one per line) | |
| # – do not choke on shell escape characters (use Tempfile instead of shell pipe for osascript) | |
| # – default to MultiMarkdown 3 executable (instead of MMD 2 Perl script) | |
| # – make smart typography processing optional (set SMARTY to 'false' to bypass processing; | |
| # note smart typography cannot be disabled in MMD 3.0 and 3.0.1 | |
| # – handle both smart typography processing scripts (ie. SmartyPants.pl) |
| ## | |
| # Let's see what we can figure out about Ruby's handling of slashes in weird | |
| # places. Regex, or division? | |
| class Array; def / *args; puts "array #{self.inspect} divided by: " + args.inspect; return args; end; end | |
| class String; def / *args; puts "string #{self.inspect} divided by: " + args.inspect; return args; end; end | |
| def bar *args | |
| args.inspect | |
| end | |
| abc = ["abc"] |
| javascript:(function({ | |
| var INSTAPAPER=true,w=window,d=document,pageSelectedTxt=w.getSelection?w.getSelection():(d.getSelection)?d.getSelection():(d.selection?d.selection.createRange().text:0),pageTitle=d.title,pageUri=w.location.href,tmplt=""; | |
| tmplt="From ["+pageTitle+"]("+pageUri+"):\n\n"; | |
| if(pageSelectedTxt!="") { | |
| pageSelectedTxt=">%20"+pageSelectedTxt; | |
| pageSelectedTxt=pageSelectedTxt.replace(/(\r\n|\n+|\r)/gm,"\n"); | |
| pageSelectedTxt=pageSelectedTxt.replace(/\n/g,"\n>%20\n>%20"); | |
| w.location.href="nvalt://make/?txt="+encodeURIComponent(tmplt+pageSelectedTxt)+"&title="+encodeURIComponent(pageTitle) | |
| } | |
| else { |
| // Use Gists to store code you would like to remember later on | |
| console.log(window); // log the "window" object to the console |
#MindNode URL Schemes
mindnode://
mindnode://open?name=&folder=
mindnode://open?name=todos
mindnode://open?name=my%20next%20presentation
mindnode://open?name=my%20next%20presentation&folder=presentations
| #!/usr/bin/env ruby | |
| # encoding: utf-8 | |
| # tag primary folders =Tagname | |
| # target them with #Tagname | |
| # tag subfolders with @nickname | |
| # target them with :nickname | |
| # if no tagged folder exists but there's a matching folder name, that's used | |
| # otherwise it will create folders based on :tags | |
| # :tags can be strung together :bt:Drafts:testing for nesting | |
| # Only one #Tag and one :path should exist in a file's tags |
| tell application "Safari" | |
| set current_tab to current tab of front window | |
| set tab_title to name of current_tab | |
| set tab_address to URL of current_tab | |
| tell application "Spillo" | |
| show create bookmark panel with properties {url:tab_address, title:tab_title} | |
| end tell | |
| end tell |
| { | |
| "icons": { | |
| "unicode here without \ or extra characters": { | |
| "name" : "some name" | |
| } | |
| } | |
| } |