Changes between Version 1 and Version 2 of EmacsSnippetSupport
- Timestamp:
- 11/23/08 22:38:05 (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
EmacsSnippetSupport
v1 v2 1 1 = Using Bcfg2 with Emacs + YASnippet mode = 2 2 3 This page describes using emacs with YASnippet mode with a set of snippets that allow quick composition of bundles . More snippets are under development.3 This page describes using emacs with YASnippet mode with a set of snippets that allow quick composition of bundles and base files. More snippets are under development. 4 4 5 5 1. Download YASnippet from http://code.google.com/p/yasnippet/ … … 8 8 {{{ 9 9 (require 'yasnippet-bundle) 10 11 ;;; Bcfg2 snippet 12 10 13 (yas/define-snippets 'sgml-mode 11 14 '( … … 13 16 $0 14 17 </Bundle>" nil) 18 ("<Base" "<Base> 19 $0 20 </Base>" nil) 15 21 ("<Group" "<Group name='${1:groupname}> 16 22 $0 … … 32 38 ) 33 39 ) 40 34 41 }}} 35 42 1. One quick M-x eval-current-buffer, and this code is enabled … … 37 44 Each of these snippets activates on the opening element, ie <Bundle. After this string is entered, but before entering a space, press <TAB>, and the snippet will be expanded. The template will be inserted into the text with a set of input prompts, which default to overwrite mode and can be tabbed through. 38 45 39 The code above only works for bundles , but will be expanded to support base andother xml files as well.46 The code above only works for bundles and base, but will be expanded to support other xml files as well.