lkml.org 
[lkml]   [2005]   [Apr]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: Linux 2.6.12-rc3
Date
Greg KH <greg@kroah.com> wrote:

> Feel free to make it better, I have never claimed to be a bash
> programmer :)

Just some basic comments:

> #!/bin/bash

set -e

> DIR=$1
>
> mkdir $DIR
> cd $DIR
[...]

General rule: _*Allways*_ use quotes for variable expansion.

Reason:

$ md foo\ bar
$ DIR=Foo\ bar
$ cd $DIR
bash: cd: foo: No such file or directory

--
Top 100 things you don't want the sysadmin to say:
70. Hmm, maybe if I do this...

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-04-24 17:15    [W:0.018 / U:0.496 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site