mirror of
				https://github.com/neovim/neovim.git
				synced 2025-10-26 12:27:24 +00:00 
			
		
		
		
	docs: rename builtin.txt, eval.txt #34212
Problem: Despite the name, `builtin.txt` only includes Vimscript functions, which is confusing, especially to people who only use Lua to configure Nvim Solution: From justinmk's suggestion - Rename `builtin.txt` to `vimfn.txt` - Rename `eval.txt` to `vimeval.txt` - The tags `*builtin.txt*` and `*eval.txt*` should be kept for Vim-patches Closes #33743
This commit is contained in:
		| @@ -273,7 +273,7 @@ If you need to modify or debug the documentation flow, these are the main files: | |||||||
|   runtime/lua/vim/*     =>  runtime/doc/lua.txt |   runtime/lua/vim/*     =>  runtime/doc/lua.txt | ||||||
|   runtime/lua/vim/lsp/  =>  runtime/doc/lsp.txt |   runtime/lua/vim/lsp/  =>  runtime/doc/lsp.txt | ||||||
|   src/nvim/api/*        =>  runtime/doc/api.txt |   src/nvim/api/*        =>  runtime/doc/api.txt | ||||||
|   src/nvim/eval.lua     =>  runtime/doc/builtin.txt |   src/nvim/eval.lua     =>  runtime/doc/vimfn.txt | ||||||
|   src/nvim/options.lua  =>  runtime/doc/options.txt |   src/nvim/options.lua  =>  runtime/doc/options.txt | ||||||
|   ``` |   ``` | ||||||
|  |  | ||||||
|   | |||||||
| @@ -1,10 +1,10 @@ | |||||||
| *eval.txt*	Nvim | *vimeval.txt*	Nvim | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| 		  VIM REFERENCE MANUAL	  by Bram Moolenaar | 		  VIM REFERENCE MANUAL	  by Bram Moolenaar | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| Expression evaluation		*vimscript* *expression* *expr* *E15* *eval* | Expression evaluation	*vimscript* *expression* *expr* *E15* *eval* *eval.txt* | ||||||
| 
 | 
 | ||||||
| Using expressions is introduced in chapter 41 of the user manual |usr_41.txt|. | Using expressions is introduced in chapter 41 of the user manual |usr_41.txt|. | ||||||
| 
 | 
 | ||||||
| @@ -1,10 +1,10 @@ | |||||||
| *builtin.txt*	Nvim | *vimfn.txt*	Nvim | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| 		  NVIM REFERENCE MANUAL | 		  NVIM REFERENCE MANUAL | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| Builtin functions		*vimscript-functions* *builtin-functions* | Vimscript functions	*vimscript-functions* *builtin-functions* *builtin.txt* | ||||||
| 
 | 
 | ||||||
| For functions grouped by what they are used for see |function-list|. | For functions grouped by what they are used for see |function-list|. | ||||||
| 
 | 
 | ||||||
| @@ -293,6 +293,10 @@ preprocess_patch() { | |||||||
|   LC_ALL=C sed -Ee 's/( [ab]\/src\/nvim)\/option\.h/\1\/option_vars.h/g' \ |   LC_ALL=C sed -Ee 's/( [ab]\/src\/nvim)\/option\.h/\1\/option_vars.h/g' \ | ||||||
|     "$file" > "$file".tmp && mv "$file".tmp "$file" |     "$file" > "$file".tmp && mv "$file".tmp "$file" | ||||||
|  |  | ||||||
|  |   # Rename runtime/doc/eval.txt to runtime/doc/vimeval.txt | ||||||
|  |   LC_ALL=C sed -Ee 's/( [ab]\/runtime\/doc)\/eval\.txt/\1\/vimeval.txt/g' \ | ||||||
|  |     "$file" > "$file".tmp && mv "$file".tmp "$file" | ||||||
|  |  | ||||||
|   # Rename version*.txt to news.txt |   # Rename version*.txt to news.txt | ||||||
|   LC_ALL=C sed -Ee 's/( [ab]\/runtime\/doc)\/version[0-9]+\.txt/\1\/news.txt/g' \ |   LC_ALL=C sed -Ee 's/( [ab]\/runtime\/doc)\/version[0-9]+\.txt/\1\/news.txt/g' \ | ||||||
|     "$file" > "$file".tmp && mv "$file".tmp "$file" |     "$file" > "$file".tmp && mv "$file".tmp "$file" | ||||||
|   | |||||||
| @@ -955,17 +955,17 @@ local CONFIG = { | |||||||
|     render = render_api_keyset_meta, |     render = render_api_keyset_meta, | ||||||
|   }, |   }, | ||||||
|   { |   { | ||||||
|     path = 'runtime/doc/builtin.txt', |     path = 'runtime/doc/vimfn.txt', | ||||||
|     funcs = get_eval_meta, |     funcs = get_eval_meta, | ||||||
|     render = render_eval_doc, |     render = render_eval_doc, | ||||||
|     header = { |     header = { | ||||||
|       '*builtin.txt*	Nvim', |       '*vimfn.txt*	Nvim', | ||||||
|       '', |       '', | ||||||
|       '', |       '', | ||||||
|       '\t\t  NVIM REFERENCE MANUAL', |       '\t\t  NVIM REFERENCE MANUAL', | ||||||
|       '', |       '', | ||||||
|       '', |       '', | ||||||
|       'Builtin functions\t\t*vimscript-functions* *builtin-functions*', |       'Vimscript functions\t*vimscript-functions* *builtin-functions* *builtin.txt*', | ||||||
|       '', |       '', | ||||||
|       'For functions grouped by what they are used for see |function-list|.', |       'For functions grouped by what they are used for see |function-list|.', | ||||||
|       '', |       '', | ||||||
|   | |||||||
| @@ -94,7 +94,7 @@ local redirects = { | |||||||
|  |  | ||||||
| -- TODO: These known invalid |links| require an update to the relevant docs. | -- TODO: These known invalid |links| require an update to the relevant docs. | ||||||
| local exclude_invalid = { | local exclude_invalid = { | ||||||
|   ["'string'"] = 'eval.txt', |   ["'string'"] = 'vimeval.txt', | ||||||
|   Query = 'treesitter.txt', |   Query = 'treesitter.txt', | ||||||
|   matchit = 'vim_diff.txt', |   matchit = 'vim_diff.txt', | ||||||
|   ['set!'] = 'treesitter.txt', |   ['set!'] = 'treesitter.txt', | ||||||
|   | |||||||
| @@ -981,7 +981,7 @@ add_target(doc-eval | |||||||
|     ${PROJECT_SOURCE_DIR}/src/nvim/eval.lua |     ${PROJECT_SOURCE_DIR}/src/nvim/eval.lua | ||||||
|     ${PROJECT_SOURCE_DIR}/src/nvim/options.lua |     ${PROJECT_SOURCE_DIR}/src/nvim/options.lua | ||||||
|     ${PROJECT_SOURCE_DIR}/src/nvim/vvars.lua |     ${PROJECT_SOURCE_DIR}/src/nvim/vvars.lua | ||||||
|     ${NVIM_RUNTIME_DIR}/doc/builtin.txt |     ${NVIM_RUNTIME_DIR}/doc/vimfn.txt | ||||||
|   ) |   ) | ||||||
|  |  | ||||||
| add_custom_target(doc) | add_custom_target(doc) | ||||||
|   | |||||||
| @@ -76,7 +76,7 @@ endfunc | |||||||
|  |  | ||||||
| func Test_help_expr() | func Test_help_expr() | ||||||
|   help expr-!~? |   help expr-!~? | ||||||
|   call assert_equal('eval.txt', expand('%:t')) |   call assert_equal('vimeval.txt', expand('%:t')) | ||||||
|   close |   close | ||||||
| endfunc | endfunc | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Phạm Bình An
					Phạm Bình An