- linux or unix-like environment (pthread)
- bash-like command tool
- gcc
- it works well in WSL
cd proj_folder
make
WARNING!
Some linkers will throw errors because of the -lpthread
flag. If that is happening in your case as well, try this command:
gcc -o mole -std=gnu99 -Wall -lm mole.c priority_queue.c globals.c index.c stack.c -lpthread
placing the -lpthread
flag at the end should do the trick.
If there are still some errors try substituting -lpthread
with -pthread
.
mole -d <directory> [-f <index-file>] [-t <time interval for periodic indexing>]
If -d
is not specified, the program will use the path from environmental variable $MOLE_DIR
.
If neither the variable and -d
are provided, the program ends with an error.
If -f
is not specified, the program will use the file from environmental variable $MOLE_INDEX_PATH
.
In case neither the variable and -f
are specified, the index-file location will be set to ~/mole-index
.
If -t
is not specified, then the periodic indexing is off.
During the word of the mole use these commands:
index
- initiate indexing procedure
exit
- finishes ongoing word, saves progress and quits
exit!
- quits abruptly
largerthan <number>
- lists files larger than <number
count
- lists the amount of files of recognisable types that are in the index
namepart <string>
- lists the files which name consists the <string>
owner <uid>
- lists the files that are owned by user <uid>