New Folder From Selected File BUT Ignore a Pattern ?
Posted: 14 Mar 2023 20:50
hi! is it possible to detect a part of a file name (and part of it ignored by pattern) and then use it to make a new folder ?
for example, if i have this file selected : Family Dinner S03E01.mkv
the script/command would create a new folder called "Family Dinner".
the "S03E01" could be anything but it would always follow the "S##E##" pattern.
another example would be the selected file "The Art of Vintage S01E04.mkv" would then have the folder "The Art of Vintage" created, etc.
i found an example on this forum to rename a file based on the folder name but got confused trying to make it work in reverse AND ignore a pattern in the file.
for example, if i have this file selected : Family Dinner S03E01.mkv
the script/command would create a new folder called "Family Dinner".
the "S03E01" could be anything but it would always follow the "S##E##" pattern.
another example would be the selected file "The Art of Vintage S01E04.mkv" would then have the folder "The Art of Vintage" created, etc.
i found an example on this forum to rename a file based on the folder name but got confused trying to make it work in reverse AND ignore a pattern in the file.