markstuartwalker wrote:Might I suggest that you replace the "Unix Folder Separator" switch with a more generic solution which can replace chunks of the m3u destination path in a similar style to the "Replace folders in m3u files". After all '\'->'/' replaces the separators to make it unix, I simply want to replace separators with an abstract character, say '-'.
I am already thinking to implement possibility to specify destination path for .m3u files using some option similar to "Replace folders". However, I don't want to change Options sheet so much because I have no free space on it (and I don't like an idea to create one additional option sheet for few extra options). This is a reason why I considered a possibility to use same "Replace folders" controls for both things, i.e. for specifying physical destination path of .m3u files and for their representation inside of .m3u files themselves. Anyway, I think now that it would be better if I just add one more radio button "Export to single folder" in same group with "Export to parent/child folders", then one text box for specifying that folder and one text box for specifying separator which will be used in file names of .m3u files.
I know that "Unix folder separator" option could be replaced with the option similar to "Replace folders", but I though that it is more easier, especially for beginners, to tick just one check box then to specify some complicated Regular expression. This is also a reason why I asked you about Unix/Linux since I have a very limited knowledge about it. I need to know if I could replace x: with /x always (where "x" is arbitrary drive letter), or is it something which is specific to your Subsonic Linux server. If it is general stuff related to Linux, I could implement that replacement of drive letter into the script and instead of "Unix folder separator" option I will make it as "Unix paths in .m3u files".
Also, I think that it is not so simple to just replace all "\" in path with "-" as you suggest. What if someone wants to put all .m3u files into e.g. Playlists folder which is in the root, so instead of e.g. x:\My Music\Rock\Pink Floyd\Dark Side of the Moon\ you want to get x:\Playlists\Rock-Pink Floyd-Dark Side of the Moon.m3u - as you could see, the first two "\" should not be replaced with "-".
You could have a single string that contains a list of source/destination pairs to be actioned on the m3u path. If the pair separator were ',' and space were the list separators.
Again, it is not so simple as you think. What if someone wants to use a comma or a space character for replacement and how script could know that they are not pair/list separators that you are suggesting? I think that "Replace folder" option is already too complicated for most users and I bet that many users don't use it at all. I am not sure that introducing some new, even more complicated syntax for replacement is the best approach.