Giter Site home page Giter Site logo

autoplay's Introduction

autoplay

a daemon that keeps your MPD playlist filled with the music you actually listen to.

Requirements

  • python 3.x
  • python-mpd2

If you have pip installed, a simple pip install -r requirements.txt should do the job.

Usage

autoplay.py [command]
command can be one of :
  radio [on|off|toggle]     : switches between radio mode and stat collection only
  trigger [number]          : sets how many tracks must be in the playlist at all times
  info [filename]           : gives some info on the specified track, or the currently playing track

  start
  stop (synonym: kill)
  loglevel [debug|info|notice|warning|error]
  help
  version

To have autoplay start automatically, you may add autoplay.py start > /dev/null & to your .profile or .bash_profile.

Installation

Make sure you have all dependencies installed, then put autoplay.py anywhere in your $PATH.

Configuration

Autoplay will connect to the server according to environment variables MPD_HOST and MPD_PORT. The defaults are :

MPD_HOST="127.0.0.1"
MPD_PORT="6600"

A password can be used by using the syntax MPD_HOST="password@host".

If the variable MPD_MUSIC_DIR is set, Autoplay will use it to flag symlinks or hardlinks as duplicates.

How it works

Autoplay gives each song a karma rating based on how often it adds that song, and how often that song is played.

Usually, bad songs have karma under 0.25, meh songs have karma between 0.25 and 0.60, and good songs are over 0.60. A song that is often added by the user to the playlist will have a karma over 1.

When a song is played, there is a cooldown time (default 12h) during which autoplay cannot add it. This way, the same songs cannot be spammed over and over.

autoplay's People

Contributors

codl avatar

Watchers

James Cloos avatar Yorgos Dimopoulos 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.