Skip to content

Instantly share code, notes, and snippets.

Created June 9, 2009 04:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save anonymous/126269 to your computer and use it in GitHub Desktop.
Save anonymous/126269 to your computer and use it in GitHub Desktop.
(defun using-azerty? ()
(condition-case nil
(let ((buffer (get-buffer-create "*using-azerty?*"))
return)
(set-buffer buffer)
(erase-buffer)
(call-process-shell-command "setxkbmap" nil buffer nil "-print")
(goto-char (point-min))
(setq return (search-forward "azerty" nil t))
(kill-buffer buffer)
return)
(error (message "got a error in 'using-azerty?'") nil)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment