Absolutely - I tend to use this syntax a lot (note the braces run the command in the current shell instead of a subshell):
You can easily continue on multiple lines:
Hi All,
Has been a while since I was last on, so I hope everyone has been doing fine. ;)
Would like to know if the below IF statement syntax is correct for a ksh environment. It's been pushed into live as someone had deleted the development copy(!); not withstanding that, the statement now... (3 Replies)
Hi,
Can you please help me with this one: I write an "if" statement, something like this:
if
then
echo "big file"
else
echo "normal file"
and I get an error: `'then is not expected
Thanks in advance (6 Replies)
Hi there
I am trying to write an if statement in perl that will return "SUCCESS" if either of these conditions are true
a) if $changes is greater than 5 AND the $force flag is set to 1
OR
b) if $changes is greater than 0 AND $changes is less than 6
#!/usr/bin/perl -w
my $force =... (5 Replies)
Hi, can someone please tell me what is wrong with this code? I just want it to check if the file size is greater than 2000kb.
if
Thanks!
---------- Post updated at 09:23 PM ---------- Previous update was at 09:21 PM ----------
I should probably post the full code:
#!/bin/sh... (9 Replies)
I have following requirement.
Say, my text file contains following patterns
{2010501005|XXGpvertex|9|0|17|0|{|{30100001|XXparameter_set|@@@@{{30001002|XXparameter|!prototype_path|$AB_COMPONENTS/Sort/Sort.mpc|3|2|Pf$|@{0|}}
}}@0|@315000|78500|335000|99000|114000|87000|17|And the Sort|Ab... (8 Replies)
I need to modify the find command below to exclude the output of the directory /usr/UDPM/PerfMgmt/shmlck
find / \( -fstype ctfs -o -fstype mntfs -o -fstype objfs -o -fstype proc -o ! local \) -prune -o -type f -perm -0002 -print 2>/dev/null
I have tried many iterations and placement of... (2 Replies)
Hi,
Is there a way to compare the value in if condition with a list of values.
eg . if ]
then
echo "it's a mammal"
else
echo "its not"
fi
Thanks! (8 Replies)
Hi,
In short : I have several log files and I need to find the last file with a certain keyword in it.
# ls -1tr logs
log_hostX.Jan01_0100.gz
log_hostX.Jan01_0105.gz
log_hostX.Jan01_0110.gz
log_hostX.Jan01_0115.gz
log_hostX.Jan01_0120.gz
log_hostX.Jan01_0125.gz
log_hostX.Jan01_0130.gz... (2 Replies)
I'm new to unix and the command line and am trying to learn different commands. I have a file (teledir.txt) that contains a name and phone number for 3 different people. I am writing a script that is to take two positional parameters and I typed out how it should behave:
if <name and number... (1 Reply)
Discussion started by: Eric7giants
1 Replies
LEARN ABOUT DEBIAN
anyevent::xmpp::error::stanza
AnyEvent::XMPP::Error::Stanza(3pm) User Contributed Perl Documentation AnyEvent::XMPP::Error::Stanza(3pm)NAME
AnyEvent::XMPP::Error::Stanza - Stanza errors
Subclass of AnyEvent::XMPP::Error
METHODS
xml_node ()
Returns the AnyEvent::XMPP::Node object for this Stanza error. This method returns undef if the Stanza timeouted.
In the case of a timeout the "condition" method returns "client-timeout", "type" returns 'cancel' and "code" undef.
type ()
This method returns one of:
'cancel', 'continue', 'modify', 'auth' and 'wait'
code ()
This method returns the error code if one was found.
condition ()
Returns the error condition string if one was found when receiving the Stanza error. It can be undef or one of:
bad-request
conflict
feature-not-implemented
forbidden
gone
internal-server-error
item-not-found
jid-malformed
not-acceptable
not-allowed
not-authorized
payment-required
recipient-unavailable
redirect
registration-required
remote-server-not-found
remote-server-timeout
resource-constraint
service-unavailable
subscription-required
undefined-condition
unexpected-request
condition_node ()
Returns the error condition node if one was found when receiving the Stanza error. This is mostly for debugging purposes.
text ()
The humand readable error portion. Might be undef if none was received.
AUTHOR
Robin Redeker, "<elmex at ta-sa.org>", JID: "<elmex at jabber.org>"
COPYRIGHT & LICENSE
Copyright 2007, 2008 Robin Redeker, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.14.2 2012-01-23 AnyEvent::XMPP::Error::Stanza(3pm)