Revision 1000 tmp/org.txm.groovy.core/src/groovy/org/txm/scripts/importer/transcriber/transcriberLoader.groovy

transcriberLoader.groovy (revision 1000)
43 43
//
44 44
package org.txm.scripts.importer.transcriber;
45 45

  
46
import java.io.File;
47
import org.txm.scripts.importer.xmltxm.*;
46
import java.io.File;
47
import org.txm.importer.*
48
import org.txm.importer.scripts.xmltxm.*;
48 49
import org.txm.*;
49 50
import org.txm.core.engines.*;
50 51
import org.txm.objects.*;
......
114 115

  
115 116
//get metadata values from CSV
116 117
Metadatas metadatas; // text metadata
117
File allmetadatasfile = Metadatas.findMetadataFile(srcDir);
118
println "Trying to read metadatas values from: "+allmetadatasfile
119
if (allmetadatasfile.exists()) {
120
	File copy = new File(binDir, allmetadatasfile.getName())
121
	if (!FileCopy.copy(allmetadatasfile, copy)) {
122
		println "Error: could not create a copy of metadata file "+allmetadatasfile.getAbsoluteFile();
118
File allMetadataFile = Metadatas.findMetadataFile(srcDir);
119
println "Trying to read metadatas values from: "+allMetadataFile
120
if (allMetadataFile.exists()) {
121
	File copy = new File(binDir, allMetadataFile.getName())
122
	if (!FileCopy.copy(allMetadataFile, copy)) {
123
		println "Error: could not create a copy of metadata file "+allMetadataFile.getAbsoluteFile();
123 124
		return;
124 125
	}
125 126
	metadatas = new Metadatas(copy, Toolbox.getMetadataEncoding(), 
......
127 128
		Toolbox.getMetadataTextSeparator(), 1)
128 129
}
129 130
else
130
	println "no metadata file: "+allmetadatasfile
131
	println "no metadata file: "+allMetadataFile
131 132

  
132 133
File propertyFile = new File(srcDir, "import.properties")//default
133 134
Properties props = new Properties();

Also available in: Unified diff