Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature request] Allow for setting the format for the files #41

Open
X-Ryl669 opened this issue Jun 27, 2016 · 3 comments
Open

[Feature request] Allow for setting the format for the files #41

X-Ryl669 opened this issue Jun 27, 2016 · 3 comments

Comments

@X-Ryl669
Copy link

X-Ryl669 commented Jun 27, 2016

By default, zx does "Artist_Song.mp3" in "Artist_Album" folder. Is it possible to change this so it's user-defineable ?

@sk1418
Copy link
Owner

sk1418 commented Jun 27, 2016

I was considering to let user define the naming pattern. well technically, it is not hard to achieve. However the pattern elements are not so many, just albumName, ArtistsName, and Songnames. There is a trackNo too, but for xiami (or 163 I forgot which one exactly) we have to do one more request to get this NO, so I didn't go with it. Also if user gave a pattern with mistakes, e.g. the filename was not unique, then some files could be overwritten. Due to those concerns I didn't let user define the naming pattern. Currently zhuaxia has no warning or interactive options during downloading, if file overwriting occurred.

btw, what kind of naming pattern do you prefer?

@X-Ryl669
Copy link
Author

Maybe have a config line in with this (for example: formatSave="$Artist/$Album/$Song.mp3" and do a regex replace in the pattern to set the values)

@sk1418
Copy link
Owner

sk1418 commented Jun 28, 2016

@X-Ryl669 I don't want the user to define the directory structure... also zhuaxia can download mp3 of different types (single Song, multiple songs, album, user favorites, user collections, artists' top X ...) That was another reason, I didn't give user this option to customize dir/file name. I think an awk one-liner or shell script could convert the default filename into $Artist/$Album/$Song.mp3... I know that it is a workaround.. I can support if you need on batch renaming/mving

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants