我想将模板文件复制到文件夹结构中,同时将其重命名为将位于其中的相应子文件夹的名称(加上后缀)。
问题类似于this,但我在Mac上,想通过AppleScript或在Terminal中找到解决方案。
如果这是文件,则位于我磁盘上的某个地方,
/path/to/template.txt
然后我希望将其移动到如下所示的结构的子文件夹中:
2014-05
|----2014-05-06
| |--------2014-05-06.txt (renamed template file)
|----2014-05-08
| |--------2014-05-08.txt (renamed template file)
...