Welcome to the lab.

Web Excursions for March 23, 2015

[Tweet : ADN : nvALT]

It’s only been four days since I last posted one of these. They’re not supposed to happen that often, but they get sent to my draft folder as soon as I rack up enough bookmarks in Pinboard. So much new stuff, I can’t stop it. The automation must move forward.

A scripting language that compiles to Bash, but is much friendlier to code than Bash. It’s lacking a few finer details at this point, but it’s a brilliant idea that’s totally usable right now. It’s being consistenty developed, too, so I have a certain amount of hope that this will become a “thing.”
A smart history search with fuzzy matching for Bash and Zsh. There’s a hack for overriding Ctrl-R with it, too (`bind ‘“\C-r”: “\C-a hh \C-j”’).
Holy crap. A keyboard launcher built into Xcode.
Hey.Press - Find relevant journalists. For free.
I like this idea a lot. It’s a database of publicly available emails for bloggers at major outlets, searchable by keywords. It shows you 3 relevant articles for each blogger, and if you think they’re appropriate, you can add them to lists and export CSV files for a press campaign.

Hey.Press is free to use, you just have to create an account. They do an intelligent job of “letting” you pay a buck or two when you download. It’s optional—the service is promised to be free forever—but it’s a smart way to get support from users in palettable increments.

PRstack – crowd-sourced catalog of 200+ public relations tools
More PR tools (crowd-sourced catalog) ranging from free services perfect for guerilla marketing and indie developers to enterprise level CRMs and analytics tools.
Streamlining Our Proposal Writing Process
LaCroix Design Co. wrote up how they use Markdown and Marked 2 to quickly and easily create beautiful client proposals.

A Bash function for finding your Bash functions

[Tweet : ADN : nvALT]

As you may have noticed if you’ve followed this blog lately, I write a lot of Bash functions and aliases. I keep them in distinct files using a plugin system based on bash-it. It works really well, and makes upkeep simple. However, I very often lose track of exactly where I defined a function or alias after a few months go by.

Unix commands like type and which will tell you where executable scripts and binaries are, but they’ll fail finding a function. Thus, “where” was born. It’s a Bash function that indexes every function and alias in any files that are sourced during login. Then you can type where func_name and find out exactly where a function or alias was defined. If a function/alias appears multiple times in your sourced files, the last version sourced (and thus likely the one Bash will default to) will win.

where has options for degrees of fuzzy search, too. You can use -k (aliased to where?) to find any functions containing the search string. There’s -a (or where*) to do a completely fuzzy search of the index as well.

The search will fall back to using type if there are no results in its index, so it becomes a universal command for me, replacing which and type for the most part.

The basic command outputs a full path (with :lineno) if a match is found. In iTerm, you can just ⌘-click that to edit the file. You can also use a -E flag to immediately open a match in your $EDITOR.

The fully-automatic version hooks the builtin source command. (There are included routines for taking a more manual approach as well.) Because hooking the source command and parsing every file you load can be slow, the index that where creates can be cached with any expiration time you want. See the project page for more info.

Blink: instant iTunes affiliate links on iOS

[Tweet : ADN : nvALT]

My friend (and frequent Letterpress rival) John Voorhees has just released an app called Blink.

Blink is an app for people who share links to iTunes and Mac App Store apps and use Apple’s affiliate linking program. It lets you search across the App Store, the Mac App Store, the iTunes Store and the iBooks store, then generate an affiliate link with the result. You can choose a link format: plain url or one of three Markdown formats.

You can also pass appsto.re, itun.es, appstore.com and itunes.com links to Blink to have them converted before you share them. With an extension that lets you use Blink’s capabilities anywhere on iOS, it’s a great tool for writers and bloggers who want to take advantage of affiliate linking without jumping back and forth between apps. There’s even a URL scheme for integration with workflow apps such as Drafts, Editorial, or Workflow.

Check out the homepage for more info, or just go grab Blink on the iTunes App Store ($4.99 US).

Web Excursions for March 19, 2015

[Tweet : ADN : nvALT]

Google Feud
I’m lucky to get even one right in any category, but this combination of Family Feud and Google suggestions is hilarious. This made it onto @midnight the same day I added this bookmark, so it must be cool.
A curated collection of online programming tutorials for an array of languages.
I think I’ve mentioned choose before. It’s a utility for Yosemite that pops up a visual selector for input received from any script. I mention it again because now it’s open source and ready for hacking!
Create an App Demo Video in Minutes (With Gestures) for Free
This looks like a cool service from Placeit. When I finally get around to making an iOS app…
Blippy - GIF Folders
Just in case you didn’t have enough tools for annoying people with memes, Blippy lets you build a “gif keyboard” for iOS 8 to easily save and use animated gifs in your communications. Also check out blippybot.

MeisterTask: visual task management from MindMeister

[Tweet : ADN : nvALT]

MeisterTask was officially announced today. It’s a web-based project management app from the team behind my favorite web-based mind mapping app, MindMeister. MindMeister offers a more visual way to think and collaborate, and MeisterTask continues that vision by turning brainstorms into actions.

MeisterTask is similar in function to Trello, but offers a more complete project management environment with a beautiful user interface. I’ve been trying MeisterTask out in beta for a while now, and it’s a pleasure to use. There’s an iOS companion, too.

In addition to the Kanban-style overviews of each project, every project and task contains conversation and a full activity history. You can use @mentions in conversations on any task, and inviting and onboarding new members to any project is streamlined, even if they’ve never used MeisterTask before.

Tasks can have links, photos, and other attachments connected, including direct integration with MindMeister maps. With MindMeister’s collaboration and voting features, it’s easy to expand an in-depth conversation on a single task using mind maps, which takes the conversation into a realm that I consider far more productive. From within MindMeister, you can also easily turn nodes into tasks, and link tasks into MeisterTask projects.

MeisterTask also has time tracking, great keyboard navigation, and integration with email. It also syncs with services such as GitHub, Zendesk, Google Drive, Slack, and Dropbox. There’s an API being finalized right now for custom integrations and tools, too.

I’m excited about this. I’m already using it with family and friends for small-to-medium projects, and I think it will scale quite well. It’s free to use, with a Pro package coming soon. Head over and check it out.

Shell tricks: sort a Bash array by length

[Tweet : ADN : nvALT]

I’m certain there’s a more elegant way to do this, but I couldn’t find it. I needed to sort a Bash array of strings by the length of each element without getting too verbose. Here’s what I came out with:

declare -a arr=( s sho sh short l loooooong )
IFS=$'\n' GLOBIGNORE='*' sorted_arr=($(printf '%s\n' ${arr[@]} | awk '{ print length($0) " " $0; }' | sort -n | cut -d ' ' -f 2-))

Now the sorted_arr variable contains an array of elements from arr sorted by line length in ascending order:

$ echo ${sorted_arr[@]}
l s sh sho short loooooong

$ printf '%s\n' ${sorted_arr[@]}

If you want to reverse the order, just change the sort -n section of the oneliner to sort -r -n (reverse).

By the way, this is from a quick change I made to Reiki (v1.1.3 is up) that allows it to assume that the shortest match is the most likely when testing multiple fuzzy matches. Just in case you cared…

MultiMarkdown Quicklook plugin 1.1

[Tweet : ADN : nvALT]

MultiMarkdown 4.7 was recently released, and I decided it was time to catch my Quicklook plugin up with it. This version of the MultiMarkdown QuickLook plugin allows for custom styling when previewing Markdown files in Finder. Full details on GitHub.

The only changes aside from the binary update are to the CSS files, which had comments in them that MultiMarkdown was mistaking for headlines when generating the {{TOC}} results. That’s right, MultiMarkdown 4.7 has automatic table of contents generation.

There are lots of other new things in MultiMarkdown lately, so if you haven’t updated your own installations, you should. [%metadata] replacements are one of my favorite new features, allowing you to use the [%key] format to include text from any MMD headers defined in your document.

The new QuickLook plugin source is on GitHub, and there’s a compiled version ready to install on the release page for 1.1.