Copying dynamic link with cronjob
the title might be confusing but I couldn't find a better one.
Here is my problem:
I've found a website which provides a .pdf document but the link and the document changes every week.
E.g. the link for this week is: blabla.com/week21.pdf
for the next week: blabla.com/week22.pdf
Now I want to copy the whole document and mirror it to my server. So I wanted to do this with a cronjob. The cronjob should just copy the .pdf and save it on my server as a static link, which can by overwritten every week be the new document.
Can someone help me with creating such a cronjob? It would also be great if the cronjob could work off a list which contains the dynamic links because the only thing which changes from week to week is the number.
date +%W ... gives you the week of the year
curl -o saved.pdf "blabla.com/week"$(date +%W)".pdf"