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.
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.
| Filename | Display in the menu |
|---|---|
| 01)Open File.scpt | Open File |
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.
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.
Scripts placed in a folder in the scripts folder will appear as submenus.
By adding “dot (.) + modifier key + shortcut key” in front of the extension, you can assign a keyboard shortcut to the script.
| Notation | Equivalent key |
|---|---|
| ^ | Control |
| $ | Shift |
| ~ | Option |
| @ | Command |
| Filename | Display in the menu | Shortcut |
|---|---|---|
| Insert String.@e.scpt | Insert String | Command-E |
| 03)Insert Date.@~Y.scpt | Insert Date | Option-Shift-Command-Y |
CotEditor changes keyboard shortcut mapping dinamically to prioritize the scripts in the subfolder whose name is the same as the frontmost document's syntax style when the same keyboard shortcut is determined in multiple CotEditor scripts.