Skip to content

Instantly share code, notes, and snippets.

@hage
Last active March 8, 2016 10:19
Show Gist options
  • Save hage/224979dd03e7e7e6a0b5 to your computer and use it in GitHub Desktop.
Save hage/224979dd03e7e7e6a0b5 to your computer and use it in GitHub Desktop.
Emacs で `|>` を楽に入力する ref: http://qiita.com/__hage/items/a8a99b996fd266ccbcf5
(eval-after-load "elixir-mode"
#'(progn
;; 改行して行頭に |> をつける
(defun my-elixir-newline-and-insert-pipe ()
(interactive)
(move-end-of-line 1)
(newline-and-indent)
(insert "|> "))
(define-key elixir-mode-map (kbd "M-J") 'my-elixir-newline-and-insert-pipe)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment