Skip to content

ljh-sh/macli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

macli

macOS system tools CLI with JSON/YAML output. Zero dependencies.

Install

swift build -c release
cp .build/release/macli /usr/local/bin/

Commands

cal - Calendar Management

macli cal ls                  # List all calendars
macli cal add --name Work     # Create calendar
macli cal rm --name Work      # Delete calendar

event - Calendar Events

macli event ls --calendar Work                    # List events
macli event add --calendar Work --title Meeting \
                --start "2024-01-15 10:00" \
                --end "2024-01-15 11:00"          # Create event
macli event rm --id <event-id>                    # Delete event

reminder - Reminders

macli reminder ls             # List reminder lists
macli reminder add --name Shopping  # Create list

notify - System Notifications

macli notify --title "Alert" --body "Task done"
macli notify --title "Test" --sound    # With sound

location - Current Location

macli location                # Get current coordinates

speak - Text to Speech

macli speak "Hello World"     # Speak text

speech - Speech Recognition

macli speech recognize --file audio.m4a  # Transcribe audio

smc - Apple Silicon SMC Sensors (M1/M2/M3/M4/M5)

macli smc temp        # Temperature sensors (JSON)
macli smc temp --tsv  # Temperature sensors (TSV)
macli smc volt        # Voltage sensors
macli smc curr        # Current sensors
macli smc all         # All sensors

Subcommands: temp, volt, curr, power, fans, batt, all

Options: --tsv - Output TSV instead of JSON

smc86 - Intel SMC Sensors (Legacy)

macli smc86 temp      # Temperature sensors
macli smc86 fans      # Fan speeds
macli smc86 batt      # Battery status
macli smc86 all       # All sensors

Output Format

JSON (default)

{
  "ok": true,
  "source": "HID",
  "sensors": [
    {"name": "PMU tdie1", "value": 57.5, "unit": "°C"}
  ],
  "count": 45
}

TSV (--tsv)

name    value   unit
PMU tdie1       57.5    °C

Binary Size

  • Binary: ~580KB
  • Compressed (tar.xz): ~136KB

License

Apache 2.0


For development docs, see DEV.md

About

macOS system tools. Native Apple frameworks. Human and AI friendly with JSON/YAML output.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors