source: trunk/tools/tiffcomment.bat @ 6182

Revision 6182, 1.1 KB checked in by curtis, 10 years ago (diff)

Fix up logging with Bio-Formats command line tools.
This removes the hard dependency on log4j in Bio-Formats, so it should be
possible to log with other logging frameworks via SLF4J now. There is also
a log4j configuration filein the tools folder now, which should make it easier
to configure output for debugging, stack traces, etc.

Line 
1@echo off
2
3rem tiffcomment.bat: a batch file for extracting the comment
4rem                  (OME-XML block or otherwise) from a TIFF file
5
6rem Required JARs: loci_tools.jar
7
8rem JAR libraries must be in the same directory as this
9rem command line script for the command to function.
10
11rem If you are a developer working from source and have
12rem the LOCI classes in your CLASSPATH, you can set the
13rem LOCI_DEVEL environment variable to use them instead.
14
15set PROG=loci.formats.tools.TiffComment
16set DIR=%~dp0
17
18if "%LOCI_DEVEL%" == "" (
19  rem Developer environment variable unset; look for proper libraries
20  if exist "%DIR%loci_tools.jar" goto found
21  if exist "%DIR%bio-formats.jar" goto found
22  goto missing
23) else (
24  rem Developer environment variable set; try to launch
25  java -mx512m %PROG% %*
26  goto end
27)
28
29:found
30rem Library found; try to launch
31java -mx512m -cp "%DIR%";"%DIR%bio-formats.jar";"%DIR%loci_tools.jar" %PROG% %*
32goto end
33
34:missing
35echo Required JAR libraries not found. Please download:
36echo   loci_tools.jar
37echo from:
38echo   http://www.loci.wisc.edu/bio-formats/downloads
39echo and place in the same directory as the command line tools.
40
41:end
Note: See TracBrowser for help on using the repository browser.