ex-mode/lib/vim-option.coffee
jazzpi 91f3f82730 New command defining format, minor improvements
- If the second address is empty, it is assumed to be `.`
- Regex addresses and `:substitute` now integrate with search history and
  respect case sensitivity settings
- Patterns for `:substitute` can't be delimited by
- `:set` now supports inverting options using `:set inv{option}` and
  `:set {option}!`
- New commands: `:new`, `:vnew`, `:exit`, `:xall`, `:wall`, `:qall`, `:update`
2015-07-31 12:01:47 +02:00

19 lines
459 B
CoffeeScript

class VimOption
@options =
'list': 'editor.showInvisibles'
'nu': 'editor.showLineNumbers'
'number': 'editor.showLineNumbers'
@registerOption: (vimName, atomName) ->
@options[vimName] = atomName
@set: (name, value) ->
atom.config.set(@options[name], value)
@get: (name) ->
atom.config.get(@options[name])
@inv: (name) ->
atom.config.set(@options[name], not atom.config.get(@options[name]))
module.exports = VimOption