Of all the Weird Al videos that have been released so far over his 8-day streak, this one is my favorite. It's clever and well-animated.

07/18/14; 08:41:18 AM

Pushbullet is the best service I've seen so far that will allow me to push info from my phone to my work computer and vice versa. (I cannot install Command-C at the office.) I installed the Chrome extension and the iPhone app. From the Chrome extension, I can push a note or a list to the iOS app. This in itself is unremarkable -- I use Pushover all the time for that. But the killer feature is that I can send a link to my phone, and the moment I swipe the notification, that URL will open in the Chrome browser. And if I send an address to my iPhone, after I swipe the notification Google Maps will open to that location.

Also, I can quickly send the clipboard contents on my iPhone to the desktop extension. This is a lot faster than emailing text to myself or uploading it to Dropbox via Drafts or Launch Center Pro.

IFTTT

There's an IFTTT channel that allows you to push a note, link, file or address to your iPhone. I haven't played around with this, but there are many shared recipes for the channel, and I imagine you can create a recipe to automatically send images from a feed to your device.

URL Schemes

Pushbullet has URL schemes. Bachya wrote this bookmarklet to send the current page in your iOS web browser to the Pushbullet app:

javascript:window.location='pushbullet://compose?type=link&title=' + encodeURIComponent(document.title) + '&url=' + encodeURIComponent(window.location)

The Only Downside: Google

I've been working to become less reliant on Google -- for example, moving to Fastmail.fm. With Pushbullet, you can only sign in with Google, and you have no choice but to open links and addresses in Google Chrome and Google Maps. Granted, their iOS maps app is my default, and I use Chrome for Mac at work, but I still would prefer to have a choice.

Pushbullet vs. Pushover

