genxref: error when pêrmuting glimpse index files
Brought to you by:
ajlittoz
LXR configured with glimpse free-text search engine.
After glimpseindex has done its indexing, the temporary dictory containing the index files is supposed to be moved into 'glimpsedir' directory but command errors out:
mv: cannot stat '…/<version>%@%glix%@%/<version>': No such file or directory
"This is related to fix for bug #275 because reverting the mv command to its prior state cures the problem." (quotation from bug submitter)
The cause is not in the mv itself. If mv command is reverted, bug #275 reoccurs.
What is really needed is to prevent extra directories from being created in the temporary indexing directory. For that, the cp command used to allow incremental indexing must be corrected.
The present
cp -r <index_dir>/<version> <tempd_dir>always creates a version/ subdirectory resulting in the form of the final mv command.cpmust be modified to only copy the index files, but those are "hidden" files (name starting with a dot). Consequently, they aren't automatically copied when using wildcard*. Fortunately, they all ahave a.glimpse_prefix. Thus the command takes the form:cp <index_dir>/<version>/.glimpse_* <temp_dir>and the
mvcommand has no use of aversion/ subpath.Fixed in 2.3.5