Skip to main content

A package to play an alarm after an interval

Project description

PyBites Alarm

Play a music file after an interval of N minutes. You can configure the tune to play ...

Setup

git clone git@github.com:PyBites-Open-Source/pybites-alarm.git
cd pybites-alarm
make install
make test

Configure

Create an .env file and add ALARM_MUSIC_FILE to an absolute path of the music file that should play when the timer ends. For example:

$ cat .env
ALARM_MUSIC_FILE=/Users/bbelderbos/Music/alarm.mp4

You can also set ALARM_DURATION_IN_SECONDS=<number_of_seconds_int> to stop the alarm after N seconds.

Usage

$ python -m alarm.alarm -h
usage: alarm.py [-h] (-s SECONDS | -m MINUTES) [-b | -d] [-l SONG_LIBRARY | -f FILE | -v]

Play an alarm after N minutes

optional arguments:
  -h, --help            show this help message and exit
  -s SECONDS, --seconds SECONDS
                        Number of seconds before playing alarm (default: None)
  -m MINUTES, --minutes MINUTES
                        Number of minutes before playing alarm (default: None)
  -b, --background      Run timer in the background (default: False)
  -d, --display_timer   Show timer in console (default: False)
  -l SONG_LIBRARY, --song_library SONG_LIBRARY
                        Take a random song from a song library directory, supported formats: .mp3, .mp4, .wav (default: None)
  -f FILE, --file FILE  File path to song to play as alarm (default: None)
  -v, --version         show program's version number and exit

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pybites-alarm-0.0.1.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pybites_alarm-0.0.1-py3-none-any.whl (4.8 kB view details)

Uploaded Python 3

File details

Details for the file pybites-alarm-0.0.1.tar.gz.

File metadata

  • Download URL: pybites-alarm-0.0.1.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for pybites-alarm-0.0.1.tar.gz
Algorithm Hash digest
SHA256 b367c241fb1d1399a1486da052a858fb751155c3408c55f299a7f3d49ae3019f
MD5 5a313dd05b33119eb47fe098e1369973
BLAKE2b-256 dedf942c8c285101e83a9b7014132492a04c1093608aac8aa80ce319a5d1ca78

See more details on using hashes here.

File details

Details for the file pybites_alarm-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: pybites_alarm-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 4.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for pybites_alarm-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 9dcc5bed21c42853fa0cde3f5273a26a38e1c284b3883e5d9afc84464be6b851
MD5 45c047e4fdda77ec07294f83ce21f697
BLAKE2b-256 0b63e32f17d3d56c7b75596a17a1fbb0f6e9587fe3ee9f53120ece2f79d32a36

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page