Because I couldn’t find a digital Mythic GM Emulator that I liked, I decided to create my own using the iOS Shortcuts and Data Jar app.
Tag: automation
Satisfaction: setting up a Homebridge server on a Synology NAS to link a recently purchased Jinvoo Wifi wall switch to the Home app.
OmniFocus Automation – Kanban Board
Edit: Updated the plug-in to include Sal’s code for viewing the kanban tags (the top-down view) and for adding the kanban tags to OmniFocus if they don’t already exist. Updated the article’s instructions accordingly.
I’ve recently been trying out Kanban boards for my personal use, both at home and at work.
I’m by no means a software developer, but I find the idea of selecting a subset of tasks to be done today and then further highlighting the one task that is currently in progress to be very helpful for a scatterbrain like me.
In my work, I also get constantly interrupted by people asking me questions or handing me “one quick task” – so it’s always helpful to see what it was that I was working on before the interruption.
But as much as I like the Kanban board idea, I was not interested in trying another task manager (i.e. Trello). I am happy with OmniFocus, and I wanted to see whether it was possible to implement a Kanban board with OmniFocus.
Kanban Board Layout
I searched online for solutions other people have come up with. And there were a few, most of them involving the capture of OmniFocus data and then creating a visual board using some script of another.
Although there were some interesting ideas, I didn’t want a board I couldn’t edit and that required me to jump back into OmniFocus to tick off my tasks.
One of the other suggestions was to create tags for the different Kanban columns and then open multiple instances of OmniFocus, each showing their respective “column” of tasks.
This was a workable idea for me. It just required a little fiddling with Keyboard Maestro to create the three instances of OmniFocus and have them show the correct Perspective. (I’m not a programmer, so I don’t need the “Testing” column. However, I have replaced it with a “Waiting” column – sometimes, I need to pass tasks off to other people, and I need to keep track of what I’m waiting for.)
The other option, of course, is to have the one instance of OmniFocus open and select just the Kanban tags I’m interested in seeing.
Update: There is now an additional script in the plug-in called “Kanban View”. Activating this script will automatically take you into this Top-Down view. This might be the easiest way to implement the kanban view (if you don’t want to mess about with Keyboard Maestro).
OmniFocus Automation Plug-In
But this was just the barest of what I need to make a viable Kanban board – you see, I needed a way to move tasks between the columns quickly.
It was possible to edit the task tags manually, but the whole point was to make this as painless as possible (not to mention that to move a task from one column to another properly, you had to remove the tag of the previous column as well).
So I created a few automation scripts to remove unwanted Kanban tags and assign the correct one quickly.
I’ve put all six scripts into one OmniFocus Plug-In bundle. I chose to create a plug-in bundle instead of standalone files because the bundle allows me to include icons that would show up in the toolbar if you were to add the script up there.
You can download the OmniFocus plug-in here. Unzip it before trying to install it.
For more information on how to install OmniFocus automation plug-ins, please visit the Omni Automation website.
TLDR; You double click it on the .omnifocusjs file and follow the OmniFocus prompts.
There is just one thing you need to do before using the scripts – and you don’t even need to do it if you don’t care about keeping your OmniFocus tags neat – create the tag “Kanban” and create the following sub-tags (you would want them in this order):
- To Do
- In Progress
- Waiting
- Done
Update: If you run the “Kanban View” script, it will automatically create all the tags required.
How I Use the Scripts
I put the scripts in the OmniFocus toolbar for easy access.1
You might notice the icons look a little different in your version – that was because I realised at the time of creating this blogpost that my icons don’t show very well in dark mode, so I went and changed all the icons.
Otherwise, you can activate the script by going to Automation > Kanban:
Update: You will now see the “Kanban View” script above “Kanban: To Do”.
Every day I go through my master list of potential tasks and select the ones I want to work on today. I then activate the “Kanban: To Do” script and the selected tasks would be assigned the appropriate tag.
I then move to my Kanban board layout – whether that is the three-column view or the top-down view, it doesn’t matter – and I select the one item that I want to start work on. I click on the “Kanban: In Progress”. This moves the task into the appropriate “column”, and I begin my work.
If a task gets held up because I’m waiting for someone to give me something, I click on the “Kanban: Waiting” script and the task would be moved to the “Waiting” column. I either rename the task or add a note to remind myself who I was waiting.
As an alternative, you may want to check out Rosemary Orchard’s “Complete and Await Reply” automation plug-in. This plug-in marks a selected task as complete and create a duplicate of the task and prepend the task name with “Waiting on reply: ”
Just a note though: this plug-in doesn’t assign any tags to the task, so you would still need to use the “Kanban: Waiting” script to move the task to the correct column.
Once I complete a task, I use the “Kanban: Done” script to move it to the Done column. The script marks the task as completed and assigns the “Done” tag to it.
You only need to do this if you’re interested in seeing how many tasks you’ve completed in a day (it might give you a sense of accomplishment, or you may want to review your completed task for planning purposes). If you aren’t interested in this, you can mark a task as completed normally once you’re done with it.
The Done column is actually a specially created Perspective that shows all completed items with the “Done” tag.
Once I’m done with my end of the day review, I select all the tasks in the Done column and run the “Kanban: Clear” script. This would clear the “Done” tag from the tasks, and the tasks would disappear from the Done perspective.
— * —
The scripts are fairly straightforward; for the most part, they just remove and assign tags. But that’s the whole point of the automation – to remove friction and speed up a task I have to do multiple times a day.
And the great thing about this Kanban Board automation? It works even if you have other tags assigned to the tasks. If on a particular day, I didn’t want to view my task as a Kanban board I can still use my “Hot” perspective (flagged tasks with either the “Personal” or “Work” tag assigned) to work on my Top-3 tasks of the day.
Let me know in the comments below if this helped in any way.
Shortcuts – Keeping Track of Online Reading (Webcomics, Web novels, etc.)
I read a lot of web series, whether they are webcomics or web novels, so I created this Shortcut script to keep track of which chapter/episode I’m up to.
I also created a subsequent script that would extract and load the latest chapter from your reading log.
I’m sure you can tweak this to keep track of your web TV shows too.
How To Use
- You need to have both the Shortcuts app and the Drafts app on your phone (it is not necessary to have Drafts Pro)
- Download the following three scripts (you need all three for it to work properly):
To Record Your Progress
- When you’re reading your favourite web series and want to record your progress, open Share Sheet on Safari and select the “Log Web Reading” script
- Wait for a little bit, it would show two notifications. First, to tell you when your new reading log has been created, and second when your current progress has been logged.
- The next time you run the “Log Web Reading” script, you can select your previously created log in the drop-down menu to update your progress
To Load Your Latest Chapter
- To load your latest chapter, activate the “Load Web Reading” Script – I have it on my home screen, but you can activate it from Safari Share Sheet if you want.
- Select the web series you want to read
- Safari would load up the latest chapter you were reading
- When you’re done reading, remember to run “Log Web Reading” to mark down your latest chapter
How It Works
An individual Drafts note is created for each web series you want to track.
When you run the “Log Web Reading” script and select “^New Reading”, Shortcuts creates a new Drafts note for the web series you want to log.
The Shortcut script would extract the URL of the website you were on when you activated the Safari Share Sheet and save it to the Drafts note5.
The next time you run “Log Web Reading” and select an existing web series log, Shortcuts would find the original Drafts note it had created and append the latest URL to the note.
When you run the “Load Web Reading” script and select the web series you want to read, Shortcuts would find the latest entry in the Drafts note, extract the URL and load it in Safari.
How the Drafts Notes Work
For every web series you track, a Drafts note is created with the following properties:
– Titled with the name you entered in the prompt (name of the web series)
– tagged with “bookmark” and “log”
– is flagged
– is archived
Every time you run the “Log” and “Load” scripts, they would search for all the notes that match the above criteria and extract the titles to populate the web series drop-down menu.
In fact, when you run “Log Web Reading” for the first time, a note is created with the title “^New Reading” and all the above properties – which is why you have the “^New Reading” option in the drop-down menu.6 So don’t delete that note.
I create a Drafts Workspace that shows me all my reading logs – this makes it easy to manage my logs (see below)
How to Remove a Series
When you’re finished with a web series and you don’t want to it to show up on the drop-down menu anymore, simply remove the flag from the Drafts note7.
ActionCuts
This is amazing, and would save me so much time!
Shortcuts Workflow for Extracting Read Books from Goodreads
Edit: I’ve updated the workflow because I realised there was an actual book links field that I could use instead of trying to extract the book ID to build the link.
I also realise that my workflow was built using iOS 13’s Shortcuts app, so a lot of people won’t be able to use it. I will build one using iOS 12 asap and will post a link to that as soon as that’s done.
Lastly, you might find that the workflow doesn’t populate some start/finish dates. This is not an error with the workflow, instead, it seems that Goodreads doesn’t provide the dates for some of the books. The date fields are just missing, I’m not sure why. I’ve tried re-adding the dates on some of my books but they still don’t show up, although the modify dates changed, so I know something has been recorded. I will keep looking into this and will report back if I find anything.
So I forgot where I’d read it, but I saw that some people were creating a “read/reading” page1; listing all the books they’ve read/reading this year.
I’ve also created my own page, but – being the nerd that I am – I decided to create a Shortcuts workflow to help me create and maintain this list.
I use Goodreads to keep track of my books and I thought I would use Goodreads’ API to help gather the books I’ve read/currently reading, and create a markdown list with all the pertinent information (ie. title, author, date started, date finished, rating, and whether this is a re-reading of a book).
I can then prepend that list to my previously mentioned page.
I know my workflow is not very polished – my method of processing XML files probably needs work – but for now it does the job.
Installing the workflow
You can download the Shortcuts workflow here.
When you first import the script, it’ll ask you for your Goodreads ID and your API key.
You can find your Goodreads ID by going to your bookshelf after you’ve logged into Goodreads and looking at the URL; it should be the string of numbers and letters between “list/” and “?”.
eg. https://www.goodreads.com/review/list/USERNAME?shelf=read
The workflow would ask that you save your Goodreads ID in a dictionary that the workflow would then refer to.
To get a Goodreads API key, you’d need to register here. It’s free and doesn’t require more than your name and your application name (I just used “Shortcuts”).
I save my API key in a text file in my Shortcuts folder and reference it in the script.
How to use the workflow
Now for how to use the workflow.
When you run it, it’ll ask for which bookshelf you want to list. I’ve put in two options, read and currently-reading. You can add any other bookshelf you currently use.2
Then the script will ask for the number of books you want to list.
When I ran the script the first time, I entered in 200 – I knew I’ve only read about 30 books this year, but I wanted to create pages for previous years as well.
For on going maintenance of my books list, I’d probably run the script once a month and then only need to request info on 1 to 2 books.
The script would then produce a markdown list with the requested books (sorted by read date) and copy them to the clipboard. I would then paste them into my reading page.
Final words
As I’ve mentioned, my workflow is not the most polished, but I hope it helped some people. If you customised it in any quirky way or figured out a more elegant way to deal with XML files, please comment and let me know. I would love to see how people use this.
Deleting Completed Items from Reminders Using Shortcuts
I’ve always been slightly annoyed that iOS Reminder has no way to purge completed items.
Well, not unless you are willing to sit there swiping to delete each item one by one. Like an animal. 😜
After seeing my “Completed Items” reach a couple of hundreds, I decided to turn to Google to see if anyone else has come up with a solution.
The results were quite disheartening. It seems that some people are just deleting the whole list and starting from scratch.
However, I did find a Six Colors article that provided instructions on how you could bulk delete completed items from iCloud’s version of Reminders. It also made mention of an AppleScript written by Dr. Drang that, when run, would delete completed items older than 30 days.
These were all well and good, but I wanted something to run automatically every month. Or at the very least sent me a reminder to run the script.
I was thinking about setting a Due Item, or maybe even setting up a cronjob… but then I remembered the Shortcuts app.
Maybe I could create a Shortcut workflow that could find and delete completed reminder items older than 30 days?
Well, apparently I can.
It’s a very simple shortcut workflow actually:
I specify all the lists that I would like to have purged – there may be some lists that you don’t want to have all the item deleted without first reviewing them. When you install the script, Shortcuts would ask you to input your own list names.
Here I specify that items completed over 30 days ago are eligible for deletion. Change this if according to your own preferences.
Then for each of the lists specified above, the filter would find items completed older than 30 days…
and remove them.
When you run the script, Shortcut would ask you three times if you are sure you want to remove the reminders, telling you that this is a permanent action. Just click “Remove” each time and presto, the items are gone.
Now, earlier on I mentioned that I want to automate this. There’s no way for Shortcut scripts to be run automatically on a schedule, but you can create a Launch Centre Pro item set to run monthly and have it run this Shortcut script. So every month a notification would pop up, you click on it, and the Shortcut script would go about removing all the old Reminder items.
If you have your own way of removing old Reminder items leave me a comment or send me an email, I’d love to know how others solve this problem.
So the link to the Shortcut script again: Deleting Old Completed Reminders Items
Omg, this Shortcuts workflow is insane! Of course I immediately ran it, and the report was awesome!
There’s so much I could learn from dismantling this workflow.
@mentions on self-hosted micro.blog
If you self-host your microblog, I know there’s an automated way of linking @mentions to the person’s micro.blog profile.
However since I also @mention Twitter and Instagram people, I use the following TextExpander snippets instead:
For micro.blog @mentions
Trigger: m:@
[@%filltext:name=User%](http://micro.blog/%filltext:name=User%)
For Twitter @mentions
Trigger: t:@
[@%filltext:name=User%](http://twitter.com/%filltext:name=User%)
For Instagram @mentions
Trigger: i:@
[@%filltext:name=User%](http://www.instagram.com/%filltext:name=User%)
Update:
These snippets, when activated, are supposed to ask you for input on what username you’re trying to link to. There’s an issue if you’re using these snippets on the TextExpander iOS keyboard (as opposed to TextExpander enabled apps like Ulysses or Drafts).
The TextExpander iOS keyboard doesn’t support popups, so you don’t get a chance to input the username you want.
Instead, you’d get an output like this:
[@(User)](http://www.instagram.com/(User))
This means you need to manually change the “User” to whomever you wanted to link to, but the brackets get in the way of quickly double tapping “User” and just replacing it with a name.
I’m afraid that until TextExpander changes the keyboard behaviour (which I’m assuming is being controlled by Apple), there are only two work-arounds:
- Use TextExpander enabled apps like Drafts or Ulysses to draft out your post.
- Create snippets that doesn’t have the brackets, so you can replace “User” quickly on iOS devices, like the following:
[@User](http://micro.blog/User)
Let me know how you go with this, or if you have other ways of doing this. I would love to find other workarounds for this issue.
One possible way of doing this on iOS is to use the Workflow app.
You can find the workflow here.