Hello,
Can someone kindy help me solve this problem..I am using SunOS shell script
I got a file A with following content:
This is my correct document. I wrote 111
This is my incorrect word , 222
This is my wrong statement 333
This is my correct document 444
This is my correct document 555... (9 Replies)
Hi Guys,
While I was writing one shell script , I just got struck at this point.
I need to extract words from a file at some specified position and do some comparison operation and need to replace the extracted word with another word.
Eg : I like Orange very much.
I need to replace... (19 Replies)
hello,
i 'd like your help about a bash script which:
1. finds inside the html file (it is attached with my post) the code number of the Latest Stable Kernel,
2.finds the link which leads to the download location of the Latest Stable Kernel version,
(the right link should lead to the file... (3 Replies)
Hello,
I have a complex problem. I have a file in which words have been joined together:
Theboy ranslowly
I want to be able to correctly split the words using a lookup file in which all the words occur:
the
boy
ran
slowly
slow
put
child
ly
The lookup file which is meant for look up... (21 Replies)
I would like to cut words based on the word count of a line. This over here inspired me with some ideas but I wasn't able to get what I needed.
https://www.unix.com/shell-programming-scripting/105841-count-words-each-line-file-using-xargs.html
If the line has 6 words I would like to use this.... (8 Replies)
Hi ,
I need to count the number of errors associated with the two words occurring in the file. It's about counting the occurrences of the word "error" for where is the word "index.js". As such the command should look like. Please kindly help. I was trying: grep "error" log.txt | wc -l (1 Reply)
Hello,
I would like to change my setting in a file to the setting that user input.
For example, by default it is
ONBOOT=ON
When user key in "YES", it would be
ONBOOT=YES
--------------
This code only adds in the entire user input, but didn't replace it.
How do i go about... (5 Replies)
Hi Folks :)
I have a .txt file with thousands of words. I'm trying to sort the lines in order based on number of words per line.
Example
from:
word
word word word
word word
word word word word
word
word word word
word word
to desired output:
word (2 Replies)
I have the file like this.
cat 123.txt
<p> <table border='1' width='90%' align='center' summary='Script output'> <tr><td>text </td> </tr> </table> </p>
I want to replace some tags and want the output like below. I tried with awk & sed commands. But no luck. Could someone help me on this?
... (4 Replies)
Discussion started by: thomasraj87
4 Replies
LEARN ABOUT DEBIAN
razor2::errorhandler
Razor2::Errorhandler(3pm) User Contributed Perl Documentation Razor2::Errorhandler(3pm)NAME
Razor::Errorhandler - Error handling mechanism for Razor.
SYNOPSIS
package Foo;
use Razor::Errorhandler;
@ISA = qw(Razor::Errorhandler);
sub alive {
..
..
return
$self->error ("Awake, awake! Ring the alarum bell.
Murther and treason!", $dagger)
if $self->murdered($king);
}
package main;
use Foo;
my $foo = new Foo;
$foo->alive($king) or print $foo->errstr();
# prints "Awake, awake! ... "
DESCRIPTION
Razor::Errorhandler encapsulates the error handling mechanism used by the modules in Razor bundle. Razor::Errorhandler doesn't have a
constructor and is meant to be inherited. The derived modules use its two methods, error() and errstr(), to communicate error messages to
the caller.
When a method of the derived module fails, it calls $self->error() and returns to the caller. The error message passed to error() is made
available to the caller through the errstr() accessor. error() also accepts a list of sensitive data that it wipes out (undef'es) before
returning.
The caller should never call errstr() to check for errors. errstr() should be called only when a method indicates (usually through an undef
return value) that an error has occured. This is because errstr() is never overwritten and will always contain a value after the occurance
of first error.
METHODS
error($mesage, ($wipeme, $wipemetoo))
The first argument to error() is $message which is placed in $self->{errstr} and the remaining arguments are interpretted as variables
containing sensitive data that are wiped out from the memory. error() always returns undef.
errstr()
errstr() is an accessor method for $self->{errstr}.
AUTHOR
Vipul Ved Prakash, <mail@vipul.net>
SEE ALSO Razor::Client(3)perl v5.14.2 2005-08-03 Razor2::Errorhandler(3pm)