in an existing project, I need to restructure my panel somewhat and I need to assign a template to images and videos that had not assigned any template so far. Is there a quick way to do this, without going through all the content files manually? Like, could Kirby not assign this automatically somehow, once there is a new File Blueprint that matches the file type? Am I missing something?
Is there any documentation on how such scripts can be written? I guess I have a vague idea that I will have to loop over every file on my site and update its template value, but where do I need to place the script? How do I run it?
Wait, how do I loop over all files of the entire web page? I thought I need to loop over $site->files() but that only gets me the files that are stored on the top level.
Ah, didn’t see your answer in time. I worked really well like this. If I have thousands of files in the future, I will keep in mind to utilize filters. Thanks!