Add Elixir with clause snippets

This is an addition to Elixir's syntax as of version 1.2.0 which wasn't
yet included in the current snippet list.
This commit is contained in:
Auralcat 2020-03-13 16:42:37 -03:00
parent d39c424fa8
commit 2838cdf272
2 changed files with 18 additions and 0 deletions

8
snippets/elixir-mode/wt Normal file
View File

@ -0,0 +1,8 @@
# -*- mode: snippet -*-
# contributor: Miriam Retka (https://github.com/Auralcat)
# name: wt
# key: wt
# --
with ${1:{:ok, tuple} <- function(arg)}, do
$0
end

10
snippets/elixir-mode/wte Normal file
View File

@ -0,0 +1,10 @@
# -*- mode: snippet -*-
# contributor: Miriam Retka (https://github.com/Auralcat)
# name: wte
# key: wte
# --
with ${1:{:ok, tuple} <- function(arg)}, do
$2
else
$0
end