neovim/runtime/plugin
Justin M. Keyes 673d2b52fa refactor!: rename vim.pretty_print => vim.print
Problem:
The function name `vim.pretty_print`:
1. is verbose, which partially defeats its purpose as sugar
2. does not draw from existing precedent or any sort of convention
   (except external projects like penlight or python?), which reduces
   discoverability, and degrades signaling about best practices.

Solution:
- Rename to `vim.print`.
- Change the behavior so that
  1. strings are printed without quotes
  2. each arg is printed on its own line
  3. tables are indented with 2 instead of 4 spaces
- Example:
  :lua ='a', 'b', 42, {a=3}
  a
  b
  42
  {
    a = 3
  }

Comparison of alternatives:
- `vim.print`:
  - pro: consistent with Lua's `print()`
  - pro: aligns with potential `nvim_print` API function which will
    replace nvim_echo, nvim_notify, etc.
  - con: behaves differently than Lua's `print()`, slightly misleading?
- `vim.echo`:
  - pro: `:echo` has similar "pretty print" behavior.
  - con: inconsistent with Lua idioms.
- `vim.p`:
  - pro: very short, fits with `vim.o`, etc.
  - con: not as discoverable as "echo"
  - con: less opportunity for `local p = vim.p` because of potential shadowing.
2023-03-13 01:25:09 +01:00
..
editorconfig.lua refactor(editorconfig)!: change editorconfig_enable to editorconfig 2023-01-07 08:19:37 -07:00
gzip.vim vim-patch:47e13953ffdb 2021-04-28 21:29:57 -04:00
health.vim
man.lua feat(Man): port to Lua (#19912) 2022-09-02 15:20:29 +01:00
matchit.vim Add g:loaded_matchit check (#13226) 2020-11-04 18:46:03 -05:00
matchparen.vim vim-patch:partial:dd60c365cd26 (#22437) 2023-02-28 09:34:27 +01:00
netrwPlugin.vim vim-patch:89a9c159f23f #15641 2021-09-13 06:05:27 -07:00
nvim.lua refactor!: rename vim.pretty_print => vim.print 2023-03-13 01:25:09 +01:00
rplugin.vim fix(startup): nvim with --clean should not load user rplugins 2022-06-04 18:37:54 +02:00
shada.vim
spellfile.vim
tarPlugin.vim runtime/tar: 23515b4ef7580af8b9d3b964a558ab2007cacda5 2021-02-17 23:59:17 -05:00
tohtml.vim vim-patch:be4e01637e71 (#22103) 2023-02-03 09:18:18 +01:00
tutor.vim
zipPlugin.vim vim-patch:519cc559b08b (#16340) 2021-11-17 10:02:59 +01:00