asked on
ASKER
[root@broken ~]# cat qqq
$test
[root@broken ~]# sed 's#$test#<b>$test</b>#g' qqq
<b>$test</b>
ASKER
sed 's/\$test/<b>\$test<\/b>/g'
sed "s#$test#<b>$test</b>#g"
# echo $0
ksh
# sed 's#$test#<b>$test</b>#g' qqq
<b>$test</b>
$ sed 's#$test#<b>$test</b>#g' tt
<b>$test</b>
$ uname -a
SunOS phxdns1 5.10 Generic_118822-26 sun4v sparc SUNW,Sun-Fire-T1000
$ echo $0
ksh
[root@broken ~]# cat kshsed
#!/bin/ksh
sed 's#$test#<b>$test</b>#g' /tmp/qqq
[root@broken ~]# ./kshsed
<b>$test</b>
Solaris:$ cat kshsed
#!/usr/bin/ksh
sed 's#$test#<b>$test</b>#g' /tmp/tt
$ ./kshsed
<b>$test</b>
#!/bin/ksh
sed 's#$test#<b>$test</b>#g' /tmp/file
[root@broken ~]# cat /tmp/file
$test
which ksh
ASKER
ASKER
The term 'shell' refers to a general class of text-based command interpreters most often associated with the UNIX and Linux operating systems. Popular shells include Bourne, Debian Almquist (dash), Korn (ksh), Bourne Again (bash) and the C shell family (csh). Some view the DOS 'cmd' prompt as a minimal shell of sorts. It is also possible to install Cygwin on Windows and emulate a full Unix environment with complete shell capabilities. Terminal emulators, such as xterm, GNOME Terminal and OS X Terminal, can be used to access shell.
TRUSTED BY