Skip to content

Instantly share code, notes, and snippets.

@xorel
xorel / oned.aug
Last active February 19, 2020 16:08
Augeas lens for oned.conf
module Oned =
autoload xfm
(* primitives *)
let sep = del /[ \t]*=[ \t]*/ " = "
let eol = del /\n/ "\n"
let opt_space = del /[ \t]*/ ""
let opt_space_nl = del /[ \t\n]*/ "\n"
let comma = del /,/ ","
let left_br = del /\[/ "["
syntax on
filetype indent plugin on
au BufRead,BufNewFile *.pp setfiletype puppet
" Quote a word consisting of letters from iskeyword.
nnoremap <silent> qw :call Quote('"')<CR>
nnoremap <silent> qs :call Quote("'")<CR>
nnoremap <silent> wq :call UnQuote()<CR>
function! Quote(quote)
normal mz
### Keybase proof
I hereby claim:
* I am xorel on github.
* I am janorel (https://keybase.io/janorel) on keybase.
* I have a public key ASCdhnzP6Yxu69oBegeRr8FXBT3a5giMSfAHwsu3rTOWygo
To claim this, I am signing this object: