Drupal social publishing software

Drupal is a powerful content management system and framework that makes building powerful websites possible for mere mortals. Some of the posts here will be syndicated to Drupal planet.

Drush and cloning

I need to pull down a site I have on my other computer but haven't setup here for local development. I keep thinking there should be a 'drush clone' command... well there is but it clones modules not the way I'm thinking of. Basically the command I have in mind would:

  1. Clone the git repository of the site into the proper local directory.
  2. Copy the files from the production or developer site.
  3. Create the local database and sync from production or developer instance.
  4. Or instead of syncing the database do a site install if that's called for.

This requires of course that drush aliases already exist for the site. How to handle this and keep everybody in sync. Well, here's my stab at a highly configurable, very customizable drush configuration for people who work with one or more teams.

More Alfred and drush love

A couple years ago I started playing with using the stellar Alfred.app with drush to get things done. This post describes how I used a now defunct URL shortener to create short links from Alfred.

Fast forward a couple of years and Adjix is no longer but the basic script still works. However it had run into a couple of issues like being hard-coded to drush paths which can vary from machine to machine. This was because the non-interactive shell wasn't picking up all the wonderful things like my $PATH definitions in settings files. So a bit of work later and this script now looks like this:

source ~/.bashrc
echo `drush .env ev 'print (shorten_url("{query}"));'`

That's it. Well there are two outputs of the workflow. The first copies the results of the statement to the clipboard. The other posts it to Notification Center so you know the work is done and get to see the URL for your shortened link.

Drush make and Pressflow

A quick note on using Pressflow as the basis of a Drush build using Drush make can be a little confusing as the changes necessary to use the newer github-based repository aren't abundant. So without further ado here's what works:

projects[pressflow][type] = "core"
projects[pressflow][download][type] = "git"
projects[pressflow][download][url] = "https://github.com/pressflow/6.git"
projects[pressflow][download][tag] = "DRUPAL-6-24"

Note that the previous instructions around the web tend to be problematic because the tarball file contains a git repo which Drush make doesn't know to strop since it's getting it as a tarball instead of from git.

Create custom Adjix short URLs with Alfred

Alfred.app Logo Although I use it all the time it turns I haven't written here about Adjix. There is in some issues but nothing that spells out just how awesome it is. The short version is Adjix is hands down the single best URL shortener out there. While it deserves it's own post suffice it to say you can use its power and still . Future proofing at its best.

But this post isn't about that. It's about using your own custom domain and setting up a URL shortener that works from . Alfred is itself another awesome tool that deserves yet another post. Inspired by a on Dirt Don I set out to create a url shortening shortcut. (Recursion is encouraged).

So based on this post I setup a quick shell script shortcut in Alfred. The properties end up looking something like this:

Drush away unserialize() errors

When you work with the great folks I do every day it comes as little surprise that when the stuff hits the fan and some site is in need of help there will be a legion of folks who jump into round-the-clock action to get things in a better place. While this could be a whole blog post about that alone it's not about that. Rather it's about one of those nagging little problems we came across while working on a site this Thanksgiving "holiday".

The problem is one that many have seen at one point or another:

[26-Nov-2011 22:35:17] PHP Notice:  unserialize() [<a href='function.unserialize'>function.unserialize</a>]: Error at offset 200 of 1100 bytes in /var/www/mysite/includes/bootstrap.inc on line 1104

In fact this problem pops up enough that it has its own page in the Drupal Handbook. The problem is pretty straightforward to understand. Some object was serialized for storage in the database and has become corrupted.

iPad's greatest flaw

ipad_connect_to_itunes.pngA today reminded me that I've been meaning to write about the big flaw in the iPad. Actually it is a flaw in iOS but I notice it most on the iPad.

First a little background. I've had an iPad for as long as they've been around and eagerly stood in line for the iPad 2's new cameras. More than the first iPad the iPad 2 is a transformative device. It is comfortable to hold in bed to read, it has an amazing cover that just works and it's a bright white color instead of the heavy black. (How the color affects the perception of weight is another topic for another day.)

As awesome as the device is for me. It comes with a horrible flaw. This first came to light the very night I picked it up. After the headache of convincing my credit card issuer that yes it really was me staying in a hotel and buying an iPad at an Apple store I met a friend and we headed out for dinner. Being a Drupalcon dinner there were plenty of tech folks. Since the line for Chicago pizza was longer than the line for the iPad 2 we had plenty of time to talk. Eventually I succumbed to peer pressure and opened the box.

While peeling away the shrink wrap on the box (even the box is slightly smaller than the previous iPad) thoughts of taking a few pictures of the group with the new iPad came to mind. With a creative group of smart people what could we do with this new technology while waiting for a dinner with a week's caloric intake? And then all at once it happened.

Kicking off Drupalcon with APIs

Drupalcon is off to a great start. Yesterday afternoon and this morning we met all kinds of great Drupal folks while passing out the free Acquia t-shirts and sharing the news about several recent releases. If you haven't had the chance to check out the new Acquia Drupal Stack Installers. The installers bring a Windows and Mac OS X installer to the desktop that install and setup all of the components necessary (Apache, MySQL, PHP and Acquia Drupal) to get started running a Drupal site.

Getting to Drupalcon

On the trip to the airport I was reflecting on just where Drupal has taken me. On one hand having chosen nearer the beginning of the decade to use this open source PHP-based content management system was a short-term decision. I had websites and they needed to be done. The solution was easily Drupal. Sure there was the roll-your-own option. But I've been there and there is little way to get around the idea that proprietary website management is for the birds.

In a literal sense Drupal has powered travels across the country. The wonderful thing about Drupal travel is the community.

Wherever you go from coast to coast and continent to continent there are fascinating people to meet. In a career sense Drupal has certainly been the right choice. Not only has it been a tool that has enabled me to do things to impress those who write my paychecks but a year ago it became my full-time job.

Goodbye 2008, Hello 2009

Here we have the obligatory last post of 2008. The lists of things that changed this year could fill volumes. Waiting for the fireworks last year, in a house with no blinds on the windows, we were just getting started on the new adventure. Quite an adventure it has been too.

Starting a new Drupal consultancy at the beginning of the year. Getting more involved in the Drupal community and wrapping up the winter with a visit to Boston for my first Drupalcon. Even a few months in Drupalcon was a chance to renew friendships and make many new friends.

After a winter of travel and coming home to Idaho we came home and got down to work. Several projects cranked out and lots of Drupaling later it came time for a summer of travel. From Oregon to Maryland the trips were great. Once again it seemed everywhere I landed the topic of conversation was Drupal. One of the highlights was spending hours manning the Drupal booth at OSCON with Kieran, who would soon become a colleague at Acquia though that wasn't to come till a little later.

Drupal Camp PDX

Off to a great start at Drupal Camp PDX. Ben Kaplan and Andrew Morton are kicking off the day with what Drupal is and is not. Some great analogs are being used to illustrate what Drupal is and is not. Of course having a Drupal Camp in the beautiful Portland area makes it all the better.


Subscribe to Joshua Brauer: All Drupal items Subscribe to Joshua Brauer: Drupal Planet only