Repository navigation
Releases
macos-cli 0.10.0
An agent can read the tour: Master Tour and Daysheets.
Added
macos mastertourtours,tour,day,summary,events,hotels,crew,guestlist: Master Tour's public API (v5), signed with your API key (OAuth 1.0, HMAC-SHA1).macos mastertour login --key KEYkeeps the key in the login keychain, the secret read from stdin; orMASTERTOUR_KEYandMASTERTOUR_SECRET.macos daysheets days [--from] [--to]anddaysheets day DATE: a Daysheets tour's calendar feed, grouped into days.macos daysheets loginkeeps the feed URL in the login keychain (from stdin); orDAYSHEETS_FEED_URL. The URL is never printed.credentials_missingandcredentials_refused(exit 4), and the policy namesmastertour.readanddaysheets.read.
Install: curl -fsSL https://raw.githubusercontent.com/manuaudio/macos-cli/main/install.sh | bash or brew install manuaudio/tap/macos-cli.
macos-cli-0.10.0-arm64.zip holds the macos binary for Apple silicon, signed with Developer ID (team 4M72M3J3UN) and notarized by Apple. A bare executable cannot carry a stapled ticket; the notarization id is in the manifest. sha256: 0132296261b67aa93901bde9c88a81fd6b12bd9e19f11a326fc90a828c56a63b.
macos-cli 0.9.1
Added
macos commands --json. Every command with its flags, one line of help and whether it writes;SKILL.mdis generated from it (bash scripts/gen-skill.sh).
Fixed
- The signing manifest on a Release no longer calls itself a staging artifact. Its note now points at the
installed,notarizedandstapledfields, which say what was done to the binary.
Install: curl -fsSL https://raw.githubusercontent.com/manuaudio/macos-cli/main/install.sh | bash or brew install manuaudio/tap/macos-cli.
macos-cli-0.9.1-arm64.zip holds the macos binary for Apple silicon, signed with Developer ID (team 4M72M3J3UN) and notarized by Apple. A bare executable cannot carry a stapled ticket; the notarization id is in the manifest. sha256: 21441774842bde2556eb05ddc51c36e9d99425e3719c302c47d73ffc2615e0fe.
macos-cli 0.9.0
An agent can find out what it may do, and cannot widen it; calendars by id; faster Mail, Contacts and Reminders.
Added
- A signed, notarized Release, installed with one line.
curl -fsSL https://raw.githubusercontent.com/manuaudio/macos-cli/main/install.sh | bashdownloads the Release binary and checks its sha256, Developer ID signature, team and version before installing it; no Xcode needed. A source build isMACOS_CLI_SIGN_MODE=adhoc ./install.sh. macos update [--check]. Replaces the binary with the newest Release at the same path, after the same checks, so the permissions macOS granted it stay with it.- Homebrew:
brew install manuaudio/tap/macos-cli. macos doctor [--for-agent | --json]. Every macOS privacy area this binary may need, its state and the fix, plus the binary's identity, the session and the resolvedauth.jsonpolicy. It never prompts.macos authorize <area>. Asks macOS for one area (bounded by--timeout), or opens its settings pane.--calendar-idoncalendar events,export,create,updateanddelete.calendar calendars --jsonaddskind,source,writableandcolor.calendar update --alarm/--clear-alarms,--timezoneon events, export, create and update,calendar export --since, and--start/--endaccepted for--from/--to.contacts export --since TOKENwith thehistory_tokenevery export now carries.mail read --id MESSAGE_ID, and--mailbox/--accountonmail searchandmail read; results carrymessage_id,accountanddate_sent.
Changed
- Not found is exit 3, not a usage error. A missing directory (
file list,finder), a PDF page, a Space, an accessibility hint or an audio device that does not exist now fails withnot_found(exit 3); a file that is not UTF-8 text withapp_error(exit 6). They used to exit 64 with usage text. - Widening the policy needs a person.
auth grant,auth resetandauth setupask for a typed confirmation on the terminal; without one they refuse withperson_required(exit 4).auth setup --yesis gone. - No unanswerable prompts. Calendars, Reminders and Contacts are requested only when a person is at a terminal; elsewhere an undecided permission fails at once with
state: not_determinedinstead of a 15 s timeout. The Contacts request is bounded. - A write by a shared calendar name is refused (
ambiguous_calendar, exit 64) with every matching id; it used to go to the first calendar of that name. setupexits 4 when something is missing and never reads stdin without a terminal.- Mail search asks Mail one query per mailbox instead of three or four Apple events per message.
contacts exportreturns contacts in the store's order (no sort), which was most of its time.- Reminders
update,deleteanduncompletelook the reminder up by id instead of fetching every reminder.
Fixed
- Notes without Full Disk Access reported
count: 0; Notes reads now fail withaccess_denied,area: full_disk_access.
One error contract for every command, and --json where the README promised it
Fixed
--jsonon the four exports.calendar export,contacts export,notes exportandreminders exportalways printed JSON but refused the flag withUnknown option '--json'(exit 64). They accept it now.- Notes bodies.
notes exportread some valid bodies as missing: a heuristic rejected text that was mostly digits or punctuation. The decoder now follows the note's own protobuf path (document → note → text), validates every enclosing message and the gzip checksum, and returns the text verbatim. A password-protected note is refused explicitly, and missing data is an error, distinct from an empty body. - README examples.
contacts updatetakes the contact id as an argument, not--id; the README now says so, and thesystem battery --jsonsample shows the real keys. - Unknown calendar.
calendar events --calendar NAME(anddelete,update,create) with a name that does not exist printed the root usage text; it now says which calendar is missing and exits 3.
Changed
- Errors. Under
--json, and always for the exports, a failure is one JSON object on stdout with stderr empty:ok: false,status: "error", a stable code inerror, amessage, often ahint, and theexit_code. Without--jsona failure is oneError:line and aHint:line on stderr, without the usage text. - Exit codes. 64 usage (including a rejected value such as a bad date), 3 not found, 4 permission, 5 timeout, 6 app error. The JSON errors that 0.8 emitted with exit 1 keep their codes and keys and exit with the status from this table:
invalid_date,invalid_date_range,invalid_alarmandinvalid_delete_modeexit 64,event_not_found3,access_denied4,fetch_timeout5. - Permission failures are told apart. A capability turned off in
auth.jsoniscapability_denied; macOS privacy settings refusing access isaccess_denied; a permission request nobody answered istimeout. 0.8 reported all three asaccess_denied. auth.jsonfollowsHOME. The policy file is$HOME/.config/macos-cli/auth.json, so a test or a sandboxed agent can point it at its own file.script run --jsonreturns{"output", "stderr"}.- The version string lives in one place,
Sources/macos-cli/Version.swift; the installer and its tests read it from there. make testchecks the README.scripts/tests/readme_examples_test.shfails when a README example names a command or option the binary lacks, and runs the read-only examples that need no permission.
Removed
- The GitHub Actions workflow and Dependabot configuration. Checks run locally:
make test.
Install: curl -fsSL https://raw.githubusercontent.com/manuaudio/macos-cli/main/install.sh | bash or brew install manuaudio/tap/macos-cli.
macos-cli-0.9.0-arm64.zip holds the macos binary for Apple silicon, signed with Developer ID (team 4M72M3J3UN) and notarized by Apple. A bare executable cannot carry a stapled ticket; the notarization id is in the manifest. sha256: 5b0485d31c3b5b4a8145872d31ac6e5398d603c1f92bf6b7b8b8bb6e25d41edb.