On Wed, 2014-11-26 at 15:16 -0800, Junio C Hamano wrote:
> > $ ./src/git/contrib/workdir/git-new-workdir src/git foo master
> > mkdir: cannot create directory ‘foo’: Not a directory
> > unable to create new workdir "foo"!
> 
> ;-)  That comes from mkdir || fail which is indeed sufficient.

Right.  Often I find it simpler/clearer to let the underlying commands
give the errors: they use perror() and can often provide more specific
error messages than my script can, unless I spend a lot of effort trying
to determine exactly what the problem is (permissions, disk space, bad
symlink, existing file, whatever).

Should I respin this with the \"$new_workdir\" -> '$new_workdir' change
(I actually prefer the latter myself but the former was used somewhere
so I kept it)?

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to