Getting Started > Use Lua Scripts > Use Lua Scripts within the CFS > Configure a Lua Script

Configure a Lua Script
You can execute four types of script: pre-Lua or post-Lua, Delete, and Update. Pre-Lua scripts are run after the document data is extracted but before it is filtered, so the document contains metadata. Post-Lua scripts are run after the document data is filtered, so the document also contains the document content. Delete is run when a document is deleted. Update is run when a document is updated. Update and Delete are configured in the same way as Pre and Post, but they appear in the [IndexTasks] section.
Use this procedure to specify the location of the Lua script file.
To configure a Lua script
1.
2.
3.
Locate the [ImportTasks] section, and enter a different value of PreN (for pre-Lua scripts) or PostN (for post-Lua scripts) for each script file. For example:
[ImportTasks]
...
Pre0=Lua:script1.lua
Pre1=Lua:script2.lua
Post0=Lua:script3.lua
4.
To enable family hashing, set the HashN parameter. True indicates that the Lua calculated the hash; False indicates that the hash should be calculated.
5.