从本地m3u播放列表创建/更新Spotify播放列表
tospotif的Python项目详细描述
将本地播放列表转换为Spotify播放列表
目前为m3u文件工作;m3u8支持即将到来!在
使用
usage: tospotify [-h] [-v] [--public] [--playlist-id PLAYLIST_ID]
spotify_username playlist_path
Create/update a Spotify playlist from a local m3u playlist
positional arguments:
spotify_username Spotify username where playlist should be updated.
Your email address should work just fine, or could
find your user id through e.g. the developer console
playlist_path full path to the playlist
optional arguments:
-h, --help show this help message and exit
-v, --verbose print all the steps when searching for songs
--public playlist is public, otherwise private
--playlist-id PLAYLIST_ID
do not create a new playlist, instead update the
existing playlist with this id
示例
- 在
Linux/MacOS操作系统
^{pr2}$ 在 - 在
窗口*
在python -m tospotify "john.doe@gmail.com" "D:/playlist/name.m3u"
*entry_points
似乎不能简单地在Windows上工作
要求
- 在
首先需要启用开发人员仪表板和你的“应用程序”。在
- 转到https://developer.spotify.com/dashboard/login
- 创建应用程序
- 从那里获取步骤2的客户端id和客户端密码
- 编辑设置并白名单重定向uri;默认使用
http://localhost:8888
- 在
设置一些环境变量:
在
Linux
export SPOTIPY_CLIENT_ID="<paste-from-dev-dashboard>"
export SPOTIPY_CLIENT_SECRET="<paste-from-dev-dashboard>"
export SPOTIPY_REDIRECT_URI="<your-chosen-uri>"
Windows
与linux相同,但是使用set
而不是{
- 项目
标签: