Ticket #279 (closed task: fixed)

Opened 12 years ago

Last modified 12 years ago

"Replace srcdoc with html" should work if GSDL is remote, and changes

Reported by: ak19 Owned by: ak19
Priority: moderate Milestone: Release 2.81
Component: GLI Severity: major
Keywords: GLI, replace_srcdoc_with_html, gsdlremote Cc:


Presently the script replace_srcdoc_with_html works when GSDL is running locally. gli/src/org/greenstone/gatherer/gui/ReplaceSrcDocWithHtmlPrompt.java should be adjusted to work when GSDL is remote as well. And then tested.

Once tested, the changes need to be incorporated into Greenstone 3 as well.

$GSDLHOME/bin/script's gsConvert.pl has been changed, and replace_srcdoc_with_html.pl has been added. $GSDLHOME/perllib/plugins now has changes to *.pm files ConvertToPlug? and ALL its subclasses, as well as TEXTPlug.pm. $GSDLHOME/perllib/ has changes to acronym.pm, while there are new additions to the file strings.properties. $GSDLHOME/gli/classes/dictionary.properties also has additions.

Finally, there are some changes to gli java source code files too: CollectionTree?, CollectionTreeNode?, FileManager?, Plugin, PluginManager?, Plugins. There have been some changes to CollectionManager? and GShell to deal with spaces in filepaths.

Change History

Changed 12 years ago by ak19

Finished this off - the rightclick context menu feature that allows one to Replace Source Documents With HTML works remotely now as well.

SVN revisions 15164-15172. There were mainly changes to:

- gliserver.pl: added handling of replace_srcdoc_with_html's arguments in run_script where it also ensures that spaces in filenames are escaped, to deal with such filenames. Added file-exists cmd and corresponding file_exists method.

- RemoteGreenstoneServer?.java: added exists method and RemoteGreenstoneServerExistsAction? class to check for whether a file exists. Makes use of gliserver.pl's file-exists cmd.

- ReplaceSrcDocWithHtmlPrompt?.java: downloads replaced files from remote server. Uses new exists() method of RemoteGreenstoneServer?.java to check for any associated folders before downloading them.

Additional changes were required to the files:

- util.pm: soft_link routine modified to have additional parameter that will ensure src, dest paths are absolute

- files TEXTPlug.pm and ConvertPlug?.pm make use of the modified soft_link subroutine to ensure absolute filepaths (since remote GSDL only passes relative file path to import directory).

- replace_srcdoc_with_html.pl, it must return some output to STDERR or STDOUT on success (GShell.runRemote() requires it)

Changed 12 years ago by ak19

  • status changed from new to closed
  • resolution set to fixed
Note: See TracTickets for help on using tickets.