Skip to content

Releases: HelgeSverre/zed-applescript

v1.9.1

Choose a tag to compare

@github-actions github-actions released this 27 May 02:01

Packaging-only release for Zed extension marketplace publishing. No grammar, query, or behavior changes.

Changed

  • Renamed LICENSE.md → LICENSE to satisfy the Zed marketplace license-file requirement (Oct 2025).
  • README license badge link updated to point at the new filename.

v1.9.0

Choose a tag to compare

@github-actions github-actions released this 20 May 16:54

Tier 1 grammar improvements — 5 small lenient parsing additions sourced from a three-agent stress-file analysis. 22 errors closed across the quarantined stress targets.

Added (grammar)

  1. Bare # line comments alongside the existing -- and #! forms. Common in shebang scripts and modern AppleScript style.
  2. Leading-dot floats (.5, -.25) — a number-literal form common in window-manager scripts that compute screen fractions.
  3. Multi-word record key values — {repetition method: start after completion}. Lenient editor parsing: not valid generic AppleScript per osacompile, only valid when the target app's dictionary defines those words as enumeration constants. AppleScript code that uses OmniFocus / Mail / Calendar / Contacts dictionaries does this routinely.
  4. |piped|() no-arg handler calls — supports ASObjC method-call syntax where the selector is a piped identifier.

Changed

  • Time-unit names (seconds, minutes, hours, days, weeks) removed from applescript_constant. They now parse as plain identifiers outside with timeout (which has its own dedicated seconds token). Lets set hours of theDate to 12 and similar property-reference patterns parse correctly.
  • Grammar pin bumped to 7a5dce5.

Stress-corpus impact

File Before After Δ
omnifocus_library.applescript 29 19 −10
battery_monitor.applescript 12 6 −6
layouts.applescript 7 1 −6
alfred_iterm.applescript 10 10 0 (Tier 2: chained tells)
adium_unittest.applescript 11 11 0 (single-app dictionary, intentionally skipped)

Layouts is one error short of graduating to the active corpus; the remaining error (tell application theApp — a variable reference instead of a string literal) is on the Tier 2 list as part of broadening tell_simple_statement.target to $._expression.

Verified valid AppleScript

The just validate-corpus recipe (added in 6117e9c) confirms all 4 of the additions above target real-AppleScript constructs that osacompile accepts. Fix #3 (multi-word record values) is the one intentional lenient-mode case — the comment in grammar.js explains why.

v1.8.5

Choose a tag to compare

@github-actions github-actions released this 20 May 06:18

Corpus expansion — 9 community-sourced scripts.

Added

  • Active corpus → 40 files (was 36). Four community scripts that already parse cleanly:

    • community/dmg_finder.applescript from indygreg/PyOxidizer — Finder DMG window-styling pattern.
    • community/NV-CopyToNV.applescript, community/NV-LinkAutomation.applescript, community/NV-NewNoteFromDialog.applescript from unforswearing/applescript — Notational Velocity automation snippets.
  • Stress targets in known-limits/community-stress/ — 5 substantial files (1,155 LOC total, 69 ERROR nodes) that exercise gaps not yet covered:

    • omnifocus_library.applescript (579 LOC, 29 err) — multi-word record keys, deep ASObjC patterns.
    • battery_monitor.applescript (228, 12) — long mixed-pattern app.
    • layouts.applescript (148, 7) — chained tells, window management.
    • adium_unittest.applescript (106, 11) — Adium app-dictionary specifics.
    • alfred_iterm.applescript (94, 10) — tell X to tell Y to tell Z to <action> chains.

    Each is documented in known-limits/README.md with its primary failure mode, so future grammar work can pick the highest-leverage target.

Changed

  • Grammar pin bumped to b523b13. No parser change — corpus addition only.

v1.8.4

Choose a tag to compare

@github-actions github-actions released this 20 May 05:57

Polish pass — four small additions, no behavior changes for end users.

