Script Editor Icon

Saving a script as a text file

You can save a script as a text file that can be edited in any text editor. The text file can then be opened in Script Editor and compiled.

To save a script as a text file:

Step 1

Choose File > Save.

Step 2

Choose a location to save your file.

Step 3

In the Save dialog, choose text from the File Format pop-up menu.

Step 4

Enter a name for the script (.applescript is the filename extension).

Step 5

Choose one of the following line-ending options from the Line Endings pop-up menu:

UNIX (LF): A line feed character (ASCII character 10) is used to mark line endings.

WINDOWS (CRLF): Both a carriage return character and a line feed character are used to mark line endings.

MAC (CR): A carriage return character (ASCII character 13) is used to mark line endings.

Preserve Line Endings: Choosing this option saves the file with its existing line endings.

Step 6

Click Save.

Related Topics

saving scripts