Conquer Productivity: Developer, User and Business Process Workflows Explored

The single most valuable commodity for both individuals and organizations is time. When we can increase our productivity, we can bend the rules of time and achieve more within a given period. That’s such a tantalizing prospect that it beckons the investment of our time to learn these dark arts. Let’s shed some light on a variety of productivity tools that fall under the same category: workflows. We’ll look at how workflows can increase individual productivity, optimize and enforce business processes, and add value to any organization.

A screenshot of an Untitled.workflow file in Apple's Automator app on macOS High Sierra showing a simple example with two steps
Pictured: Apple Automator workflow for power users

Workflows are sequences of automated actions. If you want to do the same thing more than once, automation can save you time in the long run. If your business must require that a sequence of steps must be performed for every given action, you may want to consider creating a workflow. That’s a pretty generic term on its own, so let’s unpack it a little in several contexts.

Developer Workflows

Code

Arguing about definitions and classifications is one of the birthrights of the modern developer. It ranks right up there with expressing thoughts in pseudo-code and then drawing language-specific conclusions from the resulting example. What “is” a workflow, really?

When a developer writes a function, there’s usually an input and an output:

public Image resize( Image myImg ){
  Image resizedImg = myImg.resize(640, 480);
  return resizedImg;
}

That pseudo-code example is kind of Java-flavored, but the main point is this: any image passed to that function will be returned with the hard-coded dimensions within the function (640 wide by 480 tall). The input type is an Image, and the output type is also an Image. What happens inside the function body is a blind action performed on any image that comes through.

This is great if we frequently process images to resize them to those exact dimensions over and over again, but this is only useful within the scope of the program where that function is available. We could pick an actual language, choose a library to handle image processing, and start building up a series of steps to process images with conditions, parameters to tweak sizes and settings, and we could call that a workflow I suppose, but that’s about as hands-on as it gets.

Programmers love saving time. Many languages offer a sort of meta-layer of functionality called “macros” that allow developers to perform repeat functionality with minimal typing. I don’t consider those to be workflows, because they’re not necessarily marching something through a process. They’re more like shortcuts.

What if we want to offer this processing function to non-technical users, create a series of steps, and extend the scope outside of the code we’ve written? Workflows to the rescue!

If I have a folder of images on my laptop, and I want to process all of them in the same or similar ways, I don’t necessarily want to open up a text editor and write a complete program to handle this processing. I mean, I have that urge, but most users would not.

Toolchains

Many programming languages require a series of tools interoperating with one another to provide the developer experience they were designed for. For example, GNU Binutils like as (Assembler) and ld (Linker), compilers (like gcc), and C libraries are usually shipped together so you’ve got all the tools in the chain required for development. You can often include debuggers, cross-compilers, and optimizers in that umbrella term. I wouldn’t really call this “a workflow”, even though there’s a sequence of actions wired up to one another. I usually think of the term “workflow” as a much higher level process. What do you think, does the term qualify here?

CI/CD

Continuous Integration and Continuous Delivery processes are, to my mind, the clearest example of workflows in a developer’s world. I wouldn’t call our code’s functions and modules a “workflow”, but when you see code you wrote passed down from a commit to a pull request to a review process to a merge, then tested, queued for staging, deployed, smoke tested by QA, and the associated docs generated and published, you really get the sense that your work is on a long conveyor belt going through clearly defined business requirements to reach its end destination.

An animated Gif loop of Charlie Chaplin turning wrenches repeatedly to pointlessly adjust metal items moving down a conveyor belt
This guy gets it! (Image courtesy of Giphy)

Users

Consumer Automation: Workflows in the Wild

Fortunately, several tools exist to make this sequenced automation a fairly painless process without writing any code. Let’s take a look at Apple Automator, included with every macOS system. Here’s a whirlwind tour of creating a workflow in Apple Automator in macOS Mojave 10.14:

An animation demonstrating the creation of a workflow, involving simple selections within sequenced blocks dragged from a menu of available actions into a composition region
Pictured: Creating a Workflow in Apple Automator in macOS Mojave’s new Dark Mode

If you’re on Windows, you can find similar programs from 3rd party developers. Linux has various packages available as well. Some of the most interesting workflow apps are available on mobile devices, such as Tasker ($2.99 purchase) for Android or Workflow on iOS (now available in iOS 12 as “Shortcuts”).

Workflows are all about context. The more we standardize actions across devices and platforms (via REST interfaces, etc.), the more we’re able to wire things up so that an email received on your watch can tell your cell phone to turn on your toaster. That’s a very dangerous, impractical example, but you get the idea.

For most users, the biggest limitation for using workflows effectively is simply a lack of awareness that a series of steps they’re performing are a prime candidate for automation. This means that one of the best tools at your disposal when thinking about automating steps in a workflow may be examples of other workflows that demonstrate practical use cases.

Let’s take a look at some example workflows in various environments:

Workflows on a Mac

If you have access to a Mac desktop or laptop computer with Mac OS X Tiger (10.4) or newer, open Automator and play around a bit. By default, it is found in the Applications folder:

A Finder window in macOS, with Automator.app highlighted in the list of applications found in the Applications folder

Users of Mac OS X older than Tiger used to be able to automate things, too, just not with that specific program. AppleScript has been around a long, long, long time prior to that, and is still the right way to go for more complex automation if you’re willing to familiarize yourself with its syntax. In fact, you can use AppleScripts within Automator as steps in perfect harmony. When Automator first starts, you’re presented with options for the kind of thing you’d like to create:

The first view presented when creating a new document within the Apple Automator app

I’ll choose “Workflow” and create an example:

A view of sequenced actions in Apple Automator's example workflow document showing PDF processing

Pretty nifty, huh? Also, maybe too tiny to read. Here’s what is happening:

  1. A folder of files is copied, so the rest of these actions are not permanently altering the source images.
  2. Every single image is being resized, to whatever dimensions I specify here in the second step.
  3. I’m creating a new PDF from all of the resulting copied and resized images.
  4. I’m watermarking that PDF so people know I MAKED THIS.
  5. I’m setting some metadata in the PDF, also putting my stamp on the file so people know who the original author was, etc.

Now, I could certainly do all of these steps by hand every time. There may be cases where I still would, for example when I know the size of the images will not all be the same or when I want to add a step that the workflow does not account for (like also cropping the images instead of just resizing them). What’s important here is that I have created the option to march any group of files through these steps if and when that’s the desired result. I’m paying attention not only to the steps being performed, but also to the conditions under which these steps are the ones I want to be performed. To the extent that I can also automate this evaluation step, I can create completely independent systems that “just work” without the need for me to be involved.

These aren’t just clever tricks for geeks, either – workflows are first class citizens in iCloud with their own iCloud Drive folder and a nifty folder icon:

A view of a Finder window in macOS showing that the iCloud Drive has a dedicated folder for Automator files

This means your workflows sync across devices, assuming they’re all logged in to iCloud:

An iPad Pro screenshot in iOS in the iCloud Drive folder in Apple Files, showing the same example file created on the Mac

It doesn’t mean you can run them in all of the environments where they may be viewed and managed, though, and that’s a key take-away here: workflows have a fixed scope. To the extent that you have the same scope, I could even share my workflow with you–even our whole team–to piggyback on the work I’ve done in automating common tasks for all of us.

Workflows on an iPad Pro

I installed and opened the Workflow app on my iPad, and it has a nice introduction that explains itself during the onboarding screens:

The freshly installed Workflows App on iOS 11 introduces workflow inspirations in an image cloud with ideas

This is a great introduction to workflows, as the titles of each action help to inspire the user to automate things we might not otherwise have thought of. This helps to overcome the “so, what should I do?” question that inevitably follows the “wow, I can do just about anything!” feeling.

A second screen in iOS 11's Workflows app demonstrating an example workflow for inspiration

I love the onboarding tour approach; it gives me a very clear sense of what I’m here to do.

The final step in setting up Workflows on iOS 11 presents you with a screen of eight example workflows you can choose from to get started

Example workflows further encourage the creative juices to flow. Opening these examples to see what the creators of the app had in mind for its use will help to understand it at a practical level.

While I was writing this blog post, both iOS 12 and macOS Mojave were released, so I can actually show you the brand new iOS app descended from Workflows:

An animated gif showing the creation of a workflow in iOS 12 using the new Shortcuts app

Shortcuts! Here I create a workflow that takes the contents of the iPad’s clipboard, detects the language, and then detects the language again as it translates it to English. Oops! ]

I’m going to pretend I included an illogical step in my example workflow on purpose, as it conveniently illustrates a good point: once you have a clear picture in your mind of what you wish to accomplish with your workflow, it is up to you to make sure the steps you wire up actually make sense. Each step is a unit that mirrors the logic and requirements of the code behind the scenes that makes it work, but like writing code–you must organize these units into a practical flow of actions that accomplishes your end goal and avoids running into issues along the way.

Workflows on an Android Cell Phone or Tablet

A Brief Tour of Tasker

We’ve looked at macOS Mojave desktop/laptop workflows, as well as iOS 12 Shortcuts automation, but what about Workflows on Android? In true non-Apple fashion, Android is an environment where you can really fine-tune and customize your experience. One of the more powerful (and popular) apps for creating and running workflows on Android is Tasker, a $3 purchase on the Google Play Store. While this app may run on other devices, I’ve pointed out cell phones and tablets specifically because of some of the cool features of Tasker that are specific to these. For example, as demonstrated in this Gizmodo article from 2016, what if you want to play music during certain hours when headphones are plugged in IF you’re on your mobile data plan rather than wifi? These very specific environment-aware conditions can all be dialed in to pinpoint the exact circumstances under which your workflow will run.

By contrast, Apple’s automation functionality feels very “thing-oriented”, as in “I have a file and I want to a, b, c with it”. Tasker makes you realize how powerful conditions can be. Want your phone to switch to speakerphone if it detects that your service area changes to Rhode Island?

No, I’m serious:

An Android screenshot of an Action Edit view in Tasker showing a variable condition for changing CELLSRV to an approximate value of RI

Workflows Inside of Desktop Applications

Many desktop applications come with systems designed to make life easier by automating repeat steps. Sometimes these are referred to as Macros, which you might know as a no-no from Microsoft’s former Swiss Cheese security model phase. I had the privilege of accepting a donation of dozen brand-new computers and a T1 connection from the generous Bill and Melinda Gates Foundation back in 1998 as the Director of a small town library in Central Georgia, and let’s just say that our patronage at that library was low enough that I had time on my hands. I networked all of the computers together, set their security policies, distributed Microsoft Access to all of the client machines, and built a library patronage and circulation management system using VBA (Visual Basic for Applications). I never once needed to use a Macro to build out the whole solution; that’s just a different problem space. Fun fact: that system ran without any bug fixes, updates, or improvements for 5 whole years after I left before the regional library system came through with a statewide management solution. This was the 90’s and Visual Basic 6, I believe, so don’t judge. (Don’t tell Bill and Melinda, but a couple of those machines wound up running Mandriva and RedHat 6 Linux; you know, in case any patrons were computer science students interested in configuring their own mail servers…)

Macros are interesting, because most software allows you to record the sequence of steps that you want to save as a macro by just doing it while the software “watches” you click, type, etc. Let’s take a look at Microsoft Word from the Office 365 suite:

An animated Gif demonstrating the technique for recording a macro in Microsoft Word

Of note, when you record your actions as a macro, it’s generating the same VBA code you would have written by hand if you had a clear vision for the steps that your macro would entail. You could have come at the problem from a different angle, choosing instead to enter the commands manually:

Because of this, it is possible to record a macro and then open it up to edit afterwards as pictured in the GIF above. You could conceivably create a series of Macros and then wire them up to form a workflow or multiple workflows in the form of VBA scripts that conditionally call your Macros, but by that point you’re basically writing software.

Workflows Online

Macros and Actions and Scripts, Oh My!

There’s a spectrum of productivity terms that we can reach for when describing problem solving. If it’s multiple problems we’re solving, the same way every time, you might consider it to be a workflow. We might even consider some products to be a collection of workflows; for example, every time I take a screenshot, the image is uploaded to my personal CloudApp account. I just had to click through the installation process and that predefined workflow is configured for me.

A screenshot of the status bar icon of CloudApp expanded with its menu beneath

When I log in to Pivotal Tracker and create a story, it automatically starts out its life as an “Unstarted” story. From there, its predefined workflow marches through “Started”, “Finished”, “Delivered”, “Rejected”, and “Accepted”:

A screenshot of the STATE field in PivotalTracker, showing its various options

This helps me to enforce a workflow in my tasks even when it is just me clicking “accept”. In a team environment this kind of prescribed workflow is essential to scalable, manageable, organized work.

We’ve looked at very specific workflows in iOS and macOS, some very powerful conditions in Android, some things that are debatably not workflows (code, macros), and looked at a couple products that either are the workflow (automatically uploading images), or offer a business-process-focused optional workflow that relies on the user to function as intended (Tracker stories). Now let’s narrow our scope to consider online-only services in the cloud, and how we can wire different activities together.

