I'm Sick of This Crap!

Way back in 1993 or so, I coded my first lame web page. Since then, I’ve learned some degree of HTML, Javascript, CSS, PHP, and more. I built my own personal websites on overly complicated, powerful, extensible Content Management Systems, and did the same for friends and clients.

I’m done.

Why? Because it’s not something I can do competently anymore. It’s no longer any fun to dabble in this stuff. Even the slightest tweak to CSS needs to be tested in fourteen versions of Internet Explorer, twelve different Android screen sizes, and did I mention it has to be responsive as well? HTML has as much in common with web design these days as a quill pen does with ebooks. I’m done with standards compliance, bug fixing, work-arounds for different browsers, and all the rest.

Screw it.

Today, I have moved my personal blog over here, to Tumblr. Sure, the search features are hideously broken, but it’s quick and fun to post and it has a great iPhone app.

Maybe I’ll write more, now!

Yeah… write…

…um…

Hey! I replaced Tumblr’s broken-ass search field with a hideous-looking Google search engine! Did you
Notice?

…aww, who am I kidding? 90% of the reason I ever blogged was to experiment with with web technologies.

So, not quitting then. Let’s call it… err… retired!

I’m scaling back, for sure, but I’m sure I’ll drop by the old office now and then to chat with HTML5 and the other new guys, maybe drop in on the FRAMESET tag and reminisce about old times. Just so I have something to do. I can’t just sit at home all day, can I?

Same crappy blog. New crappy place. Let crappy work for me.

And it’s still orange.

Written on August 30, 2012

Open 1Password Logins from LaunchBar or QuickSilver

This is a Ruby script that will export your 1Password bookmarks as an HTML file with each login as a link that will auto-fill your passwords. This file can be indexed in LaunchBar as a Bookmarks file (or in any other launcher that can index a file of URLs) for easy login to your indexed websites. Run this script on a scheduled basis using your favorite automation software, tell LaunchBar to index it as a bookmarks file, and you’re on your way.

Usage is fairly simple. Just run the script along with the path to your keychain file and the path to your bookmarks file. For example:

ruby agiletohtml.rb “/Users/me/Dropbox/1Password.agilekeychain” “/Users/me/Documents/1PasswordBookmarks.html”

Written on May 4, 2012

Bookmark the Shit out of It

I have begun to wildly and indiscriminately bookmark my online life and jam it into Evernote. The results have been fantastic: I now have the Internet (insofar as it’s relevant to me) synced up across my computer and my phone. Wifi out? No problem, my favorite nineteen Wikipedia articles are right where they’re supposed to be! Forget a website I visited? No need for browsing history, if it’s even remotely interesting, it’s probably in Evernote already. PDF reports from vendors and agencies? Yup, they’re in there, too.

My biggest tool in this regard is IfTTT, which I’ve written about before. It carefully pushes my Twitter, Facebook, blog Google Reader faves, and Instapaper archives into Evernote (and these are probably the best indicators of stuff I find interesting).

Is this good for you (or for me)? Maybe, or maybe not. It’s made searching Evernote a challenge (I’m working on sorting that out), but it’s still entirely functional. I wish (a little), that I could use something like EagleFiler to handle this, so that it’s just a little less proprietary, but with Evernote’s extensive API, it seems like I’m at least fourteen hops, six skips and eleven jumps away from disintermediating Evernote, should I want to at a later time.

Written on April 6, 2012

Hacked (again)

Once again, this site got hacked. A lovely lesson in why you need to keep all your CMS stuff up to date and otherwise keep things secure. Now that I’m spending less time sysadmining, I haven’t been as diligent as I probably should have. So, while this all gets sorted out, things will look a little strange and I’ll probably be missing some features. I have a number of sites to get back up and running, so this may take a little while.

Maybe it’s time to give up on my own CMS and move all of this to a hosted blogging platform.

Written on March 14, 2012

Cookiegate

Jonathan Mayer, a diligent researcher, discovered that Google is bypassing Safari’s third-party cookie settings. This has put Google in a bit of hot water, since this seems like a clear-cut case of ignoring how users want their content to be managed.

But the problem actually lies with Safari, which has known flaws in its security model for how it manages cookies. Once a site sets cookies, Safari will grant access to those cookies, regardless of changes to your cookie security settings.

This is very easy to demonstrate. Make sure that cookies are enabled in Safari, and log in to Facebook. Once logged in, go to your privacy settings and block ALL cookies. Close the window, open a new one, and navigate back to Facebook. You’ll see that you’re still logged in.

Now try this same trick with Firefox. You’ll find that as soon as you disable cookies, Facebook logs you out, because Firefox denies Facebook access to the cookie immediately.

As for Google’s (and others’) work-arounds to Safari’s active cookie policy, these exploits have been well documented for over a year, and totally ignored by Apple.

