Giter Site home page Giter Site logo

spotifytray's Introduction

Spotify Tray Wrapper

This project aims to overcome the problem the latest spotify versions introduced, which is that they have removed the tray icon and the possibility to minimize the player to tray on the Linux official client. This has forced many users to use the outdated client, which had this feature.

What this program does:

  • Finds a running instance of spotify (or launches a new one).
  • Creates a Tray icon with a menu to control playback (play/pause, next, previous).
  • Adds the possiblity to hide the spotify client (minimize to tray).

Requirements

  • A Linux distribuition (as the problem is not present on Windows/MacOS)
  • Python >= 3 (to run the script)
    • PyQt4 (to manage tray icon and menu)
  • xdotool (to hide/show spotify)
  • playerctl (to control playback)

Installation

Arch Linux

AUR Support will be added later

Clone the PKGBUILD Repository and run makepkg

$ git clone https://gist.github.com/1aeea4c39d33ea515a5cf7957053d131.git
$ cd 1aeea4c39d33ea515a5cf7957053d131
$ makepkg -s

You can then install the generated package with pacman -U

# pacman -U spotify-tray*.tar.xz

Other Distros

Real installation will be implemented soon, for now you can follow below

No installation is required. You just need to clone the repository or download the zip file locally

$ git clone [email protected]:Kasama/SpotifyTray.git
$ cd SpotifyTray

and run the script with python

$ python3 spotify-tray.py

You can also use the provided .desktop file to launch the script. The .desktop should be in /usr/share/applications/ or ~/.local/share/applications and the python script should be in your $PATH

Known Bugs

  • If you close spotify manually with this program running, it will hang useless and you won't be able to close it.

You can kill it with:

kill -9 `ps -aux | grep spotify-tray | head -1 | sed 's/\s\+/ /g' | cut -d' ' -f2`

License

This project is distributed under the MIT license.

Spotify is a trademark of Spotify Inc. It is not my work in any way and all its rights are reserved.

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.