Here are a few interesting tools online that help us “wire things up” to create our own custom workflows.

IFTTT

The explanation information from IFTTT showing examples of applets

[Straight from the horse’s mouth: IFTTT is positioning itself as an ecosystem where you make connections.]

“If This Then That” is a an aptly named service that takes everything we’ve been discussing about workflows and boils it down to inputs and outputs triggered on the web via APIs. Remember that problem we discussed earlier? The hardest part of using the power of workflows effectively is dreaming up what you should do with them. IFTTT has a powerful antidote in the form of a community-style collection of predefined workflows that you can use as-is or look at for inspiration:

IFTTT Applets for Social Media

You can see the creator of each , and the title of the workflow is a nice, terse use case that helps you picture its value in your, well, workflow. (That raises another point worth exploring: the English word “workflow” as one might use in a sentence. Merriam-Webster defines it as “the sequence of steps involved in moving from the beginning to the end of a working process.”, which technically could encompass coffee, cough syrup, and asking your cat “when will I finish this blog post?!” as if he’s interested in any process other than the steps necessary to move canned food from the container to the very, very center of his bowl.)

You can mash up any two services available on the IFTTT platform on your mobile device with a simple UI:

A screenshot of the New Applet screen on Android's IFTTT app

Oh, turns out you can do that on the web, too. My eye didn’t catch the button immediately as it looks a lot like a Jumbotron branding element, but check it:

Creating a New Applet in IFTTT on the web

In order to create your own published applets and services or do more than one thing, you have to sign up to develop on the IFTTT platform. This opens up a world of opportunity, with powerful features such as social media and other 3rd party platform authentication for users, webhooks, and even conditional geofencing (presumably easier to rely on when users are on the mobile version of the service), so if you’re craving an automated system that posts the current weather forecast to your company’s #random channel in Slack when you enter the Miami Metropolitan Area, you’re in luck! Most consumer users will simply enjoy the power of the applets (seriously, calling it that is giving me North/South AWT flashbacks from Java 2 in 1999) bringing a level of control to their lives that would otherwise require becoming an Alexa Skill Developer to achieve:

An Example Philips Hue app in IFTTT

As with Microsoft Flow, building a full workflow as a consumer in IFTTT will require some imagination as everything is tied to a two-step format. If something, then something else. There’s a lot of power there, but if you want to do 12 steps in a given workflow you’re going to to be configuring 12 different things, with the only connection between them being your experience that all 12 things are happening in your life.

The most powerful workflows offer you the ability to chain workflow steps into a sequence, where the output of one step becomes the input to a subsequent step.

You Were The Chosen One!

The most powerful, most fun, most interesting, most beautiful tool for chaining disparate sources of data is, sadly, no longer with us.

A view of the amazing power and complexity of the now-defunct Yahoo Pipes UI
Rest In Peace, Yahoo Pipes! You are gone, but not forgotten.

So what are developers using now in 2018? That depends on whether you’re connecting workflow steps within a closed environment or across different services. If you’re inside of a system that offers a workflow solution, great! Inside of that context, developers can lovingly craft UX and DX solutions to save you time and effort in automating your business requirements and heck, maybe just making your day a little easier. Done well, it might not even feel like a workflow. Do you ever just take for granted that your cell phone is alerting you from inside Slack that there’s a Pull Request awaiting your review, and then go on about your business as you give it a thumbs up which triggers an approve-and-merge action on GitLab, runs CI/CD, and posts an update to your #notifications channel while marking the related story in JIRA as complete? Yeah, me too. (Ok, slightly fictional, but entirely doable configuration described there.)

If you’re looking to roll your own unique solution that combines vastly different services, the gold standard is to build a bridge between two APIs, either by writing code on a box that sits in the middle (like those Heroku dynos that just connect your email to the Slack organization inviting you to invite yourself, or an AWS Lambda or DigitalOcean droplet just shuffling wee bits of data), or by tapping into a service designed to make this wiring simple and fun.

Zapier: Dominoes for Geeks

If you want to create a chain of steps in your workflow to tie the outputs of one API into the inputs of another, Zapier may be for you.

Zapier

Workflows Rock!

Workflows increase productivity, save time, and help individuals and organizations alike to focus on creating value and delighting customers. Workflows operate within a given scope, and common standards such as REST APIs allow us to build bridges between our various scopes. If you’re doing a process more than once, ask yourself: “Should this be a workflow?”

Read More →