If you’d like to experiment, I’ve set up a test page: cookietest.html

This page uses the embedded buttons for common social networks, every one of which relies to some degree on being able to post and access cookies on your computer. Try visiting the page with Safari and your other browsers and see how they manage cookies depending on your settings. Every single social plugin will load and operate properly if Safari has logged in to the individual sites before visiting the page, even if you subsequently deny third party cookies. Chrome and Firefox work properly, and deny access to these cookies as soon as you set your preference to block them, whether or not they’ve already been set.

There is another odd behavior which is that Safari will let sites set cookies on the initial visit, even with cookies blocked. These cookies seem to be inaccessible to the site that set them, but the cookies are still stored. Very odd behavior.

Apple has a pretty poor track record in keeping up with security problems, especially in Safari. As much as Google may be at fault here for using this exploit, Apple’s cookie implementation is sub-par, and shows that Apple cares a lot less about their users’ privacy than they claim.

Written on February 24, 2012

Mountain Lion: Initial Thoughts

Apple’s released the first look at MacOS X 10.somethingorother, “Mountain Lion.” Like Lion, it’s a further adoption of iOS technologies at the desktop. Unlike Lion, these adoptions are more than skin deep. Mountain Lion becomes a peer device with your iPad and iPhone. Whether that’s a promotion or demotion of the status of the Mac in your digital life is certainly debatable.

First off, there’s all the new apps. Bringing iMessage into a new iChat replacement, a better to-do manager than iCal’s half-assed handling of the same, and Notes taking on the best of the old Notepad desk accessory and Stickies looks great. Even if I’ll never use most of these things, since I already have half my life in OmniFocus and Evernote, they’re still fine additions.

But then there’s iCloud and Gatekeeper.

Gatekeeper is the most immediately controversial. It simply controls what applications are allowed to be installed, sort of a user security policy. If you want to be able to install applications that are made by developers who have not registered with Apple, you’ll need to change a setting. While this is billed as the “middle ground” between App-Store-Only and the current wide-open standard, I think that misses the point that in order to be able to easily distribute apps, you must register with Apple first.

Next, we have iCloud. Keeping all my files sync’d up across all my Macs without any hard work sounds great. I love DropBox and ChronoSync, and making that system level sounds zippy. Well, except that lots of apps won’t support it at all, especially all of the ones that won’t be distributed through the MAS, which will thereby be ineligible for iCloud.

Not so trouble free, is it?

And in either case, I’ll need to register with Apple, because iCloud’s become a necessity, not the really-just-a-payment-method AppleID of old.

Basically, Apple’s pulling a Google here. They’re taking more and more data on its developers and users, and taking more and more of its consumers’ digital stuff onto its own servers.

This is, I’ll admit, a little alarmist. They’ve always asked for product registration, and an AppleID is pretty much a must-have and with XCode’s distribution on the MAS, a requirement to be a developer. But it still shows a level of personal-level control and management that Apple’s never taken on before.

Written on February 16, 2012

Using Evernote as a Bookmark Manager

Some time ago, I got sick of my huge bookmark library and dealing with synchronizing it across every browser I have, especially given that one of my few disloyalties to the Apple ecosystem is that I use Chrome instead of Safari, which doesn’t sync in any way with my iPhone. To fix this problem, I signed up for the remarkably good Pinboard service, and used its tools to import my Safari bookmarks. Pinboard was entirely satisfactory, and I recommend it to anyone who wants an easy-to-access online repository of bookmarks. Having all my bookmarks online and available from any computer (i.e. my wife’s PC or other computers when I was a guest at someone’s house) turned out to be quite useful, which was surprising to me.

Where Pinboard didn’t work as well for me is that I clip a great deal of web content to Evernote to keep as notes or research. This meant that I had at least two places to look for what were, essentially, the same thing. (With one just being a little richer in content than the other). Despite Spotlight and the great (and free) delimport utility which let me search both sets of data at once, this wasn’t possible on my iPhone, and seemed simply overly difficult.

So I decided to switch to Evernote as my one and only place to keep track of interesting web content. Evernote was my pick of the two (Pinboard offers a service that will archive and make searchable the content of all of your bookmarks) because it offered local access to all my content, and since it also has a great deal of other valuable information, it lets me easily aggregate combinations of useful information, not only bookmarks.

Since Pinboard and Evernote both excel at import and export of various data sources, it was relatively trivial to put all my Pinboard bookmarks into Evernote. I then went the extra mile and built an AppleScript that went through all of those imported bookmarks and pulled the original web content, which I first “cleaned” using Instapaper’s web viewer, ensuring that I only had the core content and wasn’t storing ads, comments, and navigation menus.

