Match Text in Name Before Dash

Get help. Get answers. Let others lend you a hand.

Moderator: Mr_Noodle

Match Text in Name Before Dash Fri Jan 27, 2017 3:46 pm • by millerstevew
I'd like to sort files into subfolders based on part of the file name—everything before a dash. Sometimes there will be one word before the dash. Other times, there might be multiple words. For example:

I'd like to sort:

"Lewis - The Lion, the Witch, and the Wardrobe.pdf" to "/Lewis/Lewis - The Lion, the Witch, and the Wardrobe.pdf"
"C.S. Lewis Institute - A Study of C.S. Lewis.pdf" to "/C.S. Lewis Institute/C.S. Lewis Institute - A Study of C.S. Lewis.pdf"

I can sort the former using the "name matches" and "custom text" token. Is it possible to have a token include spaces?
millerstevew
 
Posts: 1
Joined: Fri Jan 27, 2017 3:40 pm

Re: Match Text in Name Before Dash Mon Jan 30, 2017 1:24 pm • by Mr_Noodle
You can use spaces. Can you show me the pattern you are using and how it isn't working?
Mr_Noodle
Site Admin
 
Posts: 11872
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City


Return to Support