Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Sep 2017 19:40:20 +0200
From:      Polytropon <freebsd@edvax.de>
To:        Manish Jain <bourne.identity@hotmail.com>
Cc:        "Steve O'Hara-Smith" <steve@sohara.org>, "freebsd-questions@freebsd.org" <freebsd-questions@freebsd.org>
Subject:   Re: case command
Message-ID:  <20170917194020.8f6db248.freebsd@edvax.de>
In-Reply-To: <VI1PR02MB12002177D7F2E684D387C90AF6620@VI1PR02MB1200.eurprd02.prod.outlook.com>
References:  <59BE89E1.3050209@gmail.com> <VI1PR02MB1200B54F7772D37F6BE020F4F6620@VI1PR02MB1200.eurprd02.prod.outlook.com> <20170917155649.e869897ddcc97c3c9d04929c@sohara.org> <VI1PR02MB12002177D7F2E684D387C90AF6620@VI1PR02MB1200.eurprd02.prod.outlook.com>

next in thread | previous in thread | raw e-mail | index | archive | help

On Sun, 17 Sep 2017 15:01:32 +0000, Manish Jain wrote:
> 
> 
> On 09/17/17 20:26, Steve O'Hara-Smith wrote:
> > On Sun, 17 Sep 2017 14:50:00 +0000
> > Manish Jain <bourne.identity@hotmail.com> wrote:
> > 
> >>
> >>
> >> On 09/17/17 20:12, Ernie Luzar wrote:
> >>> Looking for a system command that a I can pip a file through to change
> >>> all uppercase content to lower case.
> >>>
> >>> Is there such a command line command?
> >>
> >> cat <file> | tr '[:upper:]' '[:lower:]'
> > 
> > 	That poor overworked cat :)
> > 
> > tr '[:upper:]' '[:lower:]' < <file>
> > 
> 
> Being the proud owner of a beautiful cat, I rather feel inclined to pay 
> tribute to the family every now and then  : - )

The typical "useless use of cat" often is just an illustration
of how to use a certain command within a pipe chain. In cases
where no piping is needed, redirection can be used easily.

	% cat food.txt | grep "catfood" > mister_kitty.txt

Or:

	% grep "catfood" < food.txt > mister_kitty.txt

I hope the cat will understand now. =^_^=



-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20170917194020.8f6db248.freebsd>