Here's how to check which virtual machine you are running under Windows XP.
Please be aware that if your operating system displays paths to you in a
anguage other than English, it almost certainly still uses the English
pathnames underlyingly. So a path that appears to you as
"/Applicazioni" or "/Utenti/beatrice/Scrivania" will likely need to be
specified by the English "/Applications" or "/Users/beatrice/Desktop".
Again, if your operating system displays pathnames in a language other
than English, the alias in your shell initialization file almost certainly
needs to be specified in terms of the English directories.
Be sure to include the quotation marks in the first argument after
"-classpath". Also note the different direction of the slashes in the
first and the second argument (backward and forward, respectively).
The search results are written to a file with the same basename as the
query file, but with the extension .out ("foo.out" in the
case at hand).
The basename of the output file (but not the extension) can be changed
using an "-out" switch. Not "-o", but "-out".
If CorpusSearch reports a run-time error because the underlying corpus is
corrupted (for instance, because of mismatched parentheses), it sends an
error message to the terminal screen by default. Tracking down such
errors generally requires redirecting the error message to a file. The
file is standardly called "ERR", but the name is up to the user.
Depending on the complexity of a query and the size of the input, searches
can take from a few seconds to a few hours. To run a search in the
background under Unix/Linux, add an ampersand (&) at the end of
your command:
Before initiating a search in the background, make sure there is no .out
file corresponding to the query you intend to run. If there is, your
search will stall.
Preliminaries
Installing CorpusSearch
If you have moved the .jar file to some other location than /Applications,
edit the path accordingly.
java -classpath /Applications/CS_2.003.04.jar csearch/CorpusSearch
Use the appropriate syntax for other shells.
Now you can invoke CorpusSearch with just "CS".
alias CS 'java -classpath /Applications/CS_2.003.04.jar csearch/CorpusSearch'
cd C:\
java -classpath "C:\Program Files\CS.jar" csearch/CorpusSearch
Running CorpusSearch
CorpusSearch is run from a terminal window (or "cmd" box) as described
above. It needs two arguments to run: a command file and one or more
source files. Assuming the alias "CS" defined in the previous section,
the following command runs the query "foo.q" on the source file "bar.psd".
The above command assumes that the command file and source files are in
the same directory as the one from which you're invoking CorpusSearch. If
that is not the case, you need to specify full paths to the files in
question. For example:
CS foo.q bar.psd
Using standard command line conventions, more than one file can be
searched in a single run.
CS /path/to/query/file/foo.q path/to/input/file/bar.psd
CS ../queries/foo.q ../../corpus/bar.psd
CorpusSearch can also be invoked without arguments. It then prompts the
user to enter the names of the command file and of the source file(s).
CS foo.q a*.psd *z.psd /some/other/directory/*.psd
CS foo.q bar.psd -out foo-on-bar.out
CS foo.q *.psd -out all.out
CS foo.q bar.psd >& ERR
CS foo.q *.psd >& help-me-debug
CS foo.q bar.psd &
CS foo.q bar.psd >& ERR &