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] Give option to output M3U playlist file rather than depend on MPD #11

Open
Daja177 opened this issue Sep 10, 2024 · 1 comment

Comments

@Daja177
Copy link
Contributor

Daja177 commented Sep 10, 2024

As great of a tool impd is, one aspect I'm not too big of a fan of is its dependence on MPD when there are other music players people might want to use. Having the option to create an M3U playlist file would allow people to use any music player that supports M3U, including ones on devices that aren't computers, and also make MPD optional rather than essential.

For quite some time I've achieved this by replacing the reshuffle() function with one with this command:

find "$immersionpod_dir/$current" -type f -printf '%P\n' -iname "*.mp3" -o -iname "*.opus" -o -iname "*.ogg" -o -iname "*.wav" -o -iname "*.m4a" -o -iname "*.wma" | shuf > "$immersionpod_dir/$current/impd.m3u"

This isn't a particularly elegant solution nor do I know how to do a better one, which is why I'm creating an issue rather than a pull request.

tatsumoto-ren added a commit that referenced this issue Sep 11, 2024
@tatsumoto-ren
Copy link
Member

This isn't a particularly elegant solution nor do I know how to do a better one, which is why I'm creating an issue rather than a pull request.

I'm not familiar with the m3u format but your solution just prints a list of file names to a *.m3u file. I don't think it can be wrong.

I made a PR that adds this as a new function.

tatsumoto-ren added a commit that referenced this issue Sep 12, 2024
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