Need help with a Shortcut

I have a Shortcut setup now that pulls a copy of the front page my local newspaper from a url, converts it to a jpeg and loads it up in Day One for me to do a journal entry. The front page comes from the Newseum’s website and the url to pull it changes for each day of the month.

Currently I have that day of the month as a variable that I manually enter when the Shortcut is processing. In the Shortcut the url looks like this Number/GA_AJC.pdf and then after I enter the day of the month when prompted it ends up looking like

I would like to automate this further to have the day number be automatically entered based on whatever the date is, but I cannot figure out an obvious way to make that happen. Can anyone point me in the right direction on this?

Is this what you mean?

One detail I realize now I failed to mention is that the date in the URL when we are in the 1st-9th of the month is a single digit. What you laid out above will work from the 10th on, but I am correct to assume that when it gets back to the beginning of the month the date generated for the first will be 01, right?

Correct, but changing dd to d solves that problem (and yes, it shows two digits when relevant).


Perfect. Thanks for the help with this.

1 Like