GithubHelp home page GithubHelp logo

fiz-victor / netease-cloud-music-card Goto Github PK

View Code? Open in Web Editor NEW

This project forked from rugermccarthy/netease-music-card

0.0 0.0 0.0 15.34 MB

🎧 在 Github Profile 上显示你这周在网易云音乐上最喜欢听的歌曲 🎵

License: MIT License

JavaScript 78.79% CSS 12.71% HTML 8.49%

netease-cloud-music-card's Introduction

Netease Cloud Music Card

🎧 在 Github Profile 显示你这周在网易云音乐上最喜欢听的歌曲 🎵

🚀使用方法(一定要按顺序):

🎒 Fork 一份此仓库或者自己新建一个仓库

1. 获取网易云音乐用户 id

image

然后修改 main.yml 中的 USER_ID

2. 获取网易云音乐用户的 TOKEN

  • 打开网页控制台,找到 Application 下 Cookie 为 MUSIC_U 的值 }QV)3FH9@L9LUJ({35JJI}M
  • 打开自己项目中的设置,找到 Secrets 新建一个名为 USER_TOKENSecrets image
  • 将第一步获取到的值粘贴进去

3. 修改 main.yml

main.yml 中的 AUTHOR 修改为自己的 Github 用户名即可

4. 引用图片

最后只需要在你的 github profile 仓库添加图片链接即可

![card](https://github.com/你的 Github 用户名/netease-cloud-music-card/blob/main/card.svg)

你也可以使用 Jsdelivr CDN 来引用图片

![card](https://cdn.jsdelivr.net/gh/你的 Github 用户名/netease-cloud-music-card/card.svg)

你也可以将这个图片部署到你的博客等地方 😋

💨 本地测试:

Fork 项目或者新建一份。

npm install

card 文件夹下为测试界面部分,可以自己设计界面。

如果你想直接在仓库的 workflow 里面查看详细的输出,可以不需要 .env 文件

如果你想在本地测试网易云 API 并且查看,请填写相应的值,并注意在 push 到仓库之前删除它

❤️ 灵感和帮助:

🤔 工作原理:

  • 使用 NeteaseCloudMusicApi 获取听歌记录
  • 基于 Github API 将 index.js 处理好的 svg 写入到仓库中
  • 使用 Github Actions 定期更新 card.svg

📄 开源协议

MIT License

Copyright (c) 2021 Nthily

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

netease-cloud-music-card's People

Contributors

github-actions[bot] avatar hexadecimal233 avatar whitescent avatar

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.