Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Ukelele's developer (John Brownie) on the website:

Second, if you have a keyboard layout that is active, modify it (in Ukelele or any other way), save it, then log out and log in again, the system will not load the new version. You need to modify the folder that contains the keyboard layout to get the system to recognise the change. The easiest way is to drag the keyboard layout file to the desktop and then back to the Keyboard Layouts folder, then log out and log in again. Restarting will always load the newest version of a keyboard layout.

Any more sane method?

So it seems that most likely no. Here's a way to partially automate it with Applescript though:

do shell script "touch '/Library/Keyboard Layouts/'"
tell application "System Events"
        tell process "Ukelele"
            click menu bar 1's menu bar item "File"'s menu 1's menu item "Save"
        end tell
    end try
    log out
end tell
share|improve this question
If it's helpful: to try a keyboard while developing, I added a new file to the folder with a different filename and keyboard name, and added it in settings. That way you can at least try your keyboard without log in-out. – jonallard Jan 17 '15 at 2:54
up vote 0 down vote accepted

Sorry, but there's not much better than can be done. Keyboard layouts are only scanned at login, and if you don't restart, then the system optimises the process by only scanning folders that have changed since the last login, by checking the modification date of the folder.

About the only other way I can think of to automate that is to have a script that changes the modification date of the relevant folder - a shell script calling 'touch' would work (see below). Then you could have a simpler way of making the change (rather than dragging files out and in), but you would still have to log out and log in. I don't know of a shortcut to logging out, apart from hitting option-shift-command-Q. I have not seen a way to script it.

Script to change the modification date of the Keyboard Layouts folder in the Library folder:

touch /Library/Keyboard\ Layouts
share|improve this answer
Thanks, that's what I was expecting to hear actually. One way to log out is tell app "System Events" to log out. – user495470 Apr 9 '11 at 11:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .