diff options
author | Alexander Sulfrian <alexander@sulfrian.net> | 2012-04-24 23:29:38 +0200 |
---|---|---|
committer | Alexander Sulfrian <alexander@sulfrian.net> | 2012-04-24 23:29:38 +0200 |
commit | 7a6bb0f05e349068b0a89514f1da33d6d7de30a9 (patch) | |
tree | c202b81dfaf524e71e881c15aa509c45445a64b3 /emacs.d/lisp/yasnippet/snippets/erlang-mode | |
parent | 66b95ab46d870f41c12c489eb21c9c82846d6112 (diff) | |
download | dotfiles-7a6bb0f05e349068b0a89514f1da33d6d7de30a9.tar.gz dotfiles-7a6bb0f05e349068b0a89514f1da33d6d7de30a9.tar.xz dotfiles-7a6bb0f05e349068b0a89514f1da33d6d7de30a9.zip |
emacs.d/lisp/yasnippet: added yasnippet
Diffstat (limited to 'emacs.d/lisp/yasnippet/snippets/erlang-mode')
22 files changed, 104 insertions, 0 deletions
diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/.yas-parents b/emacs.d/lisp/yasnippet/snippets/erlang-mode/.yas-parents new file mode 100644 index 0000000..eed5b44 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/.yas-parents @@ -0,0 +1 @@ +text-mode diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/after b/emacs.d/lisp/yasnippet/snippets/erlang-mode/after new file mode 100644 index 0000000..264e201 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/after @@ -0,0 +1,4 @@ +#name : after ... -> +# -- +after + $1 -> $0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/begin b/emacs.d/lisp/yasnippet/snippets/erlang-mode/begin new file mode 100644 index 0000000..7b48494 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/begin @@ -0,0 +1,5 @@ +#name : begin ... end +# -- +begin + $0 +end diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/beh b/emacs.d/lisp/yasnippet/snippets/erlang-mode/beh new file mode 100644 index 0000000..4975b26 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/beh @@ -0,0 +1,4 @@ +#name : -behaviour(...). +# -- +-behaviour(${1:gen_server}). +$0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/case b/emacs.d/lisp/yasnippet/snippets/erlang-mode/case new file mode 100644 index 0000000..5bed114 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/case @@ -0,0 +1,5 @@ +#name : case ... of ... end +# -- +case $1 of + $0 +end diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/compile b/emacs.d/lisp/yasnippet/snippets/erlang-mode/compile new file mode 100644 index 0000000..ae3a4d8 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/compile @@ -0,0 +1,4 @@ +#name : -compile(...). +# -- +-compile([${1:export_all}]). +$0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/def b/emacs.d/lisp/yasnippet/snippets/erlang-mode/def new file mode 100644 index 0000000..6fb92f1 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/def @@ -0,0 +1,4 @@ +#name : -define(...,...). +# -- +-define($1,$2). +$0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/exp b/emacs.d/lisp/yasnippet/snippets/erlang-mode/exp new file mode 100644 index 0000000..67f56da --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/exp @@ -0,0 +1,5 @@ +#name : -export([]). +#contributor : hitesh <hitesh.jasani@gmail.com> +# -- +-export([${1:start/0}]). +$0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/fun b/emacs.d/lisp/yasnippet/snippets/erlang-mode/fun new file mode 100644 index 0000000..77f8293 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/fun @@ -0,0 +1,3 @@ +#name : fun (...) -> ... end +# -- +fun ($1) -> $0 end diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/if b/emacs.d/lisp/yasnippet/snippets/erlang-mode/if new file mode 100644 index 0000000..45674c4 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/if @@ -0,0 +1,6 @@ +#name : if ... -> ... ; true -> ... end +# -- +if + $1 -> $2; + true -> $0 +end diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/ifdef b/emacs.d/lisp/yasnippet/snippets/erlang-mode/ifdef new file mode 100644 index 0000000..ea89ecf --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/ifdef @@ -0,0 +1,5 @@ +#name : -ifdef(...). ... -endif. +# -- +-ifdef($1). +$0 +-endif. diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/ifndef b/emacs.d/lisp/yasnippet/snippets/erlang-mode/ifndef new file mode 100644 index 0000000..dcd67a7 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/ifndef @@ -0,0 +1,5 @@ +#name : -ifndef(...). ... -endif. +# -- +-ifndef($1). +$0 +-endif. diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/imp b/emacs.d/lisp/yasnippet/snippets/erlang-mode/imp new file mode 100644 index 0000000..c035ddd --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/imp @@ -0,0 +1,5 @@ +#name : -import([]). +#contributor : hitesh <hitesh.jasani@gmail.com> +# -- +-import(${1:lists}, [${2:map/2, sum/1}]). +$0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/inc b/emacs.d/lisp/yasnippet/snippets/erlang-mode/inc new file mode 100644 index 0000000..f7b2161 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/inc @@ -0,0 +1,4 @@ +#name : -include("..."). +# -- +-include("$1"). +$0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/inc.lib b/emacs.d/lisp/yasnippet/snippets/erlang-mode/inc.lib new file mode 100644 index 0000000..09a6723 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/inc.lib @@ -0,0 +1,4 @@ +#name : -include_lib("..."). +# -- +-include_lib("$1"). +$0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/loop b/emacs.d/lisp/yasnippet/snippets/erlang-mode/loop new file mode 100644 index 0000000..0205802 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/loop @@ -0,0 +1,8 @@ +#name : loop(...) -> receive _ -> loop(...) end. +# -- +${1:loop}($2) -> + receive + ${3:_} -> + $1($2) + end. +$0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/mod b/emacs.d/lisp/yasnippet/snippets/erlang-mode/mod new file mode 100644 index 0000000..7275d39 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/mod @@ -0,0 +1,6 @@ +#name : -module(). +#contributor : hitesh <hitesh.jasani@gmail.com> +# -- +-module(${1:`(file-name-nondirectory + (file-name-sans-extension (or (buffer-file-name) (buffer-name))))`}). +$0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/rcv b/emacs.d/lisp/yasnippet/snippets/erlang-mode/rcv new file mode 100644 index 0000000..804fb3f --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/rcv @@ -0,0 +1,5 @@ +#name : receive ... -> ... end +# -- +receive + $1 -> $0 +end diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/rcv.after b/emacs.d/lisp/yasnippet/snippets/erlang-mode/rcv.after new file mode 100644 index 0000000..51046df --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/rcv.after @@ -0,0 +1,6 @@ +#name : receive after ... -> ... end +# -- +receive +after + $1 -> $0 +end diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/rec b/emacs.d/lisp/yasnippet/snippets/erlang-mode/rec new file mode 100644 index 0000000..0d67834 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/rec @@ -0,0 +1,4 @@ +#name : -record(...,{...}). +# -- +-record($1,{$2}). +$0 diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/try b/emacs.d/lisp/yasnippet/snippets/erlang-mode/try new file mode 100644 index 0000000..fa5c9c2 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/try @@ -0,0 +1,7 @@ +#name : try ... of ... catch after end +# -- +try $1 of + $0 +catch +after +end diff --git a/emacs.d/lisp/yasnippet/snippets/erlang-mode/undef b/emacs.d/lisp/yasnippet/snippets/erlang-mode/undef new file mode 100644 index 0000000..7ab5dd4 --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/erlang-mode/undef @@ -0,0 +1,4 @@ +#name : -undef(...). +# -- +-undef($1). +$0 |