Added

  • CI on the grammar repo at HelgeSverre/tree-sitter-applescript. Runs the fixture suite + a real-world corpus scan on every push and PR to grammar main. Catches regressions before they leave the grammar repo, so a broken grammar can't silently slip in via the next just update-grammar here.
  • just status recipe — prints version, grammar pin, last tag, and whether the submodule SHA matches the pin (with a ⚠ if it doesn't). Useful when context-switching back to the repo.
  • README badges for CI status, latest version, and license.

Changed

  • README's Documentation section now lists only user-facing material (CHANGELOG, the references cache). Moved CLAUDE.md into a new Contributing section since it's a repo-internal contract for AI agents, not user-facing documentation.
  • Grammar pin bumped to 0083acc to pick up the new CI workflow on the grammar side. No parser change.

v1.8.3

Choose a tag to compare

@github-actions github-actions released this 20 May 05:12

Eight findings from a five-lens swarm review applied as a single batch.

Fixed

  • $ZED_SYMBOL no longer flows into a bash -c string in the "Run handler" task. It's now passed as an environment variable (HANDLER) and read as a normal shell variable, eliminating the textual-injection risk a maliciously named handler could otherwise exploit. (Security audit.)
  • mktemp leak in the handler task closed. The previous one-liner appended .applescript to $(mktemp …), leaving the original temp file un-deleted on every run. Now uses mktemp + mv + trap … EXIT for guaranteed cleanup. (Code review.)
  • runnables.scm handler-name capture renamed @_name → @name so Zed actually populates $ZED_SYMBOL in the task label. The leading-underscore convention marks a capture as internal/unused, which on some Zed builds suppressed the substitution silently. (Code review.)
  • just test no longer truncates its output with | tail -3. CI failures now show which fixture broke and the diff, not just the summary count. (Code review.)
  • just release uses explicit git add paths (extension.toml, grammars/tree-sitter-applescript, CHANGELOG.md) instead of git add -A, so a release commit can't sweep in stray local files. (Security audit.)
  • tree-sitter-cli@0.22 pinned in CI (ci.yml + release.yml). The previous unpinned npm install -g tree-sitter-cli would have broken silently on a major-version bump. (Maintenance forecast.)

Added

  • Comment language injection (injections.scm): both (comment) and (block_comment) now inject Zed's comment pseudo-language, activating built-in TODO/FIXME/NOTE/HACK gutter highlighting. (Comparative analysis vs Dart/Haskell/Lua.)
  • GitHub topics on the extension repo (zed-editor, zed-extension, osascript, automation, tree-sitter, macos, applescript, zed) and a clearer description that drops the misleading (WIP) prefix at v1.8.3. (Outside-skeptic review.)

v1.8.2

Choose a tag to compare

@github-actions github-actions released this 20 May 03:31

Added

  • Grammar repo README + LICENSE at HelgeSverre/tree-sitter-applescript. The grammar previously shipped without a README. Also set its GitHub topics (tree-sitter, tree-sitter-grammar, tree-sitter-parser, parser, applescript, osascript, macos, automation), updated the description, and set the homepage to point at this extension.
  • Grammar pin bumped to include the new README/LICENSE (no parser change).

Changed

  • CI workflow now runs just verify and just test instead of an ad-hoc inline parse, so the .scm-against-node-types check gates every push.
  • Release workflow runs just verify as a pre-publish gate.
  • Both workflows now use actions/checkout@v4 with submodules: recursive so the grammar is available without an extra clone step, and install just via extractions/setup-just@v2.
  • LICENSE.md copyright year bumped to 2026.

v1.0.0

Choose a tag to compare

@github-actions github-actions released this 31 Dec 19:52

Added

  • Initial release
  • Tree-sitter grammar for AppleScript (token-based for reliable highlighting)
  • Syntax highlighting for keywords, strings, numbers, operators
  • Support for .applescript and .scpt file extensions
  • Line comments (--) and block comments ((* *))
  • Case-insensitive keyword matching