Calendar automation question

Hi all

I have a piece of calendar automation I want to build into my iCloud calendar. I am agnostic about how this result is achieved ie scriptable, shortcuts etc. I think I have the steps figured out but I cannot build what I need.

  1. Manually entered variable for the starting integer
  2. Concatenated with another variable which is the name of the exercise
  3. A start date is selected
  4. The integer is incremented by one after each loop
  5. Every other day the event is added to my calendar until the integer reaches 100
  6. Then it just keeps repeating every other day at 100 with no end date

So the result would be

Starting integer = 10
Name variable = squats
Start date 28th jan

Monday - event in calendar “10 squats”

Wednesday - event in calendar “11 squats”

Friday - event in calendar “12 squats”

If anyone has any tips or ideas they would be gratefully received.

You could solve this in a number of ways by developing the steps you have and potentially taking advantage of recurring calendar events for the final entry though that might be a bit tricker depending upon option granularity for the period frequency of the event.

What I’m curious about is the statement that you “cannot” build what you need but then ask for suggestions indicating you do plan to do the building. What is the limiting factor here? I’m guessing the nature of it would probably directly affect the sort of recommendations on approached you might take.

I think Shortcuts should be able to handle all of this pretty easily—and I could try to whip something up in the next few days if that would be helpful (I have things I am procrastinating on…) - but as said above, it would be helpful to get some idea of the limitations you’re running across.

The only thing I don’t think it could do would be the final repeating event. At least, not with the built-in Calendar app—I think Fantastical might be able to do this, but I don’t have it installed so I can’t test. You could manually adjust the final event, though, once the others have been created. (Something with AppleScript might be better at this but I’m far from a pro at AppleScript so it would take me forever.)

1 Like

I know what I want to do. I think I have broken them down into programmable steps?! I guess I just cannot work out how to take those steps, select the right piece of software for the job (it’s sounding like pure shortcuts is a possibility) and piece together the actions that give the right result.

Hopefully that is more clear?

Very kind offer - thankyou

Well if you don’t know JavaScript or Python already and how to program, then Scriptable and Pythonista would be a bit of a learning curve to deal with this - though they might get you a more “perfect” solution.

It sounds like Shortcuts would be your best bet … for now at least.

The shortcut linked below will ask for a start date & time, end date & time (for the first set to get the expected duration), exercise, initial set size, final set size, and the number of days to between set increments (e.g. 2 days). It is pre-populated with some sample data for you to see how it works, but I’ve specifically made it a small set range, and you will want to set your own calendar - I’ve used my test calendar.

  • Custom Shortcut: Exc.

Shortcuts has no native access to repeat periods for calendar events, so at the end, the shortcut opens the last event so you can set the desired repeat on it. Now here’s the rub. “Every 2 days” isn’t an option. Take a look at what Calendar offers you for details.

At this point you could simply extend the shortcut to enter X number of identical events once it reaches the last of the incrementations on the number of exercises. You might try an alternate calendar like Fantastical (or any URL scheme enabled calendar app) to get around the default repeat durations; but I haven’t had time to check your options around what is on offer in terms of standard period variation. You could switch to a different creation platform that might let you create it. This could be something that simply just runs on IFTTT or a local computer that keeps track of your increments. There are quite literally so many ways to tackle this on an ongoing basis. But it should really be something that you can customise and maintain yourself.

If you’re not yet comfortable at digging in to specific automation apps to develop personal solutions, then maybe some of the available reminder and to-do list apps (i.e. rather than calendar ones) might be something that is more appropriate for your use case? Or maybe a dedicated exercise app? I’d be surprised if there wasn’t something out there that could accommodate the sort of repeat cycle you provided in your initial use case.

Hope that helps.

1 Like

Ah, I built one too but it sounds like yours is better than mine. Here it is anyway if anyone wants it: https://www.icloud.com/shortcuts/a05dbe2e46e14ee394761ef84a770bb3

It just adds all-day events until it hits 100 so again you need to deal with that part. But I think it is actually possible to repeat every two days—at least on my iOS calendar (just the stock app) I have a “personalised” option under the repeat settings that can be changed to a frequency of “every day” but then you can repeat every X number of days. Seems to work for my Exchange and Google Calendars so that might work for you.

3 Likes

I’ve never seen that detail before. Looks like it is therefore possible to manually set the repeat period as 2 days on a final event in the calendar. :sunglasses:

1 Like

That is perfect, thankyou!