![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Rules & FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here. |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Search, replace string in file1 with string from (lookup table) file2? | gstuart | Shell Programming and Scripting | 2 | 04-11-2008 11:32 AM |
| SED Replace String Help | prash184u | Shell Programming and Scripting | 2 | 01-22-2008 09:57 PM |
| Basic sed replace question | fed.linuxgossip | Shell Programming and Scripting | 13 | 05-09-2007 09:42 AM |
| Replace string B depending on occurence of string A | hemangjani | Shell Programming and Scripting | 1 | 12-05-2006 01:10 PM |
| How to replace within a string | aukequist | Shell Programming and Scripting | 2 | 02-07-2006 03:42 AM |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
basic cat replace string
trying to exclude hostnames ending in "s" from a host file:
Code:
# cat hosts
ssef
ssefd
ssefsfff
ssefsfs
# for x in `cat hosts`; do echo "${x/*s}" ;done
ef
efd
fff
#
How can I echo/or not echo only 'ssefsfs' ?? thanks |
| Forum Sponsor | ||
|
|