Locate

locate locates. It locates! Very Simple. But you probably want to just use the search utility of your operating system. If a file was created just now, you might want to use find instead. Locate updates its list generally every night, unless it was set to update at other times. But the search function that came with your operating system makes the most sense out of the three.

Relevant Usage at Saier Lab
Finding files when using the terminal. Always useful, but it's probably easier to use the search utility that comes with most operating systems, such as Windows or Mac. Also know that find can be unreasonably slow. Locate updates every night, so if a file was created today, locate won't see it.

To find a file called "test.txt", you would type: locate test.txt

Asterisk
The asterisk can be used to denote "anything". If you can't remember if your file was called "file1.txt" or "file1.fasta", and it's on the Desktop, you can type: locate file1.* and it will find files that start with "test." and end with anything. The '*' denotes that anything can go here. Similarly, if you want to find all of your .phr files, you can run: locate *.phr and it will find all of the files that start with anything and end with ".phr". You can put the * anywhere, like "test*.txt".

Person to Ask

 * Bryant
 * Anyone