shell-script-pt
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [shell-script] Re: Inverted piped commands


From: Julio C. Neves
Subject: Re: [shell-script] Re: Inverted piped commands
Date: Mon, 27 Jun 2011 18:15:15 -0300

Hi  Eric,
You said:

"Got it!

A file which I was using to grab those variables values were DOS formatted."

So, all you gotta do is another pipe, with a tr command, like this:

$ tr -d '\r' < MATRIZ/HDLM_MATRIX.txt | grep -i "$OSFULLNAME" | grep -i
"$HBAMANFAC" | grep q

  Cordialmente,

Julio Neves
*Quer programar bem em Shell?
*

*Use este endereço de e-mail, o Skype ou ☎ (21)8112-9988 ☎*

*
*

**

*
*
My profiles: [image: Twitter] <http://twitter.com/juliobash>
Contact me: [image: Skype] julioneves1


2011/6/27 eric miranda <address@hidden>

> **
>
>
> Got it!
>
> A file which I was using to grab those variables values were DOS formatted.
>
> Thank you!
>
> Eric
>
>
> 2011/6/27 eric miranda <address@hidden>
>
> > Dear experts,
> >
> > I'm facing an issue wich I can't figure out how to solve.
> >
> > I wrote a script that contains a line:
> >
> > ...
> > cat MATRIZ/HDLM_MATRIX.txt|grep -i "${OSFULLNAME}"|grep -i
> > "${HBAMANFAC}"|grep q
> > ...
> >
> > But, when executed it inverts (as far as i noticed it) the order of the
> > piped commands, returning nothing:
> >
> > ...
> > + cat MATRIZ/HDLM_MATRIX.txt
> > + grep -i QLogic
> > + grep q
> > + grep -i Windows 2003 SP2 (X64 / x86_64)
> > ...
> >
> > Why is bash messing up my life? :)
> >
> > tnx in advance!
> >
> >
>
> [As partes desta mensagem que não continham texto foram removidas]
>
>  
>


[As partes desta mensagem que não continham texto foram removidas]



reply via email to

[Prev in Thread] Current Thread [Next in Thread]