netease-music icon indicating copy to clipboard operation
netease-music copied to clipboard

NetEase Music Library for Emacs.

  • NetEase Music Library for Emacs

[[https://melpa.org/#/netease-music][file:https://melpa.org/packages/netease-music-badge.svg]]

** Installnation

  1. Install names.

  2. Install mplayer.

  3. Install [[https://github.com/Binaryify/NeteaseCloudMusicApi][Binaryify's NeteaseCloudMusicApi]], and start this API server. The default server address is http://localhost:3000.

  4. Download music.el from github and add this file to your load-path. #+BEGIN_SRC elisp (add-to-list 'load-path "your-path-to-netease-music.el") #+END_SRC

  5. Get YOUR-USER-ID.

    You need to request this url: http://localhost:3000/login/cellphone?phone=YOUR-PHONE-NUMBER&password=YOUR-PASSWORD.

    Replace YOUR-PHONE-NUMBER with your real phone number(China) and YOUR-PASSWORD with your real password.

    Get YOUR-USER-ID from 'account'. Just like this. [[./images/get_id.png]]

  6. Config. #+BEGIN_SRC elisp (require 'netease-music) (setq netease-music-username "YOUR-PHONE-NUMBER") (setq netease-music-user-password "YOUR-PASSWORD") (setq netease-music-user-id "YOUR-USER-ID") ;; api address default is http://localhost:3000 (setq netease-music-api "YOUR-API-ADDRESS") #+END_SRC

  7. Enjoy. [[file:images/playlist.png]]

    [[file:images/songs.png]]

    [[file:images/lyrics.png]]

** Useage

  • =M-x netease-music-init-frame= Initialize netease-music buffer.
  • =M-x netease-music-jump-into= Jump into the playlist.
  • =M-x netease-music-jump-into= Play current song.
  • =M-x netease-music-play-next= Play next song in this playlist.
  • =M-x netease-music-play-toggle= Toggle current playing status.
  • =M-x netease-music-search= Search songs.
  • =M-x netease-music-get-current-playing-artist-songs= Get current playing artist's Best 50 songs.

** Hot Key setting(Evil) #+BEGIN_SRC elisp (evil-define-key 'normal netease-music-mode-map (kbd "RET") 'netease-music-jump-into) (evil-define-key 'normal netease-music-mode-map (kbd "n") 'netease-music-play-next) (evil-define-key 'normal netease-music-mode-map (kbd "p") 'netease-music-toggle) (evil-define-key 'normal netease-music-mode-map (kbd "q") 'quit-window) #+END_SRC

** TODOList [8/8]

  • [X] 登录
  • [X] 获取所有歌单
  • [X] 获取歌单详情
  • [X] 播放歌曲
  • [X] 显示歌词
  • [X] 搜索歌曲

** Thanks [[https://github.com/Binaryify/NeteaseCloudMusicApi][Binaryify's NeteaseCloudMusicApi]] For the music api service.

[[https://github.com/zhengyuli/WangyiMusic][WangyiMusic]] For the process code.