“apt contains” tells you which package contains a particular file. It’s a shortcut for “dpkg -S”. For instance if you type “apt contains /usr/lib/linuxmint/mintSystem/GPL.txt” you should see the following:

“search” is easy to use. Let’s take an example and search for “workgroup” in /etc/samba. We type “search for workgroup in /etc/samba” and we see the following:

clem@mars ~/Desktop $ search for workgroup in /etc/samba
/etc/samba/smb.conf.ucf-old:26:# Change this to the workgroup/NT-domain name your Samba server will part of
/etc/samba/smb.conf.ucf-old:27: workgroup = MSHOME
/etc/samba/smb.conf:26:# Change this to the workgroup/NT-domain name your Samba server will part of
/etc/samba/smb.conf:27: workgroup = MSHOME

We can refine the search by adding “–case-sensitive” or only show filenames by adding “–show-filenames-only”. For instance:

roberto@roberto-desktop ~ $ search for workgroup in /etc/samba
/etc/samba/smb.conf:26:# Change this to the workgroup/NT-domain name your Samba server will part of
/etc/samba/smb.conf:27: workgroup = MSHOME
roberto@roberto-desktop ~ $

Thanks Clem for this useful new features
but for “apt contains” I don’t need a path?
{~._.~}
( Y )
()~*~()
(_)-(_)
tim@mint-felicia ~ $ apt contains GPL.txt
mintsystem: /usr/lib/linuxmint/mintSystem/GPL.txt
mintupdate: /usr/lib/linuxmint/mintUpdate/GPL.txt
I like the “search” command, because I’m not a big fan of tracker!
its powerful to find text also in binaries
Now I can find my stuff
cheers
Tim

Angelo: We don’t do marketing hype, this has one purpose only: to simplify your usage or Mint and make it more comfortable. I personally use the search command A LOT, and that’s the reason it’s here.. because for simple things we shouldn’t have to google up complicated commands. Read the blog post and you’ll see, it’s no secret these commands are indeed just shortcuts but they make our life easier and yes, I do believe they add a lot to this particular release.

{} works. Curly braces are not special enough that you need to escape them.

Also, consider using + instead of \; when you want to operate on a bunch of files and don’t need to do one at a time (as in your example). It works like piping to xargs instead of using -exec, but you avoid the extra process. man find for details.