Author: Lennart Sorensen Date: To: dmo-discussion Subject: Re: mythweb 0.27
On Sat, Oct 05, 2013 at 08:51:34AM +0200, Christian Marillat wrote: > "Lennart Sorensen" <lsorense@???> writes:
>
> > On Fri, Oct 04, 2013 at 01:26:02PM -0400, Lennart Sorensen wrote:
> >> On Fri, Oct 04, 2013 at 06:39:12PM +0200, Christian Marillat wrote:
>
> [...]
>
> > Hmm, that didn't actually quite work.
> >
> > This seems to:
> >
> > cat $INPUT | perl -pe "
> > s/(^[ \t]*setenv[ \t]+db_server[ \t]+\")[^\"]*\"/\$1\$ENV{'hostname'}\"/g;
> > s/(^[ \t]*setenv[ \t]+db_name[ \t]+\")[^\"]*\"/\$1\$ENV{'database'}\"/g;
> > s/(^[ \t]*setenv[ \t]+db_login[ \t]+\")[^\"]*\"/\$1\$ENV{'mythtv_username'}\"/g;
> > s/(^[ \t]*setenv[ \t]+db_password[ \t]+\")[^\"]*\"/\$1\$ENV{'mythtv_password'}\"/g;
> > " > $NEW
>
> Works for me. One change, I need to export all variables at the top of
> the script.
Yes, that is true.
I didn't actually look at the script, just the email thread about the
problem. And I tested it by just dumping some text through it with the
variables exported.
Hopefully people won't have issues with their passwords in the future
then.