Coding

Home Music Enhanced

Try it

Control whole-house music scenes combining Spotify playback with Airfoil speaker routing. Quick presets for morning, party, chill modes.

What it does

*"Why click 17 times when one command does the job?"* โ€“ Owen ๐Ÿธ

The skill document

    โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ
    
    ๐Ÿ   H O M E   M U S I C  ๐ŸŽต
    
    โ•”โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•—
    โ•‘   Whole-House Music Scenes               โ•‘
    โ•‘   One command. All speakers. Perfect.    โ•‘
    โ•šโ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
    
    โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ โ™ช โ™ซ

"Why click 17 times when one command does the job?" โ€“ Owen ๐Ÿธ


๐ŸŽฏ What Does This Skill Do?

Home Music combines Spotify + Airfoil into magical music scenes. One command โ€“ and the right playlist plays on the right speakers at the perfect volume.

Imagine:

  • You wake up โ†’ home-music morning โ†’ Gentle tunes in the bathroom
  • Friends arrive โ†’ home-music party โ†’ All speakers blasting rock
  • Time to relax โ†’ home-music chill โ†’ Lounge vibes everywhere
  • Done for the day โ†’ home-music off โ†’ Silence. Peace. Serenity.

๐Ÿ“‹ Dependencies

WhatWhyLink
๐Ÿ macOSThis skill uses AppleScriptโ€”
๐ŸŸข Spotify Desktop AppThe music source! Must be running.spotify.com
๐Ÿ“ก AirfoilRoutes audio to AirPlay speakersrogueamoeba.com
๐ŸŽต spotify-applescriptClawdbot skill for Spotify controlskills/spotify-applescript/

โš ๏ธ Important: Both Spotify and Airfoil must be running before you start any scenes!


๐ŸŽฌ Scenes

๐ŸŒ… Morning

A gentle start to your day

home-music morning
  • Speaker: Sonos Move
  • Volume: 40%
  • Playlist: Morning Playlist
  • Vibe: โ˜• Coffee + good vibes

๐ŸŽ‰ Party

Time to celebrate!

home-music party
  • Speaker: ALL (Computer, MacBook, Sonos Move, Living Room TV)
  • Volume: 70%
  • Playlist: Rock Party Mix
  • Vibe: ๐Ÿค˜ Neighbors hate this one trick

๐Ÿ˜Œ Chill

Pure relaxation

home-music chill
  • Speaker: Sonos Move
  • Volume: 30%
  • Playlist: Chill Lounge
  • Vibe: ๐Ÿง˜ Om...

๐ŸŽง Focus

Deep work / concentration

home-music focus
  • Speaker: Computer
  • Volume: 35%
  • Playlist: Lo-Fi Beats
  • Vibe: ๐Ÿ’ป In the zone, no vocals

๐Ÿท Dinner

Cooking & dining ambiance

home-music dinner
  • Speakers: Sonos Move + Living Room TV
  • Volume: 35% / 25%
  • Playlist: Jazz Vibes
  • Vibe: ๐Ÿณ Sizzle & chat

๐ŸŒ™ Sleep

Bedtime wind-down

home-music sleep
  • Speaker: Sonos Move
  • Volume: 15%
  • Playlist: Sleep Ambient
  • Vibe: ๐Ÿ˜ด Drift off gently

๐Ÿ”‡ Off

Silence

home-music off
  • Pauses Spotify
  • Disconnects all speakers
  • Vibe: ๐Ÿคซ Finally, peace and quiet

๐Ÿ“Š Status

What's playing right now?

home-music status

Shows:

  • Current Spotify track
  • Connected speakers

๐Ÿ”ง Installation

# Make the script executable
chmod +x ~/clawd/skills/home-music/home-music.sh

# Symlink for global access
sudo ln -sf ~/clawd/skills/home-music/home-music.sh /usr/local/bin/home-music

Now home-music works from anywhere in your terminal! ๐ŸŽ‰


๐ŸŽจ Custom Playlists & Scenes

Changing Playlists

Open home-music.sh and find the playlist configuration:

# === PLAYLIST CONFIGURATION ===
PLAYLIST_MORNING="spotify:playlist:19n65kQ5NEKgkvSAla5IF6"
PLAYLIST_PARTY="spotify:playlist:37i9dQZF1DXaXB8fQg7xif"
PLAYLIST_CHILL="spotify:playlist:37i9dQZF1DWTwnEm1IYyoj"

How to find Playlist URIs:

  1. Right-click on a playlist in Spotify
  2. "Share" โ†’ "Copy Spotify URI"
  3. Or copy the URL and extract the /playlist/ part

Adding a New Scene

Add a new case in the main block:

# In home-music.sh after the "scene_chill" function:

scene_workout() {
    echo "๐Ÿ’ช Starting Workout scene..."
    airfoil_set_source_spotify
    airfoil_connect "Sonos Move"
    sleep 0.5
    airfoil_volume "Sonos Move" 0.8
    "$SPOTIFY_CMD" play "spotify:playlist:YOUR_WORKOUT_PLAYLIST"
    "$SPOTIFY_CMD" volume 100
    echo "โœ… Workout: Sonos Move @ 80%, Pump it up!"
}

# And in the case block:
    workout)
        scene_workout
        ;;

Available Speakers

ALL_SPEAKERS=("Computer" "Andy's M5 Macbook" "Sonos Move" "Living Room TV")

You can add any AirPlay speaker โ€“ they just need to be visible in Airfoil.


๐Ÿ› Troubleshooting

โŒ "Speaker won't connect"

Check 1: Is Airfoil running?

pgrep -x Airfoil || echo "Airfoil is not running!"

Check 2: Is the speaker on the network?

  • Open the Airfoil app
  • Check if the speaker appears in the list
  • Try connecting manually

Check 3: Is the name exactly correct?

  • Speaker names are case-sensitive!
  • Open Airfoil and copy the exact name

โŒ "No sound"

Check 1: Is Spotify playing?

~/clawd/skills/spotify-applescript/spotify.sh status

Check 2: Is the Airfoil source correct?

  • Open Airfoil
  • Check if "Spotify" is selected as the audio source
  • If not: Click "Source" โ†’ Select Spotify

Check 3: Speaker volume?

# Manually check volume
osascript -e 'tell application "Airfoil" to get volume of (first speaker whose name is "Sonos Move")'

โŒ "Spotify won't start"

Is Spotify open?

pgrep -x Spotify || open -a Spotify

Is spotify-applescript installed?

ls ~/clawd/skills/spotify-applescript/spotify.sh

โŒ "Permission denied"

chmod +x ~/clawd/skills/home-music/home-music.sh

๐Ÿ”Š Direct Airfoil Commands

If you want to control Airfoil manually:

# Connect a speaker
osascript -e 'tell application "Airfoil" to connect to (first speaker whose name is "Sonos Move")'

# Set speaker volume (0.0 - 1.0)
osascript -e 'tell application "Airfoil" to set (volume of (first speaker whose name is "Sonos Move")) to 0.5'

# Disconnect a speaker
osascript -e 'tell application "Airfoil" to disconnect from (first speaker whose name is "Sonos Move")'

# List connected speakers
osascript -e 'tell application "Airfoil" to get name of every speaker whose connected is true'

# Set audio source
osascript -e 'tell application "Airfoil"
    set theSource to (first application source whose name contains "Spotify")
    set current audio source to theSource
end tell'

๐Ÿ“ Files

skills/home-music/
โ”œโ”€โ”€ SKILL.md        # This documentation
โ””โ”€โ”€ home-music.sh   # The main script

๐Ÿ’ก Pro Tips

  1. Set aliases for even faster access:

    alias mm="home-music morning"
    alias mp="home-music party"
    alias mc="home-music chill"
    alias mo="home-music off"
    
  2. Use with Clawdbot:

    "Hey, start party mode" "Put on some chill music" "Stop the music"

  3. Combine scenes: Create a dinner scene with a jazz playlist at 25% โ€“ perfect for guests!


๐Ÿธ Credits

โ•ญโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚                                             โ”‚
โ”‚   Crafted with ๐Ÿ’š by Owen the Frog ๐Ÿธ      โ”‚
โ”‚                                             โ”‚
โ”‚   "Ribbit. Music makes everything better."  โ”‚
โ”‚                                             โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ

Author: Andy Steinberger (with help from his Clawdbot Owen the Frog ๐Ÿธ)
Version: 1.1.0
License: MIT
Pond: The one with the water lilies ๐Ÿชท


Did this skill improve your life? Owen appreciates flies. ๐Ÿชฐ

Related skills

Find why your productivity system keeps failing, then apply the smallest fix โ€” capacity math, bottleneck routing, durable local notes.

by Ivรกn854 installs69 stars

figma-use

Official

Pre-flight rules and conventions for executing JavaScript in Figma files via the use_figma MCP tool.

by OpenAI27.5k stars

cli-creator

Official

Generate a durable, composable CLI from API docs, OpenAPI specs, curl examples, SDKs, web apps, or scripts.

by OpenAI27.5k stars

aspnet-core

Official

Pick the right ASP.NET Core app model and build with current host, middleware, and feature patterns.

by OpenAI27.5k stars

Turn a creative brief into a p5.js generative artwork with a written philosophy and an interactive viewer.

by Anthropic177.2k stars

More from terrycarter1985

Browse all skills

Grade English homework for Chinese primary students in grades 3โ€“6 with consistent, age-appropriate feedback.

by terrycarter198517 installs

Analyze stocks and cryptocurrencies using Yahoo Finance data. Supports portfolio management (create, add, remove assets), crypto analysis (Top 20 by market c...

by terrycarter198524 installs

Control whole-house music scenes combining Spotify playback with Airfoil speaker routing. Quick presets for morning, party, chill modes.

by terrycarter198519 installs

Comprehensive developer cheatsheets and quick references for Git, Docker, Kubernetes, jq, curl, and common Linux commands. Use when needing quick lookups for...

by terrycarter198516 installs

Control whole-house music scenes combining Spotify playback with Airfoil speaker routing. Quick presets for morning, party, chill modes.

by terrycarter198516 installs