Clone wiki

frawor / Frawor redesign

  1. Purge out “twoload” feature. It is already possible to automatically load dependencies from any location, so just use some interface plugins:
    1. instead of 'Mapname': {'lhs': dictionary} in mappings do something like 'Mapname': {'lhsplid': plid} and s:_mappings.Mapname inside plugin described by plid. Same for commands, autocommands and external functions.
    2. as we no longer use dictionaries inside mappings/… as a wrapfunc arguments, also purge out wrapfunc itself; decorators should be left: they can be python-like decorators that use let func=decorator(func[, decargs]) syntax. No need to optimize the speed of decorators as almost every time only FWC decorator is used and there is only one other decorator.
  2. All ignoredeps features should be located inside @/ignoredeps and be loaded from @frawor using runtime! plugin/frawor/ignoredeps/**/*.vim.
  3. Replace execute frawor#Setup() with execute frawor#Setup, put version and dependencies into s:_version and s:_dependencies variables.
  4. More ftplugin features with different API:
    1. Set/unset options from _ftoptions.
    2. Map/unmap mappings from _ftmappings. Don’t enforce 'buffer': 1 anymore
    3. Create/delete commands from _ftcommands.
  5. Remove dictionaries support from commands, autocommands and mappings. They are not needed anymore after twoload will be purged.

Non-redesign related tasks:

  1. Purge out frawor#Reload(), put it as a command into macros/frawor/reload.vim. Add ReloadRTP command.
  2. Add bufvars plugin. API: bv.setup(bufnewcallback, bwcallback), bv.get([bufnr]), bv.delete([bufnr]). Make it “compile” on changes, run compiled function on events.
  3. Also compile mappings.
  4. Make it possible to call functions provided as a funcref using :call: feature appears to be too needed not to add it to frawor.
  5. Purge out a bunch of add_varname, use one ignoredeps feature that adds variables instead.