Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 13 Jun 2011 13:15:43 -0700
From:      Garrett Cooper <yanegomi@gmail.com>
To:        Josh Paetzel <jpaetzel@freebsd.org>
Cc:        svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org
Subject:   Re: svn commit: r223056 - head/etc/periodic/daily
Message-ID:  <BANLkTinBS9xxA2AnKWRq%2Bo2nMLygDbv9Jg@mail.gmail.com>
In-Reply-To: <201106131945.p5DJj1JF096079@svn.freebsd.org>
References:  <201106131945.p5DJj1JF096079@svn.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Jun 13, 2011 at 12:45 PM, Josh Paetzel <jpaetzel@freebsd.org> wrote=
:
> Author: jpaetzel
> Date: Mon Jun 13 19:45:01 2011
> New Revision: 223056
> URL: http://svn.freebsd.org/changeset/base/223056
>
> Log:
> =A0Convert the allowed characters '-', '.', and ':' in a ZFS pool name to=
 _
> =A0to avoid causing errors in the shell script.

This could be done like:

sed -E -e 's/[-\.:]/_/g'

to avoid the need for pipelining multiple tr calls. Example:

$ echo :-. | sed -E -e 's/[-\.:]/_/g'
___
$



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?BANLkTinBS9xxA2AnKWRq%2Bo2nMLygDbv9Jg>