---
title: TextExpander tools for AppleScript editing
date: 2012-02-19 12:21
slug: textexpander-tools-for-applescript-editing
categories:
- Code
tags:
- textexpander
- scripting
- snippet
- tools
---

[tools]: http://brettterpstra.com/project/textexpander-tools/
[te-as]: http://brettterpstra.com/share/te-snippets/index.php?group=AppleScript%20Editor&prefix=

I added a new group to the [TextExpander Tools][tools] collection this morning: a set of snippets for working in AppleScript editor. The group is pretty barebones right now, but handy nonetheless. Feel free to submit any additions or expansions you come up with, I'll gladly include them in the set (and credit you publicly).

I was actually working on a more complex set of snippets involving some AppleScripting when I decided to build a few of these. I'll try to post the results of that later today.

The snippets cover basic syntax for `if`, `tell`, `repeat` and setting variables and properties. For `if` and `tell`, following the trigger ("if" or "tell") with a space will create a one-liner and reposition your cursor, following immediately with minus symbol (`-`) will create a block with an end block and put your cursor back in position for continuing the statement. `s=` and `p=` will use the Fill dialog to create `set` statements and `property` declarations, respectively.

You can pick up the group using the [te-snippets tool][te-as], which will allow you to download directly or give you a url you can subscribe to in TextExpander to automatically get updates as the group grows.

**Addendum:** If it doesn't come through in the `.textexpander` file, I should mention that I have the group set up in TextExpander to expand "Only in..." AppleScript Editor. Just select the group in the TextExpander window and set "Expand in:" as needed.

---

Brett is a writer and developer living in Minnesota, USA. You can follow him as ttscoff. This content is supported by readers like you. [More about Brett](https://brettterpstra.com/contact.md), including social links.

Copyright © 2026 Brett Terpstra. All rights reserved.
