Hi, i read couple of threads here on forum, and googled about what bugs me, yet i still can't find solution.
Problem is below.
I need to change this string (with sed if it is possible):
to look like this:
I managed to do this by using:
Ok, it doesen't replace closing tag [/rquote] to [/bquote], but i can run sed again just to replace that.
That works, until it come do double quote, like this:
How can i get above example (with double quote) to be replaced with this:
Some help?
P.S. It is not so impotrant to change those closing tags [/rquote] to [/bquote] in the same sed expression.
Hi,
I have a program that searches for a particular string patten. I am however having difficulty passing the varible $i (in a loop) as the string pattern to replace. Using either perl or sed search and replace statements, I get the same kinda result. For example, using the perl:
for i in... (3 Replies)
Plzzzz, tell me some script about this...
What does this mean ?
sed '/^ */s///'
sed '/^/s// /'
and why it's diferent ???
sed '/ */s// /g' and sed 's/ */ /g'. It's all the same ???
Thanks you very much (2 Replies)
Hi All,
I am just learning shell programming,
I need to do the following in my shell script.
Search a given log file for two\more strings.
If the the two\more strings are found then write it to a outputfile else
if only one of the string is found, write the found string in one output... (2 Replies)
Hey everyone!
Simple question - I am trying to use sed to replace two different strings. As it stands I can implement this as:
sed -i 's/TIMEOUT//g'
sed -i 's/null//g'
And it works. However, is it possible to shrink that down into a single command? Will there be any performance benefits? (3 Replies)
Hi There...
I need to serach and replace a strings in a text file.
My file has; books.amazon='Let me read' and the output needed is
books.amazon=NONFOUND
pls if anybody know this can be done in script sed or awk.. i have a list of different strings to be repced by NONFOUND.... (7 Replies)
Hi All,
I need help in manipulating the data in first column in a file.
The sample data looks like below,
Mon Jul 18 00:32:52 EDT 2011,NULL,UAT
Jul 19 2011,NULL,UAT
1] All field in the file are separated by ","
2] File is having weekly data extracted from database
3] For eg.... (8 Replies)
Hi All,
I need to serach and replace a strings between single quote in a file.
My file has :
location='/data1/test.log' and the output needed is
location='/data2/test_dir/test.log'
pls if anybody know this can be done in script sed or awk.
I have a script, but it's... (6 Replies)
I have a list of files all over a file system e.g.
/home/1/foo/bar.x
/www/sites/moose/foo.txtI'm looking for strings in these files and want to replace each occurrence with a replacement string, e.g.
if I find: '#@!^\&@ in any of the files I want to replace it with: 655#@11, etc.
There... (2 Replies)
Hi All,
How can I find (pattern search with grep/awk/sed) all files containing any IP address pattern in one directory hierarchy and in its sub-directories. The files can contains more than 4 octets in addition to the IP address as shown below. IP address can contain any octet combinations like-... (3 Replies)
Hello,
I would like to replace all occurencies of long data types by others (coresponding int) using 'sed' in the extensive source code of a software package written for 32 bit CPUs.
I must use regular expressions to avoid wrong replacements like
s/unsigned]+long/ulong/gLeaving out... (2 Replies)
Discussion started by: Mick P. F.
2 Replies
LEARN ABOUT DEBIAN
jsonbot
JSONBOT(1) jsb manual JSONBOT(1)NAME
JSONBOT - The JSON everywhere bot!
SYNOPSIS
JSONBOT is a remote event-driven framework for building bots that talk JSON to each other over XMPP. This manual page documents briefly the
jsb distribution..
DESCRIPTION
This distribution provides bots built on this framework for console, IRC, XMPP, Convore and WWW on the shell.
USAGE
JSONBOT uses command line options to configure a bot. See the --help option to get more help on a command options or see the corresponding
man page.
the jsb pakage contains the following programs:
* jsb - console version of jsb
* jsb-backup - create backup of JSONBOT datadir
* jsb-convore - convore version of jsb
* jsb-init - create data directory and config examples, default ~/.jsb
* jsb-irc - IRC version of jsb
* jsb-fleet - mix IRC and XMPP bots
* jsb-sed - sed a whole directory
* jsb-stop - stop a running bot
* jsb-tornado - a shell web server based on tornado
* jsb-udp - send udp packets to the bot that will relay the data
* jsb-xmpp - XMPP version of jsb
note: JSONBOT is in BETA stage right now and still subject to change of protocols and API.
see http://jsonbot.googlecode.com. see https://jsonbot.org for documentation on the bot.
SEE ALSO
The program is documented fully on http://jsonbot.org or see http://jsonbot.googlecode.com
SEE ALSO jsb(1), jsb-backup(1), jsb-init(1), jsb-irc(1), jsb-xmpp(1), jsb-fleet(1), jsb-tornado(1), jsb-stop(1), jsb-udp(1)AUTHOR
This manual page was written by Bart Thate <bthate@gmail.com>, for the Debian GNU/Linux system (but may be used by others).
Debian GNU/Linux 22 Nov 2011 JSONBOT(1)