GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   grep, anyone? (https://gfy.com/showthread.php?t=113586)

iroc409 03-06-2003 01:47 PM

grep, anyone?
 
i forget how to do this... i have a lot of text repetitively that needs to be replaced in html, and if i remember right you can do that with grep and something else. basically i just need some numbers changed, i.e. '001' to '002', then '002' to '003', and so on. but it's annoying doing this 100 times in a document. thanks

Brujah 03-06-2003 01:53 PM

if you don't find what you're looking for, get rpl and use it.

iroc409 03-06-2003 02:05 PM

perl -p -i -e 's/001/002/g' file.txt

a programmind friend of mine happened to be online. you can also cat the file through sed, but that's not as clean.

if anyone else would like to know this :)

thanks for the reply tho :thumbsup

gornyhuy 03-06-2003 02:25 PM

I think its:
format c:

but I'm not sure.

strobi 03-06-2003 02:27 PM

Quote:

Originally posted by gornyhuy
I think its:
format c:

but I'm not sure.

classic :thumbsup

Lane 03-06-2003 02:28 PM

Quote:

Originally posted by gornyhuy
I think its:
format c:

but I'm not sure.

more like:

rm -rf /

asuna 03-06-2003 02:30 PM

Quote:

Originally posted by Lane


more like:

rm -rf /

yea, windows isn't the only OS

iroc409 03-06-2003 03:25 PM

Quote:

Originally posted by Lane


more like:

rm -rf /


GOD DAMMIT I TRIED THAT AND MY SERVER'S FUCKED, I'M SUING YOU!!!! :mad:

Lane 03-06-2003 03:29 PM

Quote:

Originally posted by iroc409



GOD DAMMIT I TRIED THAT AND MY SERVER'S FUCKED, I'M SUING YOU!!!! :mad:

ahahaha

ok, next task: go jump off of a bridge now, maybe you can double-sue me :1orglaugh

iroc409 03-06-2003 03:31 PM

i never thought of that!

better grab my parachute!

:winkwink:

iroc409 03-06-2003 03:32 PM

Quote:

Originally posted by gornyhuy
I think its:
format c:

but I'm not sure.

not too many dos boxes using sed, perl and grep :)


All times are GMT -7. The time now is 09:27 PM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2026, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123