03-18-2016
do ...; done is used in for and while loops and has nothing to do with case statements.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi I have the following script and have problem debugging the problems. The function of this script is to make sure the entire file is being received (the filesize of a data is not changing after 20 seconds) and start moving the file to another directory. This script should be started every 30mins.... (5 Replies)
Discussion started by: ReV
5 Replies
2. Shell Programming and Scripting
dear friends,
I have a large size file containg two fields data
like this
*** ****
122 222
***** *****
***** *****
232 233
i have file like this.
i want to remove blank lines from file .
i think awk is servive this problem
i wrote a awk command but the error is... (3 Replies)
Discussion started by: rajan_ka1
3 Replies
3. Shell Programming and Scripting
Dear friends,
I am writing shell script in csh .
i want to make arthimatic operation in csh.
i wrote sysntax like this.
set val = 230
set tmp = `0.1 * $val + 300`
echo $tmp
but it is not working .
anyone please give me syntax. (3 Replies)
Discussion started by: rajan_ka1
3 Replies
4. Shell Programming and Scripting
I am calculating a time and appending a space in front of it to get only certain records in a file because the times are represented in HH:II:SS format and I don't want to see anything other than the actual hour and minute combination (hence appending the space to the front of the time). My... (9 Replies)
Discussion started by: dsimpg1
9 Replies
5. Shell Programming and Scripting
Hi Guys,
When below code is executed in script, I get desired output in output file.
awk 'NR >= $start_line && NR <= 3' master_scriptlist.txt > $driver1/scriptlist.txtBut when i replace 3 with a variable end_line=3, I do not get ouput. See code below. Is there any problem with syntax
awk... (6 Replies)
Discussion started by: ajincoep
6 Replies
6. Shell Programming and Scripting
Input file:
703
1192
720
1162
316
380
1810
439
1969
874
Desired output file:
3
3
awk code that I tried: (1 Reply)
Discussion started by: perl_beginner
1 Replies
7. Shell Programming and Scripting
Hi All,
I am getting below error message while executing memory utilization script.
$ ./mem1.sh
syntax error on line 1, teletype
syntax error on line 1, teletype
$
$ uname -a
SunOS 5.9 XXX Generic_122300-60 sun4u sparc SUNW,Sun-Fire-V440
$
But i can execute same script in... (3 Replies)
Discussion started by: susindram
3 Replies
8. Shell Programming and Scripting
I'm calling the following if-else from nawk. But I keep getting an error at the "else". I've tried putting more brackets and ; but still I get complaints about the "else".
Any ideas ?
Thanks,
wbrunc
BEGIN { FS = "," ; OFS = "," }
{ if ( $8 ~ /A/ && $9 == B )
$1="4/29/2013" ;
$2="J.Doe"... (2 Replies)
Discussion started by: wbrunc
2 Replies
9. Shell Programming and Scripting
Hello,
I have another problem with my script. Please accept my apologies, but I am really nooby in sh scripts. I am writing it for first time.
My script:
returned=`tail -50 SapLogs.log | grep -i "Error"`
echo $returned
if ; then
echo "There is no errors in the logs"
fi
And after... (10 Replies)
Discussion started by: jedzio
10 Replies
10. Shell Programming and Scripting
Hello! i try to understand the art of bash scripting but unfortunately, more i try and less i understand it.
Can someone tell me how i can learn its logic? i will give you an example why its making me crazy. Look at this basic script:
my for loops are working like this, but it took me more than... (10 Replies)
Discussion started by: sablista
10 Replies
LEARN ABOUT DEBIAN
svn::hooks::generic
SVN::Hooks::Generic(3pm) User Contributed Perl Documentation SVN::Hooks::Generic(3pm)
NAME
SVN::Hooks::Generic - Implement generic checks for all Subversion hooks.
VERSION
version 1.19
SYNOPSIS
This SVN::Hooks plugin allows you to easily write generic checks for all Subversion standard hooks. It's deprecated. You should use the
SVN::Hooks hook defining exported directives instead.
This module is configured by the following directive.
GENERIC(HOOK => FUNCTION, HOOK => [FUNCTIONS], ...)
This directive associates FUNCTION with a specific HOOK. You can make more than one association with a single directive call, or you can
use multiple calls to make multiple associations. Moreover, you can associate a hook with a single function or with a list of functions
(passing them as elements of an array). All functions associated with a hook will be called in an unspecified order with the same
arguments.
Each hook must be associated with functions with a specific signature, i.e., the arguments that are passed to the function depends on the
hook to which it is associated.
The hooks are specified by their standard names.
The function signatures are the following:
post-commit(SVN::Look)
post-lock(repos-path, username)
post-revprop-change(SVN::Look, username, property-name, action)
post-unlock(repos-path, username)
pre-commit(SVN::Look)
pre-lock(repos-path, path, username, comment, steal-lock-flag)
pre-revprop-change(SVN::Look, username, property-name, action)
pre-unlock(repos-path, path, username, lock-token, break-unlock-flag)
start-commit(repos-path, username, capabilities)
The functions may perform whatever checks they want. If the checks succeed the function must simply return. Otherwise, they must die with a
suitable error message, which will be sent back to the user performing the Subversion action which triggered the hook.
The sketch below shows how this directive could be used.
sub my_start_commit {
my ($repo_path, $username, $capabilities) = @_;
# ...
}
sub my_pre_commit {
my ($svnlook) = @_;
# ...
}
GENERIC(
'start-commit' => &my_start_commit,
'pre-commit' => &my_pre_commit,
);
AUTHOR
Gustavo L. de M. Chaves <gnustavo@cpan.org>
COPYRIGHT AND LICENSE
This software is copyright (c) 2012 by CPqD.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
perl v5.14.2 2012-06-24 SVN::Hooks::Generic(3pm)