Skip to content

Commit e928aaf

Browse files
authored
Merge pull request #398 from ckhrysze/master
Update README.md section on auto pairing options
2 parents 8617881 + 9eef047 commit e928aaf

File tree

1 file changed

+6
-20
lines changed

1 file changed

+6
-20
lines changed

README.md

Lines changed: 6 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -126,10 +126,11 @@ functionality easily.
126126

127127
Keymaps can be added to the `elixir-mode-map` variable.
128128

129-
## Notes
129+
### Pairing
130130

131-
If you want to use `ruby-end-mode` for a more comfortable editing
132-
experience, you can add the following to your `elixir-mode-hook`:
131+
[Smartparens](https://github.com/Fuco1/smartparens) has direct support for Elixir.
132+
133+
Alternatively, if you want to use `ruby-end-mode`, you can add the following to your `elixir-mode-hook`:
133134

134135
```lisp
135136
(add-to-list 'elixir-mode-hook
@@ -140,21 +141,6 @@ experience, you can add the following to your `elixir-mode-hook`:
140141
(ruby-end-mode +1)))
141142
```
142143

143-
Also, if you use [smartparens](https://github.com/Fuco1/smartparens) you can
144-
piggyback on some of its functionality for dealing with Ruby's `do .. end`
145-
blocks. A sample configuration would be:
146-
147-
```lisp
148-
(sp-with-modes '(elixir-mode)
149-
(sp-local-pair "fn" "end"
150-
:when '(("SPC" "RET"))
151-
:actions '(insert navigate))
152-
(sp-local-pair "do" "end"
153-
:when '(("SPC" "RET"))
154-
:post-handlers '(sp-ruby-def-post-handler)
155-
:actions '(insert navigate)))
156-
```
157-
158144
## Elixir Tooling Integration
159145

160146
If you looking for elixir tooling integration for Emacs, check: [alchemist.el](https://github.com/tonini/alchemist.el)
@@ -172,8 +158,8 @@ Please read [CONTRIBUTING.md](https://github.com/elixir-lang/emacs-elixir/blob/m
172158

173159
## License
174160

175-
Copyright © 2011-2015 Samuel Tonini, Matt DeBoard, Andreas Fuchs, secondplanet and
176-
[contributors](https://github.com/tonini/alchemist.el/contributors).
161+
Copyright © 2011-2017 Samuel Tonini, Matt DeBoard, Andreas Fuchs, secondplanet and
162+
[contributors](https://github.com/elixir-lang/emacs-elixir/contributors).
177163

178164
Distributed under the GNU General Public License, version 3
179165

0 commit comments

Comments
 (0)