Skip to content

NyckJohnson/WindDownApp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Wind Down App

A macOS menu bar app that helps you wind down with multiple customizable routines, to-do lists, and persistent alarms.

Features

  • Multiple Routines: Create unlimited routines (Bedtime, Morning, Weekend, etc.)
  • Menu Bar App: Lives in your menu bar with a moon/stars icon
  • Per-Routine Scheduling: Each routine has its own scheduled time
  • Sequential Execution: Only one routine runs at a time; others wait their turn
  • Customizable Cards: Each routine contains multiple cards for different activities
  • To-Do Lists: Each card can have multiple to-do items that must be completed
  • Smart Alarms: Alarms go off when time expires and can be snoozed indefinitely
  • Drag & Drop: Move cards between routines in wide editing mode
  • Daily Reset: Everything resets at each routine's scheduled time
  • Apple-Style Design: Clean, native macOS interface using SwiftUI
  • Custom Sounds: Choose from macOS system sounds for each card's alarm

How It Works

Creating Routines

  1. Create multiple routines (e.g., "Bedtime Routine", "Morning Routine")
  2. Set each routine's scheduled time (e.g., 8:00 PM, 7:00 AM)
  3. Add cards to each routine for different activities
  4. Add to-do items to each card
  5. Set duration and snooze time per card

Running Routines

  • Automatic Start: Routines start at their scheduled time
  • Manual Start: Click "Start Routine" to pick and start any routine
  • Sequential Cards: Card 1 must finish before Card 2 starts
  • Blocking Finish: Must complete all to-dos before clicking "Finished"
  • Unlimited Snooze: Snooze as many times as needed
  • Queue System: If one routine runs late, the next waits

Example Setup

Bedtime Routine (8:00 PM)
├─ Prepare for bed (30 min)
│  ├─ Brush teeth
│  ├─ Wash face
│  └─ Floss
└─ Wind down (20 min)
   └─ Read

Morning Routine (7:00 AM)
├─ Wake up (15 min)
│  ├─ Make bed
│  └─ Exercise
└─ Breakfast (20 min)
   └─ Cook oatmeal

UI Modes

Inactive State - When no routine is running:

  • View all routines sorted by next scheduled time
  • Tap routine to edit its cards
  • Manual start button to begin any routine

Active State (Tall & Thin) - When routine is running:

  • Shows current routine name and progress
  • Display current card with time remaining
  • Check off to-dos
  • Snooze or finish buttons
  • Can edit current routine

Editing Mode (Wide) - Full editing interface:

  • All routines shown as columns
  • Drag cards within columns to reorder
  • Drag cards between columns to move between routines
  • Edit routine settings (name, time, enable/disable)
  • Access via "Edit All Routines" button

Setup Instructions

Prerequisites

  • macOS 13.0 or later
  • Xcode 15.0 or later
  • Apple Developer account (free tier is fine)

Installation

  1. Open the project in Xcode

    • Double-click WindDownApp.xcodeproj to open in Xcode
  2. Configure signing

    • Select the project in the left sidebar
    • Select the "WindDownApp" target
    • Go to "Signing & Capabilities" tab
    • Under "Team", select your Apple Developer account
    • Change the Bundle Identifier if needed (e.g., com.yourname.WindDownApp)
  3. Build and run

    • Select "My Mac" as the run destination
    • Click the Play button or press Cmd+R
    • Grant notification permissions when prompted
  4. First-time setup

    • Click the moon icon in your menu bar
    • Click the gear icon to set your daily start time
    • Click "Add Card" to create your first card
    • Add to-dos, set duration and snooze time
    • Repeat for additional cards

Installing Permanently

To keep the app running without Xcode:

  1. Archive the app

    • In Xcode: Product → Archive
    • Once archived, click "Distribute App"
    • Choose "Copy App"
    • Save to Applications folder
  2. Launch at login (optional)

    • Go to System Settings → General → Login Items
    • Add Wind Down App to launch at login

Project Structure

WindDownApp/
├── WindDownApp.swift              # Main app entry point & menu bar setup
├── CoreDataModels.swift            # Data models (Routine, Card, TodoItem, AppSettings)
├── RoutineManager.swift            # Business logic & multi-routine management
├── ContentView.swift               # Main container switching between states
├── RoutineListView.swift           # Inactive state - list of routines
├── RoutineDetailView.swift         # Edit single routine and its cards
├── ActiveRoutineView.swift         # Active state - tall & thin current routine
├── AllRoutinesEditView.swift       # Wide editing mode - all routines
├── CardEditorView.swift            # Card editing interface
├── SettingsView.swift              # Global app settings
├── Info.plist                      # App configuration
└── WindDownApp.entitlements        # App permissions

Architecture

Core Data Models

  • Routine: Represents a complete routine with scheduled time
  • Card: Individual activity within a routine
  • TodoItem: Tasks within a card
  • AppSettings: Global app preferences

Key Components

  • RoutineManager: Singleton that manages:

    • Multi-routine scheduling
    • Queue-based execution
    • Overdue routine detection
    • Timer management
    • Alarm triggering
    • Snooze functionality
  • AppDelegate: Handles:

    • Menu bar setup
    • Notification permissions
    • Notification actions (snooze, open app)

Flow

  1. App launches and schedules daily reset timers for all enabled routines
  2. At scheduled time, routine starts automatically (if no other routine is active)
  3. RoutineManager tracks current routine and current card
  4. When card time expires, alarm triggers
  5. User can snooze (reschedules alarm) or complete card
  6. Completing card moves to next card in routine
  7. Completing all cards ends routine
  8. System checks for overdue routines and starts next one if needed
  9. Process repeats daily for each routine

Customization

Available System Sounds

  • Basso, Blow, Bottle, Frog, Funk, Glass
  • Hero, Morse, Ping, Pop, Purr, Sosumi
  • Submarine, Tink

Modifying Default Settings

In RoutineManager.swift, createDefaultSettings():

components.hour = 20  // Change default hour (24-hour format)
components.minute = 0  // Change default minute

In CoreDataModels.swift, Card attributes:

cardDuration.defaultValue = 30  // Default duration in minutes
cardSnooze.defaultValue = 5     // Default snooze in minutes
cardSound.defaultValue = "Sosumi"  // Default alarm sound

Troubleshooting

Notifications not working

  • Check System Settings → Notifications → Wind Down App
  • Ensure notifications are enabled
  • Restart the app

App not appearing in menu bar

  • Check that LSUIElement is set to YES in Info.plist
  • Verify app activation policy is set to .accessory

Alarms not playing sound

  • Check System Settings → Sound
  • Verify sound files exist in /System/Library/Sounds/
  • Try a different sound in card settings

Core Data errors

  • Delete app data: ~/Library/Containers/com.yourname.WindDownApp/
  • Rebuild and run again

Future Enhancements

Potential features to add:

  • Day-of-week scheduling per routine (weekdays only, etc.)
  • Reorder routines via drag-and-drop
  • Statistics/history tracking per routine
  • Export/import routines
  • Routine templates library
  • Themes/color customization per routine
  • Keyboard shortcuts
  • Apple Watch companion
  • iCloud sync
  • Custom sound file support
  • Routine dependencies (one triggers another)

License

Personal use project. Modify as needed for your own use.

Notes

  • The app uses AppKit + SwiftUI for maximum macOS integration
  • Core Data provides persistent storage
  • Menu bar-only design (no dock icon)
  • Respects macOS notification preferences
  • Follows Apple's Human Interface Guidelines

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages