Re: [CentOS] command line escaping a dash

2008-10-20 Thread Filipe Brandenburger
The right answer is using -- to stop handling command line arguments. There is another trick that might help to do it too: using "./" in front of the filename the filename. # chown Administrator './-BILLED JOBS - 1997-2002' -R This should work. HTH, Filipe ___

Re: [CentOS] command line escaping a dash

2008-10-20 Thread William L. Maltby
On Mon, 2008-10-20 at 11:22 -0400, William L. Maltby wrote: > > In most cases, putting a single '-' signals the last "flag" and says Rats! As Hakan said, '--' > -- Bill ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/lis

Re: [CentOS] command line escaping a dash

2008-10-20 Thread William L. Maltby
On Mon, 2008-10-20 at 08:04 -0700, Craig White wrote: > I cannot figure this out... > > I would like to change the owner of a bunch of folders whose name begins > with a dash... > > # chown Administrator \-BILLED\ JOBS\ -\ 1997-2002 -R > chown: invalid option -- B > Try `chown --help' for more i

Re: [CentOS] command line escaping a dash

2008-10-20 Thread Craig White
On Mon, 2008-10-20 at 16:09 +0100, Hakan Koseoglu wrote: > Hi Craig, > > Craig White wrote: > > I cannot figure this out... > > > > I would like to change the owner of a bunch of folders whose name begins > > with a dash... > > When you are using shell commands, if you use double-dash, you don't

Re: [CentOS] command line escaping a dash

2008-10-20 Thread Bob Beers
On Mon, Oct 20, 2008 at 11:04 AM, Craig White <[EMAIL PROTECTED]> wrote: > I cannot figure this out... > > I would like to change the owner of a bunch of folders whose name begins > with a dash... > > # chown Administrator \-BILLED\ JOBS\ -\ 1997-2002 -R > chown: invalid option -- B > Try `chown --

Re: [CentOS] command line escaping a dash

2008-10-20 Thread Hakan Koseoglu
Hi Craig, Craig White wrote: I cannot figure this out... I would like to change the owner of a bunch of folders whose name begins with a dash... When you are using shell commands, if you use double-dash, you don't need to escape it. [EMAIL PROTECTED] ~]# mkdir -- "-test" [EMAIL PROTECTED]

[CentOS] command line escaping a dash

2008-10-20 Thread Craig White
I cannot figure this out... I would like to change the owner of a bunch of folders whose name begins with a dash... # chown Administrator \-BILLED\ JOBS\ -\ 1997-2002 -R chown: invalid option -- B Try `chown --help' for more information. # chown Administrator "\-BILLED\ JOBS\ -\ 1997-2002" -R ch