This has worked quite well for me, especially with the Evernote Chrome extension that shows clippings from individual sites as I navigate them and also shows me if I have any notes matching search terms when I search Google or Bing. This makes it stupid simple to find content that I’ve clipped or bookmarked but forgot I’d done so. The addition of the Clearly extension makes it easy to clip only the core content from web pages when I bookmark them (a habit I’ve gotten into, since it ensures the content will survive later deletion/updating or changes in its URL, and also makes it fully searchable). Having all of these pieces of information in one place is, as I expected, very useful, and makes bookmarking a much more useful tool than it ever was before, since I can search it, access it anywhere, and associate it with all sorts of other content through tags and folders.

There are two ways in which it is sub-optimal, however: Firstly, Evernote doesn’t directly launch URL bookmarks in a useful fashion, so I end up searching, opening a note, and then clicking its URL. This leaves me with an open application and selected note, and changing my currently selected note, in order to do what is typically a one-click action. Secondly, Evernote is getting very, very, full. Searching for almost any common search term brings up a dozen or more matching notes. It also falls short in giving me quick access to URLs for sites I visit regularly, so I’ve gone ahead and put those into my browser toolbar and manually updated them in Safari to make sure they get to my iPhone. Since I don’t plan on changing my email service, bank, or favorite social networks any time soon, this works just fine. Auto-completion in the browser has made these bookmarks fairly unnecessary anyhow.

I’ve found two useful work-arounds: I tag anything that I feel is really just a “bookmark” with an un-creatively-named tag of “bookmark.” This makes a search for bookmarks easier, although there’s certainly other clipped content with associated source URLs that are also useful as bookmarks. I have also created a few smart folders which narrow down to notes with URLs and one for notes with the bookmark tag. These don’t bypass the problem of opening bookmarks, but do make it substantially quicker to filter out irrelevant content. I’ve also become accustomed to deleting (or just not clipping) URLs from notes I clip from the web if I’m really just keeping them as reference and I don’t think I’ll ever need to re-visit the site. (e.g. code snippets)

So, do I recommend this approach? Absolutely. It changes bookmarking into research, reference, and a sort of bibliography for my projects and general life.

I’ve also, as you might guess if you’re a regular reader of this site (rather, if you’re THE regular reader of this site – Hi, Mom!), built a few AppleScripts to make my life easier by easily importing original HTML content into notes (with or without Instapaper’s involvement), and also one to export my Evernote bookmarks so that they can be indexed by LaunchBar, and opened without having to launch Evernote at all.

Click here to get the scripts.

Written on February 9, 2012

Evernote Bookmarking Tools

I use Evernote in lieu of in-browser bookmarks. (You can read more about this project and how it works for me here.) I have two scripts I use to make this a little easier on me:

Append source HTML to selected notes: This takes selected notes with an associated URL and attaches the content of the URL’s page to the respective notes. If you change the “useIP” property to true, it will also trim down the source with the Instapaper service, thus eliminating ads, navigation, and comments before importing the HTML. I used this originally when I imported by Pinboard bookmarks into Evernote, but occasionally use it with other notes that I’ve just added my own comments to, so as to make them “full text searchable.”

Export Notes as HTML Bookmarks: This script takes every URL stored in Evernote and exports it into a simple HTML file that contains nothing more than a series of links, labeled with the title of the associated notes. I use [LaunchBar] to index this file (added it to LB’s index as a custom web bookmarks file), making it easy for me to quickly open bookmarks without even having to open Evernote. Use your favorite scheduling utility to make this happen on a regular basis. (I use Keyboard Maestro

Written on February 9, 2012

Generate Rich Text in AppleScripts and Shell Scripts

Normally, AppleScript absolutely mangles rich text once it comes in to the system. I have recently discovered a workaround for this, which is the “pbcopy” terminal command. Anything piped to this command will be copied to the clipboard. Normally, this is done only as plain text, but if the incoming data is rich text (has an RTF header), it will come in as rich text. The second part of this is the use of the “textutil” command, which can take text of various formats and output them in, among other formats, rich text. Now, even if you’re limited to only plain text (as in AppleScript), textutil will happily accept HTML, so if you can generate formatted HTML, you can pipe it through textutil and end up with lovely rich text in your clipboard, and it even retains links!

So from the shell, your command is something like:

% echo [html text] | textutil -stdin -stdout -format html -convert rtf | pbcopy

Just make sure that your HTML text is properly escaped.

If you want to do this from AppleScript, you can simply encapsulate the whole thing in a “do shell script” command.

BONUS: You can also put Markdown or MultiMarkdown in the mix to take Markdown-formatted content and convert it to rich text on the clipboard. The following is an example of how this would work with MultiMarkdown:

% echo [markdown text] | mmd | textutil -stdin -stdout -format html -convert rtf | pbcopy
Written on January 27, 2012