Ignore:
Timestamp:
2020-07-23T18:33:28+12:00 (4 years ago)
Author:
ak19
Message:
  1. Dictionary string for the CSV filefilter extension description. 2. Gone back to attempting to upload any meta.csv created directly in the collection folder to server, and fixed an oversight in RemoteGreenstoneServer.getPathRelativeToDirectory() that prevented this because of an extra File separator char. However, even though the file now gets successfully uploaded, it won't get downloaded to the client again when the collection is reopened. (Also happens if the meta.csv file was exported into the collection's etc subfolder). This is because the remote server carefully selects which files get sent back to the client when a collection is opened, and csv files outside the import directory are not part of the existing selection. There's no compelling reason to incorporate csv files either, as the client's collect folder is stored in a hidden gli user folder anyway, and it's best the client-gli user choose an easily discoverable and accessible folder into which their exported meta csv is saved.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/gli/src/org/greenstone/gatherer/remote/RemoteGreenstoneServer.java

    r34160 r34285  
    836836    {
    837837    String file_path = file.getAbsolutePath();
     838
     839    // Special case: if file path is longer by File separator,
     840    // still dealing with practcally the same folder path, return relative path as "."
     841    if(directory_path.equals(file_path + File.separator)) {
     842        return ".";
     843    }
    838844    if (!file_path.startsWith(directory_path)) {
    839845        System.err.println("ERROR: File path " + file_path + " is not a child of " + directory_path);
Note: See TracChangeset for help on using the changeset viewer.