Getting Healthy with Workflow

Shortcuts no longer supports shortcut file imports and links no longer function. Any links to shortcuts in this post have been updated to use iCloud links.

With the end of 2015 almost upon us, it’s time to make well-meaning new year resolutions about our health. Sticking to them, however, is easier said than done, so I thought I’d share some workflows that I created for Workflow which manipulate Health data, many of which I use on a daily basis.

Don’t forget, all of these workflows can be used as-is, but the real benefit comes from tinkering and changing them to best fit your own requirements.

Log Calories by Scanning a Barcode

This is one of my favourite workflows and really takes advantage of some of the features that makes Workflow such a joy to use. Using information from the Nutritionix USDA common foods database, you can scan the barcode of almost any US grocery item to find its calories and log them to Health. You can alter the serving size accordingly, which will adjust the calories calculated before logging them to Health. If no information can be found, or you don’t have a barcode handy, the workflow will ask you if you’d like to manually enter calorie information instead.

You’ll need to register for a free Nutritionix developer account and update the workflow with your API keys, and barcode scans are limited to 20 requests a day.

Calorie information for most US grocery items, along with the recommended serving size, can be determined

Manually Log Calories

Another favourite of mine can be run directly on your Apple Watch. Nutritionix only has widespread support for US grocery items, so anyone living outside the US will almost always have to log calories manually. To make this easier, this workflow can be run from either the Today Widget or Apple Watch to input the estimated calories consumed for a particular snack or meal, which is then logged to Health.

Apple Watch

Daily Health Report

This workflow can be run directly from the Today Widget and will display your total step count, flights climbed, walking + running distance, calories logged for the day and most recent weight. A great way to get some at-a-glance information about how you’re doing today.

A daily health report in the Today Widget

Monthly Weight Report

This workflow compares your most recent weight to that of 30 days ago and displays the results in a message. Just a quick way to see how your weight compares since last month.

Monthly Weight Report in the Today Widget

Monthly Weight Chart

While the Health app will display some basic chart information, it’s not very customisable and intuitive. This workflow is based upon my Create a Chart workflow and will create a chart of your weight based upon how many months you specify, output as an image.

I save the resulting chart into Day One each month so I can look back at my progress over the months (and, eventually, years).

Weight chart example for a 12 month period


Creating Device-Framed Screenshots in Workflow

Update: This workflow has since been replaced with one that uses Workflow’s Overlay Image action. You should use the new workflow instead.

I spent some time over the holidays catching up on a selection of previous Club MacStories newsletters and came across a reader question in the Workflow Corner section of Issue 10:

Is there any way to build a workflow that would put the latest screenshot into an iPhone or iPad frame?

Federico Viticci response was that there isn’t a fully autonomous way of placing a screenshot inside an iOS device frame, suggesting instead to use an app like Pixelmator and Apple’s official product marketing images.

Federico isn’t wrong – there isn’t really any way to automate the placement of a screenshot inside an existing image of something like an iPhone or iPad using something like Workflow. However, if we come at this from a different angle, it actually is possible to achieve the desired result with Workflow.

Instead of looking to insert a screenshot inside device image, a screenshot can be “wrapped” by slicing a device image beforehand. Then, with some creative use of the “Combine Images” action and a few variables later, it’s possible to wrap a screenshot in a way that results in a perfect image of an iOS device containing a screenshot.

An example using this workflow

I’ve created this Screenshot Builder workflow and the necessary image assets that you can use to frame a screenshot with the iOS device of your choice. This is achieved by slicing the device image into four distinct segments (top, bottom, left and right sides), as the following screenshot (with some added padding) will show:

See how the device has been split into four distinct pieces

I spent some time slicing the images available from Apple so that the workflow can provide support for:

  • iPhone 6s
  • iPhone 6s Plus
  • iPad Pro
  • iPad Air
  • iPad mini
  • iPod touch
  • Apple Watch

Each iOS device has an option (and assets) to use either Silver or Space Gray colours (with the exception of the iPod touch, which offers Blue and Silver options) and will automatically detect if a screenshot should be in portrait or landscape.

Using this Workflow

This workflow requires the pre-made image assets I’ve created be saved to Dropbox so it can use them when creating these device screenshots. To do this, use this Dropbox link and add the folder (screenshot-builder) to your Dropbox account (click Download, then Save to my Dropbox). You’ll need to update the Dropbox action in the workflow if you move this from the root of your Dropbox folder.

Once the above has been done, simply run the workflow and select the device, its colour and the screenshot that you’d like to create.

Apple Watch with CARROT WeatherApple Watch with CARROT Weather

iPhone 6s Plus with OvercastiPhone 6s Plus with Overcast

iPhone 6s Plus with Alto's AdventureiPhone 6s Plus with Alto’s Adventure


Initial Thoughts on the Apple iPad Pro Keyboard

David Sparks writing about his first few weeks with the iPad Pro keyboard:

When the iPad Pro was first announced I knew there would be a lot of third party keyboard cases and I figured the winner for me would end up being something from Logitech. However, the Apple keyboard has the right amount of balance between minimal profile and working keyboard that I think it is the keeper for me.

The iPad Pro keyboard is often being compared to the new MacBook keyboard, which has had some polarising opinions1, so it’s interesting to start seeing some of these check-ins from people who have been using them for a little while.

  1. I’ve only tested the MacBook by visiting an Apple Store and leaving random notes for Marco, though I’m with TJ – I think the new keyboard is great. 


London Bus Stops Using E-Ink Displays

BBC News:

Transport for London is trialling e-paper bus stops that can display real-time travel information.

Fitted with solar-powered panels, they show how long passengers have to wait for the next buses, as well as route maps and timetables.

TfL has always been a forward-thinking about using technology for public transport, especially if it improves on something already in use. Live timetables have been in place at many bus stops already, though limited to higher-traffic stops with shelters. This new technology is both environmentally friendly and capable of being installed at any bus stop. I bet it’s even cheaper, long-term, as well.


Sidetrack for iOS Updated

My favourite RSS reader for iOS, Sidetrack, has just received a major update :

  • Added Feedbin support
  • 3D Touch
  • Split-screen
  • Safari View Controller
  • iPad and iPad Pro modes
  • Configurable tap and press & hold actions in list view (url scheme and multi-tasking support allows for very flexible configuration)
  • Status bar can be toggled on and off in settings
  • New font options
  • New app icon

Sidetrack is one of the few (if any) iOS apps that fully supports Feed Wrangler, including the creation of Smart Streams. These new features are a welcome addition and the customisable URL scheme for sharing is fantastic, and was one of the features that makes Mr. Reader, another iPad RSS reader, so great.




OpenAI is a non-profit artificial intelligence research company. Our goal is to advance digital intelligence in the way that is most likely to benefit humanity as a whole, unconstrained by a need to generate financial return.

Since our research is free from financial obligations, we can better focus on a positive human impact. We believe AI should be an extension of individual human wills and, in the spirit of liberty, as broadly and evenly distributed as is possible safely.

The outcome of this venture is uncertain and the work is difficult, but we believe the goal and the structure are right. We hope this is what matters most to the best in the field.

I think we’re going to see some significant advances in AI in the next few years and OpenAI will be leading the charge, especially as they’re starting off very well funded:

Sam, Greg, Elon, Reid Hoffman, Jessica Livingston, Peter Thiel, Amazon Web Services (AWS), Infosys, and YC Research are donating to support OpenAI. In total, these funders have committed $1 billion, although we expect to only spend a tiny fraction of this in the next few years.

$1 billion. And they don’t even plan to use most of it for a long while. This isn’t just a start-up, this is an initiative that’s likely setting goals decades in the future.


Here’s What Makes Apple’s Battery Case So ‘Smart’

Rene Ritchie has a great breakdown of the benefits of Apple’s new Smart case over at iMore:

Because of the enormous of amount of attention paid to the visual design of Apple’s new Smart Battery Case for iPhone 6s, a lot about its functional design has been overlooked. Including by yours truly. Though the actual battery inside the case is smaller than many other, similar cases, the “smarts” Apple built into it the battery case means it’s also much more efficient.

While not the prettiest case ever made, it is a lot smarter than any other on the market. Question is, will Apple be willing to open up the same functionality to other case manufacturers to take advantage of?


Apple Remembers It’s Also a Software Company, Releases Updates

I don’t know what just happened in Cupertino, but a slew of updates have just been released. iOS 9.2, tvOS 9.1, watchOS 2.1, OS X 10.11.2 and Xcode 7.2 are all available to download and install through Software Update.

And what some may consider a Christmas miracle, tvOS 9.1 even gains support for the presumed-dead iOS Remote app.


Apple Introduces iPhone 6s Smart Battery Case


Apple today introduced the new iPhone Smart Battery Case for the iPhone 6s and iPhone 6. Available in White or Charcoal Gray, the Smart Battery Case includes a built-in battery which will boost your iPhone’s battery life for talk time up to 25 hours and internet use up to 18 hours on LTE.

You charge the Smart Battery Case and your iPhone simultaneously and the amount of charge left in the case is displayed on your iPhone’s normal battery indicator.

iPhone Smart Battery Case

Ignoring, for a moment, that this thing is downright hideous – it’s interesting that Apple has released this. The iPhone battery case market is pretty well covered and Apple Stores have been carrying the Mophie cases for years… so why now?

While Apple has mostly always produced its own cases and smart covers for iPhones and iPads, they have often been forerunner products to provide both an option for newly-released devices and a benchmark for what other case manufacturers should achieve in terms of style and quality1.

My theory is that Apple has been receiving a lot of negative feedback on the battery life of the iPhone 6/6s in stores, so much so that they felt it necessary to release their own battery case. It’s not unreasonable to assume that many Apple Store employees often have to recommend a third-party battery case to 6/6s customers reporting poor battery life, so Apple may likely be seeing an increasing need to have a first-party option that could be recommended first. Whether this is solely for profitiability, however, remains to be seen2.

Whatever the reason, releasing their own battery case for a device that is often derided for poor battery life seems almost an admission that maybe there is such a thing as too thin.

  1. The exception to this is the original iPad case. Worst. Case. Ever. 

  2. I really hope it isn’t, but it does seem that Apple may be wanting to cash in on the poor experience many users are suffering from. 


Saying Goodbye to Carousel and Mailbox

Dropbox announced today that they’re killing off Carousel and Mailbox:

In 2013, we acquired Mailbox because we believed in the way it was making mobile email better. In 2014, we launched Carousel to create a new way to experience and share photos. With both, we aspired to extend the simplicity of Dropbox to other parts of our users’ lives.

Building new products is about learning as much as it’s about making. It’s also about tough choices. Over the past few months, we’ve increased our team’s focus on collaboration and simplifying the way people work together. In light of that, we’ve made the difficult decision to shut down Carousel and Mailbox.

Like Gabe, I never really quite understood how Mailbox fit into the Dropbox ecosystem and was surprised when the acquisition was announced. It was essentially a Gmail client and it doesn’t use any features that would prevent it working without Dropbox.

Given that Dropbox open-sourced Hackpad (another acquisition the company made in 2014) rather than kill it off, it’s a shame they didn’t spin the two apps off1 or see if another development team would be willing to carry the torch.

  1. That sound you hear is Myke Hurley weeping at the realisation he has to start using another iOS Mail client.