12-03-2015
Yeah you're right, I didn't include the zero.
Yeah that looks great, thanks so much. How do I run the script? Is it a perl script or should I just put it into the linux terminal?
9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi, I need some help in text manipulation.
I have an input file like this:
7629 "WPCW 19 - CW/AM1, WPCB 40 - FAMN/CORNER, WPCB-DT1 50 - FAMN/CORNER, "
W35AW - Various Shopping Pgms
W41CF - TBN
W47CV - TBN
WLLS-LP 49 - AM1
WATCH WPXI 11 N & WPIX 11 CW
1234 "WPCW 19 - CW/AM1,... (26 Replies)
Discussion started by: injeti
26 Replies
2. UNIX for Dummies Questions & Answers
I want to have a terminal open and have something like a "repeating cat" command running in it for a certain text file (in particular /var/log/system.log). So my terminal will scan or cat the text file every so often or whenever the text file system.log gets written to by the system, it will... (1 Reply)
Discussion started by: guitarscn
1 Replies
3. Programming
Is there any way to erase all the contents of a specific line of a text file and then write something on it?
e.g.
test.txt.old:
qwert
asdfg
zxcbv=0
test.txt.new
qwerty
asdfg
hello=0
is this possible with C++ ?:confused: (1 Reply)
Discussion started by: hakermania
1 Replies
4. OS X (Apple)
Mac OS X 10.6: Leopard - I'm trying to create a script that will run on its own that can edit system preferences. I've done some digging, and found that a lot of system preference options are controlled by .plist files in ~/library/preferences, /library/preferences, and... (1 Reply)
Discussion started by: Jalaska13
1 Replies
5. Shell Programming and Scripting
Dear Members,
I have a table in Oracle DB and one of its column name is INFO which has data in text format which we need to fetch in a script and create an xml file of a new table from the input.
The contents of a single cell of INFO column is like:
Area:app - aam
Clean Up Criteria:... (0 Replies)
Discussion started by: Yoodit
0 Replies
6. Shell Programming and Scripting
I have a text file that has data like:
Data "12345#22"
Fred
ID 12345
Age 45
Wilma
Dino
Data "123#22"
Tarzan
ID 123
Age 33
Jane
I need to figure out a way of adding 1,000,000 to the specific lines (always same format) in the file, so it becomes:
Data "1012345#22"
Fred
ID... (16 Replies)
Discussion started by: say170
16 Replies
7. Shell Programming and Scripting
Dear Guru's
I'm using Putty and want to edit a file. I know we generally use vi editor to do it. As I'm not good in using vi editor, I want to convert the vi into something like text pad. Is there any option in Putty to do the same ? Thanks for your response.
Srini (6 Replies)
Discussion started by: thummi9090
6 Replies
8. Shell Programming and Scripting
Hello All,
I have a text file containing output from a command that contains lots of escape/control characters that when viewed using vi or view, looks like jibberish. But when viewed using the cat command the output is formatted properly.
Is there any way to take the output from the cat... (7 Replies)
Discussion started by: mrm5102
7 Replies
9. UNIX for Dummies Questions & Answers
Good morning all, I have a machine running IRIX and I need to edit a text file on the terminal that is literally thousands of lines. Does anyone know the most efficient way to edit portions of files like these? Obviously simply using the vi command isn't going to work since I get a too many lines... (1 Reply)
Discussion started by: James C
1 Replies
LEARN ABOUT V7
scriptreplay
SCRIPTREPLAY(1) User Commands SCRIPTREPLAY(1)
NAME
scriptreplay - play back typescripts, using timing information
SYNOPSIS
scriptreplay [options] [-t] timingfile [typescript [divisor]]
DESCRIPTION
This program replays a typescript, using timing information to ensure that output happens in the same rhythm as it originally appeared when
the script was recorded.
The replay simply displays the information again; the programs that were run when the typescript was being recorded are not run again.
Since the same information is simply being displayed, scriptreplay is only guaranteed to work properly if run on the same type of terminal
the typescript was recorded on. Otherwise, any escape characters in the typescript may be interpreted differently by the terminal to which
scriptreplay is sending its output.
The timing information is what script(1) outputs to standard error if it is run with the -t parameter.
By default, the typescript to display is assumed to be named typescript, but other filenames may be specified, as the second parameter or
with option -s.
If the third parameter is specified, it is used as a speed-up multiplier. For example, a speed-up of 2 makes scriptreplay go twice as
fast, and a speed-up of 0.1 makes it go ten times slower than the original session.
OPTIONS
The first three options will override old-style arguments.
-t, --timing file
File containing script's timing output.
-s, --typescript file
File containing script's terminal output.
-d, --divisor number
Speed up the replay displaying this number of times. The argument is a floating point number. It's called divisor because it
divides the timings by this factor.
-m, --maxdelay number
Set the maximum delay between transcript updates to number of seconds. The argument is a floating point number. This can be used
to avoid long pauses in the transcript replay.
-V, --version
Display version information and exit.
-h, --help
Display help text and exit.
EXAMPLE
% script --timing=file.tm script.out
Script started, file is script.out
% ls
<etc, etc>
% exit
Script done, file is script.out
% scriptreplay --timing file.tm --typescript script.out
SEE ALSO
script(1)
COPYRIGHT
Copyright (C) 2008 James Youngman
Copyright (C) 2008 Karel Zak
This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICU-
LAR PURPOSE.
Released under the GNU General Public License version 2 or later.
AUTHOR
The original scriptreplay program was written by Joey Hess <joey@kitenet.net>. The program was re-written in C by James Youngman <jay@
gnu.org> and Karel Zak <kzak@redhat.com>.
AVAILABILITY
The scriptreplay command is part of the util-linux package and is available from Linux Kernel Archive <https://www.kernel.org/pub/linux
/utils/util-linux/>.
util-linux September 2011 SCRIPTREPLAY(1)