I have been using my Pushover command line script to send text to my phone, and after a recent release, now a swipe of a Pushover notification will open a supplementary URL (if available). This is great, because I can execute Drafts actions with a swipe of a notification. For example I can make my message an URL and the Drafts action "launch url" (which is just launch://?url=[[draft]]). This will open a link in Safari for iOS with a single swipe. However, it is definitely less work for me to just open the Pushbullet extension and send a link to my phone that way.

I will continue to use my Pushover script to execute actions in Drafts, but Pushbullet is more convenient if I just want to quickly send text or a link to my phone.

07/11/14; 12:21:20 PM

I am constantly fidgeting with my productivity apps and system. I was engaged to Paperless for many months, but now I am playing with Todo.txt on the command line and on iOS. As a result, I've been thinking about types of lists and the most appropriate apps for each type of list.

1. Actionable Tasks

These lists include only tasks that require a physical (measurable/observable) action to mark as complete. This is what the GTD system is all about. Over the years I have used Omnifocus, TaskPaper, Paperless, and now Todo.txt. I have found that -- for me -- text-file-based apps are the best (TaskPaper, Todo.txt). They both support tags/contexts (the @ sign) and projects (the + sign in Todo.txt; a string followed by a : for TaskPaper). I can open them in any text editor, or I can manipulate the text in supported apps. (Jesse Grosjean removed his TaskPaper app from the iOS App Store, but fortunately Ole Zorn created an excellent TaskPaper module for Editorial.)

1a. Actionable Tasks With "Hard" Due Dates

Some actionable tasks need to be done at a very specific time, or by a very specific time. "Mail the DVD at 8:30am" or "Go to Trader Joe's at 6pm." These I put in Due or Fantastical/iOS Reminders.

2. "Consumption" Lists

These are items that I want to consume: books, movies, music tracks, groceries. None of this is urgent (well, except for food). These items do require checkboxes, because once I've rented/downloaded/borrowed/purchased the item, I don't need to do it again (... except for food). I am still using Paperless for this, because the app provides a note field where I can include all the meta info I need (URLs, for example, or who suggested a particular book). And in Paperless, I can uncheck a grocery item to re-add it to my shopping list.

3. Ideas Lists

I have a list that is more-or-less called, "Things I Need to Remember to Do at Home to Avoid the Wrath of My Wife." Another is "Lunch Ideas." These items should not have checkboxes, because they are reference materials, not one-time (or even recurring) tasks. Right now I have these lists in Listary which pulls notes with a specific tag from Simplenote. You can toggle a setting for a list in Paperless to remove checkboxes and just use the list as a reference. I have also used Carbonfin Outliner with the checkboxes toggled off for these types of lists.


Of course, one can store all these lists in simple text files and store them in a single directory. nvAlt fans do this. But am I either in front of my phone or a work computer, and I cannot sync Dropbox at work. (One can sync an nvAlt folder with Dropbox.) Although I feel too spread out with my various list apps, I do believe that the ultimate test is whether my system supports both "brain dump" and "information access." Can I quickly note down an idea or todo? And can I easily find it later? Part of my problem is that I don't always recall where I put a todo. With this three-part categorical division, I hope I can better recall a todo's location. If it's actionable, it's in Todo.txt or iOS Reminders; if it's about something I want to buy, it's in Paperless; if it's an evergreen list, it's in Listary. We'll see how it goes.

07/11/14; 09:59:17 AM

If you're trying to wrap your head around url schemes, encoding and x-callback-url, listen to this excellent podcast in which the hosts of Pocket Sized Podcast interview Alex Guyot.

Here's the link to the .m4a file.

07/11/14; 08:48:55 AM

I recently created an IFTTT recipe to add the first url mentioned in a tweet to Instapaper if I favorite the tweet. Now I am concerned that someone will interpret my favorite as condoning the content of a tweet, whereas all it means is that I want to "read it later." A favorite is not the equivalent of a on Facebook.

07/10/14; 04:02:39 PM

The newest version of my action (import it into LCP) includes priorities A-C.

texttool://x-callback-url/transform?text=[list|clipboard=[clipboard]|prompt=[prompt-return:tasks]]&method=affix&prefix=[-list:priorities|A=%28A%29%20|B=%28B%29%20|C=%28C%29%20|none={{}}][textexpander:ddate]%20&suffix=[-list|no context={{}}|@online=%20%40online|contexts=%20%40[prompt-list( @)]][-list|no project={{}}|+Bills=%20%2BBills|projects=%20%2B[prompt-list( +)]]&scope=lines&x-success={{drafts:///create?text=[[output]]&action=todotxt}}

So now you can send something like the following to Drafts:

(A) 2014-07-10 complete task @context +project

This works with the Todo.txt command line interface and the iPhone app.

Visit the first post in this series to get the Drafts Dropbox action, and the second one for more about the contexts and projects.

07/10/14; 01:24:31 PM

Yesterday I posted a Launch Center Pro action to prepend the date and append a single tag to all the items in a list, and then append that text to a file in Dropbox. Since then, I have been using the todo.txt command line tool and decided to upgrade the action.

This action lets you enter a task and then enter either (a) no tag (I prefer that to "context"); (b) a tag called @online; (c) any number of tags; followed by (d) no project; (e) a project called +bills; (f) any number of projects. To enter multiple tags or projects you need to hit Return after each, and then Next only when you're done.

Import the new action. Or enter the following in the action composer:

texttool://x-callback-url/transform?text=[prompt-return:tasks]&method=affix&prefix=[textexpander:ddate]%20&suffix=[-list|no tag={{}}|@online=%20%40online|tag=%20%40[prompt-list( @)]][-list|no project={{}}|+Bills=%20%2BBills|project=%20%2B[prompt-list( +)]]&scope=lines&x-success={{drafts:///create?text=[[output]]&action=todotxt}}

If you can decipher this action then you ought to be able to customize it, e.g., add +work in the projects list.

07/09/14; 01:45:33 PM

A blog reader emailed the following question:

I have texttool, draft and LCP apps on my iphone.

Please help me this issue.

I have todo.txt file in directory dropbox/todo/todo.txt

I write in draft app one note with multiline line:

Task1

Task2 

Task3 

I want to add this list to shown todo.txt (each line separate) in this format:

[current date] task1 @grocery 

[current date] task2 @grocery 

[current date] task3 @grocery 

@grocery tag optional and may be replaced with other tag.

How to do this?

Here is a solution that adds the current date before each list item and the single tag of your choice after each list item.

Import the LCP action or enter the following in the action composer:

texttool://x-callback-url/transform?text=[prompt-return:tasks]&method=affix&prefix=[textexpander:ddate]%20&suffix=%20%40[prompt:tag]&scope=lines

When I tap on this action, I enter each list item on a new line (hitting Return after each item except the last) and when I'm done I hit "Next".

apple

orange

banana

Then the next prompt asks me to enter a tag:

groceries

The action outputs the following in TextTool:

2014-07-08 apple @groceries

2014-07-08 orange @groceries

2014-07-08 banana @groceries

The above action requires that I have a TextExpander snippet called ddate in the following format: %Y-%m-%d, and that I have imported snippets into Launch Center Pro.

Prepending the Output to the todo.txt File

Import this action to prepend the output from TextTool to your todo.txt file, or enter the following into the LCP action composer:

texttool://x-callback-url/transform?text=[prompt-return:tasks]&method=affix&prefix=[textexpander:ddate]%20&suffix=%20%40[prompt:tag]&scope=lines&x-success={{drafts:///create?text=[[output]]&action=todotxt}}

The above action requires that you import this Dropbox action into Drafts. Or enter the following as a Dropbox action:

Name: todotxt

Path: /todo/

File (predefined): todo

Ext: txt

Write: Prepend

Template: [[draft]]

It is possible to accomplish the above without LCP. Import this URL action into Drafts, or enter the following as an URL action:

texttool://x-callback-url/transform?text=[[body]]&method=affix&prefix=ddate%20&suffix=%20%40[[title]]&scope=lines&x-success={{drafts:///create?text=[[output]]&action=todotxt}}

The only difference is that you need to enter the tag name on the first line:

groceries

apple

orange

banana

Everything else works exactly the same. (You still need to install the Dropbox action and to import TextExpander snippets.)

07/08/14; 11:51:00 AM

SoundCloud has url schemes to jump to a user or a specific track in the iOS app. I have cobbled the following together after reading a few threads on Stack Overflow.

How to Create a User URL Scheme

Let's get the url scheme for Tasha Blank. Click on the share icon then choose the Embed tab and then copy the embed code into a text editor.

<iframe width="100%" height="450" scrolling="no" frameborder="no" src="https://w.soundcloud.com/player/?url=https%3A//api.soundcloud.com/users/325143&amp;auto_play=false&amp;hide_related=false&amp;show_comments=true&amp;show_user=true&amp;show_reposts=false&amp;visual=true"></iframe>

Look for api.soundcloud.com/users/. Copy the numerical string immediately after that, up until the &. Put that string after soundcloud://users/ and you'll get soundcloud://users/325143. If you click on this link on your iOS device, it will bring you to her page. And you can add it to Launch Center Pro in an action or list.

How to Create a Track URL Scheme

Let's get the url scheme for one of Tasha's recent tracks. Click on the share icon then choose the Embed tab and then copy the embed code into a text editor.

<iframe width="100%" height="450" scrolling="no" frameborder="no" src="https://w.soundcloud.com/player/?url=https%3A//api.soundcloud.com/tracks/156299506&amp;auto_play=false&amp;hide_related=false&amp;show_comments=true&amp;show_user=true&amp;show_reposts=false&amp;visual=true"></iframe>

Look for api.soundcloud.com/tracks/. Copy the numerical string immediately after that, up until the &. Put that string after soundcloud://tracks/ and you'll get soundcloud://tracks:156299506. If you click on this link on your iOS device, it will bring you to that track and start to auto-play. And you can add it to Launch Center Pro in an action or list.

 

I don't know how else to get track and user IDs without signing up for a developer account, but if you find a solution, please let me know in the comments or on Twitter.

07/08/14; 10:05:06 AM

If you're browsing the Tumblr or Instagram apps on your iOS device and want to get the share URL, they are formatted as follows:

http://NAME.tumblr.com/post/POST_ID/SLUG

http://instagram.com/p/POST_ID

Unfortunately, these are web links. What if you want a link that will bring you right to that post ID in the app? I have written a couple of Launch Center Pro actions to automate these processes.

Tumblr

The URL scheme for a Tumblr post (as per GitHub) is as follows:

tumblr://x-callback-url/blog?blogName=NAME&postID=POST_ID

All the information you need is in the web link, but you need to rearrange it all to make it work.

Import the Tumblr action or enter the following into LCP:

texttool://x-callback-url/transform?text=[clipboard]&method=split&delimiter=%2F&lc-icon=tumblr&x-success={{texttool://x-callback-url/transform?text=[[output]]&method=split&delimiter=.&x-success={{drafts:///create?text=[[output]]&action=tumblr-id}}}}

To make this action work, you will also need TextTool and Drafts. And you will need to import this URL action into Drafts.

Let's work with a random Tumblr post to see how this works:

http://yahoo.tumblr.com/post/90564142294/furthering-our-focus

Copy this URL to your iOS clipboard, and then tap on the Tumblr action in LCP. LCP sends this string to TextTool, which splits the string at the /:

http:



yahoo.tumblr.com

post

90564142294

furthering-our-focus

It then takes that output and sends it back to TextTool to split at the .:

http:



yahoo

tumblr

com

post

90564142294

furthering-our-focus

It then sends that output to Drafts and triggers the tumblr-id URL action:

drafts:///create?text={{tumblr://x-callback-url/blog?blogName=[[line|3]]&postID=[[line|7]]}}

This action inputs lines 3 and 7 of the draft into the relevant points of the url scheme, and creates a new draft with the final result:

tumblr://x-callback-url/blog?blogName=yahoo&postID=90564142294

And just to make the action icon look nice, I added lc-icon=tumblr.

Instagram

The Instagram action is more complicated. It requires TextTool, Drafts, and Textastic. Import the LCP action or enter this into a new action:

textastic://api.instagram.com/oembed?url=[clipboard]&lc-icon=instagram&lc-callback=[list|url=texttool://x-callback-url/transform?text=[clipboard]&method=split&delimiter=%22&x-success={{drafts:///create?text=[[output]]&action=insta-api}}|image=texttool://x-callback-url/transform?text=[clipboard]&method=split&delimiter=%22&x-success={{drafts:///create?text=[[output]]&action=insta-api-url}}]

Instagram's url scheme for a post is as follows (as per its iPhone Hooks page):

instagram://media?id=MEDIA_ID

The media ID is not part of the web URL. But we can get that info from Instagrams's Embed API. Let's use an example post (http://instagram.com/p/qJu0a-OHMC) and add it after the url=:

http://api.instagram.com/oembed?url=http://instagram.com/p/qJu0a-OHMC

This API returns JSON:

 {"provider_url":"http:\/\/instagram.com\/","media_id":"759343924702114562_1483611","title":"Another beautiful day in the city! \ud83d\ude0d","url":"http:\/\/photos-d.ak.instagram.com\/hphotos-ak-xfp1\/10537269_595401073912091_331298792_n.jpg","author_name":"newyorkcity","height":640,"width":640,"version":"1.0","author_url":"http:\/\/instagram.com\/newyorkcity","author_id":1483611,"type":"photo","provider_name":"Instagram"} 

We can see that the media_id is 759343924702114562_1483611. instagram://media?id=759343924702114562_1483611 would bring us right to that post in the app, but we need the LCP action to automate the process.

We first need an easy way to grab the HTML of the API results. Textastic has an url scheme that lets you download a file and open the HTML in the editor by replacing http:// with textastic://. The first part of the LCP action does just that. However, even though Textastic supports x-callback-url, it doesn't for this particular action. So we need to tap on the share button at top right of the screen after the HTML has downloaded, and choose "Copy All." Then we take advantage of a new feature introduced in LCP: lc-callback. For apps that do not support x-callback-url, this is the next best thing. We define the callback action, but instead of it triggering automatically after the first action, we double-tap on the home button (to get the app launcher) and choose LCP. Once we tap on LCP, the next action gets triggered.

Because the embed API also provides the raw image URL for the Instagram post, the lc-callback starts with a list. We can get the iOS url scheme ("url") or the raw image URL ("image"). Let's see what happens when you choose "url":

The entire HTML is sent to TextTool, which splits the string at ":

{

provider_url

:

http:\/\/instagram.com\/

,

media_id

:

759343924702114562_1483611

,

title

:

Another beautiful day in the city! \ud83d\ude0d

,

url

:

http:\/\/photos-d.ak.instagram.com\/hphotos-ak-xfp1\/10537269_595401073912091_331298792_n.jpg

,

author_name

:

newyorkcity

,

height

:640,

width

:640,

version

:

1.0

,

author_url

:

http:\/\/instagram.com\/newyorkcity

,

author_id

:1483611,

type

:

photo

,

provider_name

:

Instagram

}

This entire string is then sent to Drafts, and the insta-api action is triggered. Import it into Drafts or enter the following as an URL action:

drafts:///create?text={{instagram://media?id=[[line|8]]}}

It simply takes line 8 -- which contains the media_ID -- and inserts into into the URL scheme.

Now, if we would rather get the raw image URL, we choose "image" after the lc-callback. It also performs a " split and sends that output to Drafts, but it instead triggers the insta-api-url action. Import it into Drafts or enter the following URL action:

texttool://x-callback-url/transform?text=[[line|16]]&method=unescape

Line 16 -- the raw image URL -- is sent to TextTool. Why? All the forward slashes in the URL are "escaped"

   http:\/\/photos-d.ak.instagram.com\/hphotos-ak-xfp1\/10537269_595401073912091_331298792_n.jpg

so we have to unescape them:

   http://photos-d.ak.instagram.com/hphotos-ak-xfp1/10537269_595401073912091_331298792_n.jpg

This action stops at TextTool. It has sharing features, so you can do what you like with URL: e.g., download the image.

To make the action icon look nice, I added lc-icon=instagram.

Granted, this LCP action is not fluid. I think it would possible to perform the conversion without the "Copy All" and lc-callback using the JSON parser in Pythonista, but I'm not proficient enough to accomplish that as of this writing. If you write an action that accomplishes the conversion with fewer steps, I would love to hear from you in the comments section or on Twitter.

Thanks to @epramono and @youens on Twitter for helping me to understand LCP 2.3.x at a deeper level.

07/07/14; 01:38:49 PM

I use Paperless for the majority of my list-making on my iOS devices. I've already written how to mark an item as complete without using the app and how to view your lists on the web. Today, I am going to share a unix command line bash script to "print" incomplete items from a list.

I created a text file called "prl" and put it in /usr/local/bin/:

#! /bin/bash

list=$1

grep -A 1 \<dateCompleted\>\<\/dateCompleted\> ~/Dropbox/Paperless/$list.xml | sed -n 's:.*<itemName>\(.*\)</itemName>.*:\1:p'

I made it executable while in that directory: chmod +x prl

Now, to view the incomplete items in any list, I just type prl followed by the list name. If I have a list named Bills, I just type prl Bills and the script will output all bills that are due. (This script does not output the notes field.)

How It Works

All your Paperless lists are stored as XML files. I use grep to look for all items for which there is no completion date: <dateCompleted></dateCompleted> with -A 1 to also print out the lines immediately after each match (which are the list items themselves). Those results are piped into a sed which extracts any string sandwiched between <itemName> and </itemName>.

If I need to see a note, I can do a quick grep: grep -A 1 verizon ~/Dropbox/Paperless/Bills.xml. This will output all lines matching verizon plus the lines immediately following, including the XML tags. It's not pretty but it will get me the info I need (e.g., the due date).

<itemName>Verizon $100.00</itemName>

<itemNote>7/7</itemNote>
07/07/14; 11:30:32 AM

I'm amazed at all the stuff that's available:

Dropbox

An Evernote Client

A Twitter Client

I am a keyboard-shortcut fanatic; adding a note to Evernote with syntax like

geeknote create --title "A Title" --content "Some content." --tags "tag1"

beats the evernote.com web interface hands down.

Granted, the cli doesn't support images, and since I'm ssh-ing into a VPS I can't open media from the command line, but for quick data input/output, nothing beats it. (I'm faster at typing on a physical keyboard than on an iPhone.)

07/03/14; 11:53:19 AM

Today I have released v 2.0 of my plugin, which renders a Fargo OPML file on a WordPress page or blog post using a simple shortcode. The updated version supports the link-blog format (type="idea").

View the update and download the zip file here.

07/02/14; 10:42:41 AM

I take credit for none of the following (other than a few personal tweaks) -- just wanting to share this solution by Stephen May because it's so cool.

Evernote does not have much of an url scheme beyond evernote:// which is not terrible useful for productivity nerds. This solution creates a link that will bring you directly to the note of your choice. It requires Pythonista, Drafts, and Launch Center Pro.

First, you will need to grab some personal information about your Evernote account, and the only way I know how to find it is via the Mac OS X app. In the left sidebar, right-click on any note and get the note's link. At the beginning of the link, there will be a six digit string and another digit or two following an s. You will need this information for a future step.

Add the following to Pythonista. You can title it Evernote Link or whatever you like. Where it says evernote:///view/123456/s4/ you will replace the six digit string and the s4 with the information from the note link you copied from the desktop app. Where it says https://www.evernote.com/shard/s4/sh/ replace the s4 with the s.. from your original note link.

import clipboard

import sys

import webbrowser

import console

import urllib

mytext = (sys.argv[1])

head, sep, tail = mytext.rpartition('/')

parttwo = head.replace('https://www.evernote.com/shard/s4/sh/', '')

evernoteurl = ('evernote:///view/123456/s4/' + parttwo + '/' + parttwo + '/')

webbrowser.open('drafts://x-callback-url/create?text=' + evernoteurl + '&action=Copy%20to%20Clipboard&afterSuccess=Nothing')

Then add the following action in LCP:

pythonista://EvernoteLink?action=run&argv=[clipboard]

How to Get Your Link

Go to the Evernote app and tap on any note. Choose "Share " and then "Copy link." Then tap on the LCP action. After the script runs, the direct Evernote link will be in a new draft in Drafts, and also copied to the clipboard. If you make links clickable in Drafts and tap on the link, it will bring you right to that note in Evernote.

If you care about the privacy of your note, then tap on "Share " again and choose "Stop sharing." Your direct link will still work.

07/01/14; 08:37:23 AM

Tweet This Post

If you're a Fastmail.fm user, you can use this bookmarklet to automatically compose an email to your favorite person in Fastmail's web interface. The subject line is the title of the web page, and the body includes the link. Then just hit Cmd-Return to send.

javascript:window.location='https://www.fastmail.fm/action/compose/?to=username@domain.com&subject='+encodeURIComponent(document.title)+'&body='+encodeURIComponent(location.href)

(Make sure to replace username@domain.com with a working email address.)

Reference: Fastmail Wiki

06/30/14; 11:15:07 AM

Tweet This Post

Over the weekend I wanted to embed a video on my blog while on my iPad. The mobile YouTube site did not appear to offer an embed code, so I created a few actions to automate the process.

As an example, here is the starting URL https://m.youtube.com/watch?v=38lY-3g6mn8.

This browser bookmarklet -- I call it "TextTool Split" -- imports the URL into Drafts and triggers the "split" action:

javascript:window.location='drafts://x-callback-url/create?action=split&text='+encodeURIComponent(location.href)

The "split" URL action sends the URL to TextTool and splits the URL at the =.

texttool://x-callback-url/transform?method=split&delimiter=%3D&text=[[draft]]&x-success={{drafts://x-callback-url/create?text=[[output]]&action=line2-youtube}}

Import it here into Drafts.

The above action takes the original URL and creates a new draft:

https://m.youtube.com/watch?v

38lY-3g6mn8

It then triggers the line2-youtube action, which takes line 2, sticks it in the YouTube embed code, and saves all of that to the clipboard with the help of Launch Center Pro:

launch://clipboard?text={{<iframe width="560" height="315" src="//www.youtube.com/embed/[[line|2]]" frameborder="0" allowfullscreen></iframe>}}

Import it here into Drafts.

The result will be that the following is added to your clipboard, and you can paste it into your blog CMS:

<iframe width="560" height="315" src="//www.youtube.com/embed/38lY-3g6mn8" frameborder="0" allowfullscreen></iframe>

This action presumes that there are no additional paramaters in the URL. If your URL has something like &list= after the video ID, you will either have to manually remove that string or create an extra Drafts/TextTool action to split the results of line 2 at the & and to take line 1 of that output.

06/30/14; 09:03:42 AM

Tweet This Post

If you're a fan of Frozen, you may find this lol funny:

06/29/14; 02:04:56 PM

Tweet This Post

Happy Friends and Fargo are now working together.

The tweet below is just a headline copied from my "watched" Happy Friends tab in Fargo. It has the following attributes associated with it:

06/27/14; 12:06:35 PM

Fargo -- the CMS outliner I use to publish this site -- has the ability to publish to GitHub Pages. I have long wanted to do this. I don't want a *.smallpict.com blog, I want to publish to blog.jeffreykishner.com. I could do this back when Fargo was using Trex (its original CMS), but Dave Winer did a complete rewrite, and mapping a CNAME to a smallpict blog no longer worked. FargoPublisher is too complicated for me to set up, and I know just enough GitHub to push commits to a repository from a subdirectory in Dropbox, so I chose the latter route.

The problem I've encountered for months: I don't blog at home, and I cannot sync Dropbox at the computer where I do blog. Hence, I cannot push commits from /Dropbox/Apps/smallPicture/jkishner.github.io (where Fargo renders the HTML of my blog) to GitHub locally. I tried -- and failed -- to configure my AirPort Extreme at home to have a stable IP address so that I could SSH into my MacMini at home from another computer. That way I could sync Dropbox on my MacMini, and then push commits remotely to GitHub.

Only a few days ago, I realized that I have a "box" where I can do all this: the VPS that I rent from WiredTree. Over the past few days, I have installed GitHub, Dropbox, and the Dropbox CLI (command line interface) into the root of my VPS. It was complicated -- WiredTree had to install a parallel version of Python so that dropbox.py could work, and a sysadmin there also changed a key file to allow Dropbox to monitor all the folders in my account -- but I got it to work. Now I can blog on Fargo, ssh into my root, make sure Dropbox has synced my jkishner.github.io folder, and add/commit/push changes. I set up a CNAME redirect so that jkishner.github.io will be viewable at blog.jeffreykishner.com, and it all works.

I used to use a web service called Mover that allowed me to FTP all the files in a specific Dropbox folder to the /blog directory on jeffreykishner.com, but the GitHub solution is faster because only the updated files are uploaded -- not my entire blog -- when I want to publish.

06/26/14; 03:29:28 PM

Tweet This Post

If you get a Spotify share URL like http://open.spotify.com/album/3eAA4fvTVttgUlE43vRVMq and open it in Safari for iOS, use this bookmarklet to jump directly to that artist/album/track in the app:

javascript:window.location='spotify:'+(window.location.href);

To install, you can either set it as a bookmarklet in Safari for Mac and sync with iCloud, or do the following:

  1. Bookmark any page in Safari for iOS and call it Spotify.

  2. Go to edit bookmarks, and replace the URL of that bookmark with the javascript above.

06/19/14; 03:35:31 PM

Tweet This Post

I've written a previous post on how to schedule a text message for later with Due and Launch Center Pro. However, now that LCP's encoding grammar has simplified, I'd like to revisit the topic. First off, an action to save a text in Drafts:

drafts://x-callback-url/create?text={{launch://messaging?to=8005551212&body=[prompt]}}

Click on this link to import it onto your iOS device.

Tap on the action, enter your text message, and an encoded launch://messaging URL scheme is saved in Drafts. When you are ready to send the text message, just make links clickable and tap on the URL scheme. It will open the text message in Messages to the designated recipient (change 8005551212 to his or her cell number).

The Contact Picker

LCP now has a contact picker -- [contact] -- that will allow you to choose a contact when you start the action. I tried creating the action above by substituting the phone number with [contact] -- the action can be imported here -- but it does not work.

drafts://x-callback-url/create?text={{launch://messaging?to=[contact]&body=[prompt]}}

The problem is that the body text is not encoded, so you get something like this:

 

Screenshot by @tahewett

 

I could not figure out how to fix this, so I wrote a pretty complicated action that does do the job. (Import it here).

launch://x-callback-url/clipboard?text=[contact]&x-success={{texttool://x-callback-url/transform?text=[prompt:your message]&method=encode&clipboard=0&x-success={{drafts:///create?text={{launch://messaging?to=||clipboard||&body=[[output]]}}}}}}

How It Works

First, the action asks you to pick a contact, and the number you choose is saved to the clipboard.

Then the action prompts you to enter your message. TextTool url-encodes your message, but does not save it to the clipboard (because we need the clipboard for the contact's number).

Then the action tells Drafts to create a new draft, the launch://messaging action. The body of the message is the [output] value carried from TextTool, and the to field is the clipboard contents, which -- because it has carried over two different x-successes -- needs to use ||clipboard|| to work, as explained here:

/create URL scheme now supports a special “||clipboard||” tag within the text parameter, which will substitute the contents of the clipboard at the time the “create” URL is opened. This can be used in an x-success callback URL to allow capture of a clipboard value that changed before returning to Drafts. Note the pipe characters, not brackets. This tag is not evaluated other time, only on /create URLs when processed by Drafts.

06/19/14; 11:35:06 AM

Tweet This Post

Here is an example of an RSS feed for @newyorkcity. If you click on a link, you get to see the raw image. How I did it:

1. Use this IFTTT Recipe

Customize this IFTTT recipe with the Instagram profile you want to use, as well as the tag(s) you want. (Note: this recipe requires a Pinboard account, which requires a one-time fee.)

2. Wait Until the Recipe Has Been Triggered

Here is the newyorkcity_instagram tag for my Pinboard account. To get the RSS feed, I follow these instructions to get the following:

https://feeds.pinboard.in/rss/u:kishner/t:newyorkcity_instagram
06/18/14; 02:46:43 PM

Tweet This Post

The latest update to Launch Center Pro has made it easier to create nested lists. Previously one had to use launch://?url= but now that is no longer necessary. Here is an abridged version of my LCP action to open albums in Ecoute:

ecoute://play?terms=[[list:Artist|Eminem=[list:Album|Marshall Mathers|Recovery]|Foo Fighters=[list:Albums|The Colour and the Shape|There Is Nothing Left to Lose]|Pharrell Williams={{Pharrell Williams}}|Search=[prompt:Search]]]

When I tap on this action, it presents a list of artists (Eminem, Foo Fighters, Pharrell Williams, and "Search"). If I tap on either of the first two, I am presented with a list of albums, and when I tap on the album name, that album auto-plays in Ecoute. If I tap on Pharrell Williams, G I R L automatically plays because I only have one album by him in my library. And if I tap on Search I am presented with a prompt, and if my query matches something in my music library, then it starts playing. (Thanks to Eric Pramono @epramono for help encoding this last part.)

The key to this nested list is that the first list is surrounded by double brackets and the embedded lists are only surrounded by single brackets. Two brackets means don't encode this. Because the first list is not encoded, I have to encode Pharrell Williams in double curly brackets since his name does not included an embedded list. And the search prompt only needs single brackets because they encode the prompt text.

The Spotify URL scheme is a bit more complicated. Here is an abridged version of my Spotify action:

spotify:[[list:Pick a List|Ali Farka Touré={{http://open.spotify.com/artist/3mNygoyrEKLgo6sx0MzwOL}}|King's X=[list:|Xv=http://open.spotify.com/album/792TsZibmmEiOCL2rEoJvm|Please Come Home....Mr. Bulbous=http://open.spotify.com/album/2ZyMISUxP7MLzxZCZLHEHJ]|Yes=[list:|Fragile=http://open.spotify.com/album/4X6gq5bgpGXcHINlFWzriM|Relayer=http://open.spotify.com/album/6MK9yp7hFeOLeR7F1hsBp6]]]

When I click on this action I would be presented with Ali Farka Touré, King's X, and Yes. Following the pattern above, if I don't have an embedded list for an artist, I just encode that value with double curly brackets. Otherwise I just use single brackets around the embedded list.

The URL scheme for Spotify is spotify:SPOTIFY_URL. You can get the Spotify URL from the app (in the share settings) or via a google search. I've even written a search tool using their API here.

How to Manage These Actions

One of the major downsides of LCP is that it's difficult to edit very long actions in the app's editor. However, there is a way around this. Import this action or just create a new action called Import and enter this string:

launch://import?url=[dropbox-text:ACTION.txt]

Then keep your music actions in their own text files in Dropbox. For example, I currently have my unabridged Spotify action as a text file called spotify.txt in the root of my Dropbox folder. I then just use the following action to import it:

 launch://import?url=[dropbox-text:spotify.txt]

LCP will import that text file, and ask you if you want to add it, just like if you were to use one of the importable actions at launchcenterpro.com. This way, you can make your edits in any Dropbox text editor instead of within the app itself.

06/16/14; 11:57:07 AM

Tweet This Post

Tweetbot has a list of URL schemes, the most recent of which is one to jump immediately to a Twitter list. I have never used it until now because I never knew how to find a list's ID. But now that I've figured it out, I'd like to share it with you.

The full scheme is

tweetbot://<screenname>/list/<list_id>?callback_url=<url> 

but you don't need to include the ? parameter unless you want to go somewhere other than your most recent timeline view in the app.

Let's say I want to view my ios Twitter list. To get the list ID, I view the source of the web page and search for data-list-id. In this example, the source code includes data-list-id="79393622". I take that value and put it in the URL scheme:

tweetbot://kishner/list/79393622

If I include this as an action in Launch Center Pro, then clicking on it will bring me right to that list.

If I have a preferred app I want to go to after I click the Cancel button, I can include the callback_url parameter, which is an encoded URL. If I want to go to Launch Center Pro:

tweetbot://kishner/list/79393622?callback_url=launch://

If I want to go to an actual website like google.com instead:

tweetbot://kishner/list/79393622?callback_url=http%3A%2F%2Fgoogle.com

Enjoy!

06/16/14; 09:21:52 AM

Tweet This Post

I am very much a newbie at bash scripting in Terminal, but I felt tempted to replicate the tool I built at TaskPusher for the command line: namely to send text and an optional action to Drafts from a Mac OS computer.

TaskPusher is a PHP web application that sends an url-encoded string to Pushover, a notifications app for iOS. Pushover already provided the code to send notifications from the Unix command line so I only had to make a few modifications to send a message to Drafts.

Before we begin, I need to qualify that I literally have only started bash scripting this week, so please bear with me if there are any inefficiencies or errors. The script works, but if you have any suggestions please comment below in the Disqus widget or send me a tweet.

The first challenge is that all the text after the Drafts URL scheme drafts:///create?text= needs to be url-encoded. I found a basic sed find/replace script here and I copied the code snippet into this gist:

 

 

Just add this in a text file somewhere in your directory and call it urlencode.sed. I haven't gotten to move new scripts into /usr/local/bin (or what-have-you) so in the pushover script below you will have to precede urlencode.sed with the directory path. In my working script I replace it with ~/j/scripts/urlencode.sed.

I named the following script pushover but you can call it whatever you want:

 

 

How to Run the Script

If you haven't already, purchase Pushover in the app store, create an account and get your user key. Then create an app in Pushover and save the API token. Where it says $APP_TOKEN and $USER_KEY enter yours in the script.

Now go to Terminal. You need to set one or two variables to send to Drafts: the message and the action. The message is the actual text of your draft. The action is the exact wording of any of the actions in the Action Directory. For example, I may want to send text to Due: 6pm pick up prescription. In Drafts, the action is called Send to Due. So on the command line, I type the following:

export message="6pm pick up prescription"

export action="Send to Due"

pushover

(In my case, I type ~/j/scripts/pushover. If Terminal says you don't have permission to run the script, type chmod 700 pushover.)

Your notification will be sent to Pushover, and you'll get a status response on the command line. When you get your notification, just swipe to open it, and tap on the URL string. In the example above, it would look like

drafts:///create?text=6pm%20pick%20up%20prescription&action=Send%20to%Due

When you tap on the URL, it will send the text to Drafts and tell Drafts to send that text to Due.

If you just want to send text to Drafts and not immediately act on it, just leave the action variable null. To clear the action variable from a previous notification, type unset action.

There are additional variables you can add to the script (as defined in Pushover's API) if you want to send your notification to a specific device or customize the sound. Just add an additional line in the script, like -F "sound=cashregister" \.

05/23/14; 08:47:30 AM

Last built: Fri, Jul 18, 2014 at 8:43 AM

By Jeffrey Kishner, Friday, July 18, 2014 at 8:43 AM.