Git Product home page Git Product logo

neteaserecommendationsync's Introduction

Banner

功能

  • 同步网易云音乐每日推荐至 Spotify
  • 将网易云音乐我喜欢的音乐导入至 Spotify 歌单
  • 同步 Spotify 所喜欢的音乐至网易云音乐(用于算法优化)
    • 现在使用的逻辑为,在同步网易云音乐每日推荐至 Spotify 后,保存解析的网易云音乐歌曲 -> Spotify Track 的 ID 映射,这样可保证同步的音乐是网易云音乐此前推荐音乐中的,杜绝由于搜索词不同导致的同步偏差或遗漏。
    • 但此逻辑对于非每日推荐的音乐无效。后续将考虑对这部分没有匹配的音乐通过搜索词进行匹配后同步喜欢状态。
  • 同步网易云音乐歌单至 Spotify

使用

Docker

  1. curl -o .env -L https://github.com/GalvinGao/NeteaseRecommendationSync/raw/main/.env.example 后,修改 .env 配置

    1. SPOTIFY_CLIENT_IDSPOTIFY_CLIENT_SECRET 为 Spotify 开发者账号的 Client ID 和 Client Secret;申请请参考 Spotify for Developers

    2. NETEASE_MUSIC_PHONENETEASE_MUSIC_PASSWORD 为网易云音乐账号的手机号和密码。

  2. 获取预置的 docker-compose.yml,修改(若需要)后启动服务

curl -o docker-compose.yml -L https://github.com/GalvinGao/NeteaseRecommendationSync/raw/main/docker-compose.yml
# edit docker-compose.yml if needed
docker-compose up -d

本地运行

  1. cp .env.example .env 后修改 .env 配置

    1. SPOTIFY_CLIENT_IDSPOTIFY_CLIENT_SECRET 为 Spotify 开发者账号的 Client ID 和 Client Secret;申请请参考 Spotify for Developers

    2. NETEASE_MUSIC_PHONENETEASE_MUSIC_PASSWORD 为网易云音乐账号的手机号和密码。

  2. 配置修改完毕后,使用 npm run start 启动每日推荐服务

    1. 或者使用 npm run importLike 将网易云音乐我喜欢的音乐导入至 Spotify 歌单。需要注意的是,在此模式下,由于 Spotify API 的速率限制,根据歌单长度的不同,导入耗时将在 1 - 10 分钟不等。
  3. 留意 Console 信息,你将需要通过 Spotify OAuth 授权本服务访问你的 Spotify 账号

  4. 授权通过并完成首次同步后,本项目将会:

    1. Asia/Shanghai 时区的每天 6:10 AM 自动同步网易云音乐每日推荐至 Spotify
    2. Asia/Shanghai 时区的每天 9:10 AM, 15:10 PM, 21:10 PM, 3:10 AM 自动同步 Spotify 所喜欢的音乐至网易云音乐

License

MIT

致谢

neteaserecommendationsync's People

Contributors

borraken avatar galvingao avatar poiuy1234 avatar renovate[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

neteaserecommendationsync's Issues

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • chore(deps): update dependency @types/node to v18.16.17
  • chore(deps): update dependency eslint-config-prettier to v8.8.0
  • chore(deps): update dependency eslint-plugin-import to v2.27.5
  • chore(deps): update dependency eslint-plugin-jsx-a11y to v6.7.1
  • chore(deps): update dependency prettier to v2.8.8
  • chore(deps): update dependency typescript to v4.9.5
  • fix(deps): update dependency @reduxjs/toolkit to v1.9.5
  • fix(deps): update dependency dotenv to v16.1.4
  • fix(deps): update dependency luxon to v3.3.0 (luxon, @types/luxon)
  • fix(deps): update dependency node-fetch to v3.3.1
  • fix(deps): update dependency pino to v8.14.1
  • fix(deps): update dependency pino-pretty to v9.4.0
  • fix(deps): update prisma monorepo to v4.15.0 (@prisma/client, prisma)
  • chore(deps): update dependency typescript to v5
  • chore(deps): update node.js to v20
  • 🔐 Create all rate-limited PRs at once 🔐

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

docker-compose
docker-compose.yml
dockerfile
Dockerfile
  • node 19
  • node 19
github-actions
.github/workflows/build.yml
  • actions/checkout v3
  • docker/setup-buildx-action v2
  • docker/login-action v2
  • docker/metadata-action v4
  • docker/build-push-action v4
  • marvinpinto/action-automatic-releases v1.2.1
npm
package.json
  • @prisma/client ^4.6.1
  • @reduxjs/toolkit ^1.8.6
  • dotenv ^16.0.3
  • fast-levenshtein ^3.0.0
  • luxon ^3.1.0
  • NeteaseCloudMusicApi ^4.8.2
  • node-fetch ^3.2.10
  • node-notifier ^10.0.1
  • node-schedule ^2.1.0
  • p-limit ^4.0.0
  • pino ^8.7.0
  • pino-pretty ^9.1.1
  • prisma ^4.6.1
  • @trivago/prettier-plugin-sort-imports ^4.0.0
  • @types/async ^3.2.15
  • @types/fast-levenshtein ^0.0.2
  • @types/luxon ^3.1.0
  • @types/node ^18.11.9
  • @types/node-notifier ^8.0.2
  • @types/node-schedule ^2.1.0
  • @typescript-eslint/eslint-plugin ^5.42.1
  • esbuild ^0.15.16
  • esbuild-node-tsc ^2.0.4
  • eslint ^8.27.0
  • eslint-config-prettier ^8.5.0
  • eslint-import-resolver-typescript ^3.5.2
  • eslint-plugin-import ^2.26.0
  • eslint-plugin-jsx-a11y ^6.6.1
  • eslint-plugin-prettier ^4.2.1
  • esno ^0.16.3
  • prettier ^2.7.1
  • typescript ^4.8.4
  • node >=16.0.0

  • Check this box to trigger a request for Renovate to run again on this repository

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.