-
-
Save cosven/0923596c4792b97c61548b62a74c6fd1 to your computer and use it in GitHub Desktop.
导出网易云音乐歌单到 fuo 文件
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Usage: | |
1. 在 FeelUOwn 中登录网易云 | |
2. fuo exec < t.py | |
""" | |
from fuo_netease import provider | |
from fuocore.models.uri import reverse | |
from fuocore.cmds.helpers import show_song | |
user = provider._user | |
# for pl in user.playlists: | |
# print(reverse(pl)) | |
def export_pl(pl): | |
with open(f'{pl.name}.fuo', 'w') as f: | |
songs_g = pl.create_songs_g() | |
for song in songs_g: | |
f.write(show_song(song, brief=True)) | |
f.write('\n') | |
export_pl(user.playlists[0]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment