Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Document the global :LuaCheckSyntax and :LuaCheckGlobals commands

  • Loading branch information...
commit 624ee7015b9c4c8557624ad373335aa51e3d6878 1 parent 17e9003
@xolox authored
Showing with 37 additions and 6 deletions.
  1. +12 −2 README.md
  2. +25 −4 doc/ft_lua.txt
View
14 README.md
@@ -119,14 +119,24 @@ By default the Lua file type plug-in sets the ['omnifunc'] [] option so that Vim
By default the Lua file type plug-in defines insert mode mappings so that the plug-in is called whenever you type a single quote, double quote or a dot inside a Lua buffer. This enables context sensitive completion. If you don't like these mappings you can set this option to zero (false). In that case the mappings will not be defined.
+## Commands
+
+### The `:LuaCheckSyntax` command
+
+Check the current file for syntax errors using the Lua compiler. This command is executed automatically when you write a Lua script to disk (i.e. when you save your changes) unless `lua_check_syntax` is false.
+
+### The `:LuaCheckGlobals` command
+
+Check the current file for undefined global variables. This command is executed automatically when you write a Lua script to disk (i.e. when you save your changes) unless `lua_check_globals` is false or syntax errors were detected.
+
## Contact
If you have questions, bug reports, suggestions, etc. the author can be contacted at <peter@peterodding.com>. The latest version is available at <http://peterodding.com/code/vim/lua-ftplugin> and <http://github.com/xolox/vim-lua-ftplugin>. If you like this plug-in please vote for it on [Vim Online][script].
## License
-This software is licensed under the [MIT license](http://en.wikipedia.org/wiki/MIT_License).
2013 Peter Odding &lt;<peter@peterodding.com>&gt;.
+This software is licensed under the [MIT license](http://en.wikipedia.org/wiki/MIT_License).
2014 Peter Odding &lt;<peter@peterodding.com>&gt;.
['completefunc']: http://vimdoc.sourceforge.net/htmldoc/options.html#'completefunc'
View
29 doc/ft_lua.txt
@@ -20,9 +20,12 @@ Contents ~
12. The |lua_define_completefunc| option
13. The |lua_define_omnifunc| option
14. The |lua_define_completion_mappings| option
- 4. Contact |ft_lua-contact|
- 5. License |ft_lua-license|
- 6. References |ft_lua-references|
+ 4. Commands |ft_lua-commands|
+ 1. The |:LuaCheckSyntax| command
+ 2. The |:LuaCheckGlobals| command
+ 5. Contact |ft_lua-contact|
+ 6. License |ft_lua-license|
+ 7. References |ft_lua-references|
===============================================================================
*ft_lua-introduction*
@@ -230,6 +233,24 @@ like these mappings you can set this option to zero (false). In that case the
mappings will not be defined.
===============================================================================
+ *ft_lua-commands*
+Commands ~
+
+-------------------------------------------------------------------------------
+The *:LuaCheckSyntax* command
+
+Check the current file for syntax errors using the Lua compiler. This command
+is executed automatically when you write a Lua script to disk (i.e. when you
+save your changes) unless |lua_check_syntax| is false.
+
+-------------------------------------------------------------------------------
+The *:LuaCheckGlobals* command
+
+Check the current file for undefined global variables. This command is executed
+automatically when you write a Lua script to disk (i.e. when you save your
+changes) unless |lua_check_globals| is false or syntax errors were detected.
+
+===============================================================================
*ft_lua-contact*
Contact ~
@@ -242,7 +263,7 @@ lua-ftplugin. If you like this plug-in please vote for it on Vim Online [17].
*ft_lua-license*
License ~
-This software is licensed under the MIT license [18]. Š 2013 Peter Odding
+This software is licensed under the MIT license [18]. Š 2014 Peter Odding
<peter@peterodding.com>.
===============================================================================
Please sign in to comment.
Something went wrong with that request. Please try again.