Re: [Hampshire] XP built for qemu

Top Page

Reply to this message
Author: Graham Bleach
Date:  
To: Hampshire LUG Discussion List
Subject: Re: [Hampshire] XP built for qemu
On 11/02/07, Sean Gibbins <sean@???> wrote:
> root@bender:~# find /etc -name pass*d
> /etc/pam.d/passwd
> /etc/passwd


Good tip. I'd like to refine it slightly.

It is always a good idea to wrap arguments to -name in quotes to stop
them being expanded by the shell. I generally use single quotes, as
the shell will never expand anything within them.

# find /etc -name 'pass*d'

Without the quotes the results are unpredictable. Let's imagine that
there's a file called "password" in the current working directory.

find /etc -name pass*d

would be expanded by the shell to

find /etc -name password

with entirely different (and surprising) results.

G