basics / 03 of 15
A first wallpaper
Play a video, let phonto pick one from a folder, and start it with your session.
Play a video
phonto ~/Videos/harbour.mp4The video covers every display, cropped to the screen’s shape, and starts again from the top when it ends. phonto stays in the foreground while it plays. Press Ctrl+c to stop it, and the desktop shows whatever was there before.
On Linux the video sits on the layer-shell background layer, under your windows and bars. Layers covers the other three.
Pick one at random
Tell phonto where your videos are. On its first run it wrote a config file, ~/.config/phonto/config.toml, with every section commented out. Add a search path:
[[search_paths]]
path = "~/Videos/wallpapers"
depth = 1depth = 1 searches the folder and the folders inside it. Then:
phonto --randplays one of them, a fresh pick each time phonto starts.
Start it with your session
phonto doesn’t fork into the background. Start it the way your desktop starts any program that keeps running.
On Wayland
| compositor | in its config |
|---|---|
| Hyprland | exec-once = phonto --rand |
| Sway | exec phonto --rand |
| niri | spawn-at-startup "phonto" "--rand" |
| river | riverctl spawn "phonto --rand" |
With AeroSpace or Rift
Both tiling window managers run commands when they start. In AeroSpace, add phonto to after-startup-command. With start-at-login = true, that’s every login:
after-startup-command = [
'exec-and-forget phonto --rand --pause-on-battery',
]AeroSpace adds Homebrew’s /opt/homebrew/bin to the PATH its commands get, and finds a Homebrew phonto by name.
In Rift, add it to run_on_start:
[settings]
run_on_start = [
"/opt/homebrew/bin/phonto --rand --pause-on-battery",
]Rift starts the command without a shell. Give it phonto’s full path, the one which phonto prints.
With a LaunchAgent
Without a window manager to start it, launchd can. Save this as ~/Library/LaunchAgents/com.museslabs.phonto.plist:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.museslabs.phonto</string>
<key>ProgramArguments</key>
<array>
<string>/opt/homebrew/bin/phonto</string>
<string>--rand</string>
<string>--pause-on-battery</string>
</array>
<key>RunAtLoad</key>
<true/>
<key>StandardErrorPath</key>
<string>/tmp/phonto.log</string>
</dict>
</plist>launchd starts it at every login from then on. To start it now, without logging out, load it:
launchctl bootstrap gui/$(id -u) ~/Library/LaunchAgents/com.museslabs.phonto.plistlaunchd doesn’t use your shell’s PATH, so the plist names phonto by its full path. Errors go to /tmp/phonto.log. To stop phonto, unload it:
launchctl bootout gui/$(id -u)/com.museslabs.phontoDelete the plist as well, or launchd loads it again at the next login.
Next
- Videos and streams: what phonto can play.
- Multiple displays: a different video on each.
- Battery: pausing when the laptop is unplugged.