MCPcopy Index your code
hub / github.com/efogdev/mpris-timer

github.com/efogdev/mpris-timer @2.2.2

Chat with this repo
repository ↗ · DeepWiki ↗ · release 2.2.2 ↗ · + Follow
88 symbols 224 edges 16 files 4 documented · 5%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Play Timer

Build

Timer app pretending to be a media player.

image

Ultimately, serves the only purpose — to start a timer quickly and efficiently. \ Notifications included! Utilizing GTK4, Adwaita and MPRIS interface.

image

Installation

flatpak install flathub io.github.efogdev.mpris-timer

AUR: play-timer \ NixOS: mpris-timer

Demo

1

Play Timer aims to be as keyboard friendly as possible. \ Use navigation keys (arrows, tab, shift+tab, space, enter) or start inputting numbers right away.

KDE Plasma

By default, Play Timer will use Breeze GTK4 theme with adjustments on Plasma. \ In case you prefer the original Adwaita look, set PLAY_TIMER_IGNORE_KDE_THEME environment variable to any non-empty value.

image

CLI use

-ui
    Show timepicker UI (default true)
-start int
    Start the timer immediately, don't show UI (value in seconds)
-notify
    Send desktop notification (default true)
-rounded
    Rounded corners (default true)
-shadow
    Shadow for progress image
-color string
    Progress color (#HEX) for the player, use "default" for the GTK accent color (default "default")
-sound
    Play sound (default true)
-soundfile string
    Filename of the custom sound (must be .mp3)
-text string
    Notification text (default "Time is up!")
-title string
    Name/title of the timer (default "Timer")
-tray
    Force tray icon presence (default false)
-volume float
    Volume [0-1] (default 1)
-lowfps
    1 fps mode (energy saver, GNOME only)

Examples

# show UI for a red "Oven" timer
play-timer -title Oven -color "#FF4200"  

# start a silent 120s "Tea" timer immediately
play-timer -title Tea -rounded=0 -sound=0 -start 120

Development

Install gsettings schema (the app will crash on start otherwise):

sudo cp misc/io.github.efogdev.mpris-timer.gschema.xml /usr/share/glib-2.0/schemas/
sudo glib-compile-schemas /usr/share/glib-2.0/schemas/

Run:

go run cmd/main.go -help

Build:

go build -pgo default.pgo -tags wayland -o ./.bin/app ./cmd/main.go

There's a Dockerfile to build easily.

Flatpak:

flatpak run org.flatpak.Builder --force-clean --sandbox --user --install --install-deps-from=flathub --ccache .build io.github.efogdev.mpris-timer.yml

Contributors

@Tuba2 — app name and icon \ @efogdev — oh wait that's me

Core symbols most depended-on inside this repo

GdkKeyvals
called by 17
internal/core/kbd.go
NumToLabelText
called by 4
internal/core/time.go
Stop
called by 4
internal/core/core.go
broadcast
called by 4
internal/core/core.go
saveSize
called by 4
internal/ui/ui.go
MakeProgressCircle
called by 3
internal/core/image.go
PlaySound
called by 3
internal/core/sound.go
Destroy
called by 3
internal/core/core.go

Shape

Function 64
Method 18
Struct 5
TypeAlias 1

Languages

Go100%

Modules by API surface

internal/core/prefs.go24 symbols
internal/core/core.go20 symbols
internal/ui/prefs.go8 symbols
internal/ui/ui.go6 symbols
internal/core/time.go5 symbols
internal/core/kbd.go4 symbols
internal/core/image.go4 symbols
internal/core/const.go4 symbols
internal/ui/tray.go2 symbols
internal/ui/notify.go2 symbols
internal/ui/input.go2 symbols
internal/core/sound.go2 symbols

For agents

$ claude mcp add mpris-timer \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact