17

When I use the search function in Nautilus it only returns files with matching file names. It doesn't even support wildcards. For example, "*.txt" doesn't return anything. I would expect it to return all .txt files.

Anyway, is there a way, without using the command line, to search the contents of files, including all plain text files (.txt, .html, .css, .js, .c, .csv, .sh, .py, ...), archives (.zip, .7z, .rar, .tar, ...), office/libreoffice files (.doc, .docx, pptx, .odf, .ods, ...), and media (.mp3, .mp4, ...) meta data? The search should also have the option of setting file size, date, type, and being case insensitive.

  • You could try installing nepomuk, strigi, and dolphin file browser - together nepomuk and strigi will index (including contents) your file system, and dolphin supports searching this indexed content (as well as supporting other cool features like tagging files...) – jmetz Jul 23 '12 at 19:53
  • 1
    I'd rather not switch to kubuntu or mix applications from different desktop environments/OSs. I'm using stock ubuntu 12.04. – waspinator Jul 23 '12 at 19:57
  • Ok well actually strigi is desktop environment independent and is supported (apparently) in Gnome also: en.wikipedia.org/wiki/Strigi via the deskbar applet. – jmetz Jul 23 '12 at 19:59
  • hmm, strigi is only a daemon. and the gui (catfish) isn't very good. – waspinator Jul 23 '12 at 20:14
12

When you use Nautilus, just click search from the top level of your home folder (i.e. where you can see all your folders laid out) and in the search box only enter .pdf (or whatever extension like .txt that you want to find). That's what I do and it just returned me all the pdfs in my home folder. You don't need to use a wildcard or put quotes around the search term in Nautilus search, unlike when you use search programs on the command line.

The gnome-search-tool can be used to search within files- select the home folder or the directory to be searched and then click select more options, and input your search term where it says 'contains the text.' It can be quite slow as it works without an index, but I have used it several times and it has been useful for basic searches.

  • 2
    ah ok. how about searching for contents of documents using nautilus? – waspinator Jul 23 '12 at 20:09
  • It may be necessary to use a desktop search program that indexes results and forms a database. Take a look at askubuntu.com/questions/29483/… – user76204 Jul 23 '12 at 20:13
  • wow, why isn't this integrated into nautilus! slow, but works as expected. I hope ubuntu catches up with windows/osx in search within this decade. thanks – waspinator Jul 23 '12 at 21:06
  • 1
    integrate such a thing would make them near the desktop... and i'm sure they are AVOIDING it. :\ – neu-rah Dec 7 '14 at 0:19
  • searchmonkey or regexxer are extremelly better tho! askubuntu.com/questions/29483/… – Aquarius Power May 20 '17 at 5:49
0

Here's my solution for 1.5 terabytes of files on an external hard drive - 'cos you can search with "find - all" in the resulting XLSX nice and easy (Does not answer the GUI question, tho - sorry)

Put this in the terminal to create a TXT file with all your folders and files

find -ls > ~/Downloads/IndexTree.txt

afterwards, open the TXT file and replace ./ & / with "*"; also replace "user user" with "user *" to delineate size & date date for this year do not show the year - gee!. Replace "\" with space

Then open in XLS (Libre Office) column delineator "*" Save-As XLSX - (plain XLS only does 35,000 rows - mine had 330,000 rows) Delete first column, replace with auto number 1 thru whatever Select all, SORT by column C & next 7 columns - goes to col G normally

And use the "find" function in Libre Office to your heart's content

0

At the launcher you will see homefolder. Click on it and select the lib you want to search. You see in the right upper corner the answer. You can search with that.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.