Customize Script menu in CotEditor

You can change the order of sripts in the menu or assign keyboard shortcuts to scripts by modifying the filenames of your scripts in the script folder.

Order of items in the menu

By adding “number + closing parenthesis ())” at the head of the name, you can line up the files in numeric order. The part “number + )” won’t be shown in the menu.

Example
FilenameDisplay in the menu
01)Open File.scpt Open File

Separators

A folder named “-” appears as a separator line in the menu. By adding “number + closing parenthesis ())” at the head of the folder name, you can put a separator between the menu items.

Hidden files/folders

A file/folder whose name begins with the underscore “_” will not be lined up in the script menu. You can use it for setting files, library scripts, and so on.

Submenus

Scripts placed in a folder in the scripts folder will appear as submenus.

Keyboard shortcuts

By adding “dot (.) + modifier key + shortcut key” in front of the extension, you can assign a keyboard shortcut to the script.

Modifier key notations
NotationEquivalent key
^Control
$Shift
~Option
@Command
Examples
FilenameDisplay in the menuSortcut
Insert String.@e.scpt Insert String Command-E
03)Insert Date.@~Y.scpt Insert Date Option-Shift-Command-Y

See also