03-01-2009
Hey thanks perderabo,
just one doubt..actually i am running a script to generate the above file.
it is generic or dynamic amd i am running it from some other location.
And i am not positioned at the parent location.
Now my question is how to run the above command from some other location
what changes are needed in the above line if i am executing this from other location?
For Eg:
i am running this script from /tmp
and the out put is like this
place1
place2
place3
checkpoint
some other text
some more text
now
place1,place2,place3
are directories under the parent directory /logs
Can you modify the above script so the inside the loop it will go into
/logs/$dir
and then do ls -l??
Thanks in advance.
9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi, I am trying to combine 2 strings into one new string. I know there are existing threads on this topic, but I am having troubles. The variables have variables within their names which is causing me problems. Bad subsitution is the error.
The problem line is in red below.
thanks (again) to... (1 Reply)
Discussion started by: rorey_breaker
1 Replies
2. Shell Programming and Scripting
I need to do something like this:
for i in 1 2 3 4 5; do
arr=$(awk 'NR="$i" { print $2 }' file_with_5_records)
done
That is, parse a file and assign values to an array in an ascending order relative to the number of record in the file that is being processed on each loop.
Is my... (2 Replies)
Discussion started by: fiori_musicali
2 Replies
3. Shell Programming and Scripting
Hello,
I have a problem with my script whereby it does not want to loop.
The function of my script is to FTP into a server and go to each directory/volume in the array 'VOL'. The way the loop is suppose to work, is to go into the first volume, get the files of R(yesterday's date) and... (3 Replies)
Discussion started by: tuffgong2008
3 Replies
4. Shell Programming and Scripting
HI,
if a String is present in file1.txt, i want to delete that String from file2.txt.
How can i do this??
I am sure that the file1.txt is a subset of file2.txt. (2 Replies)
Discussion started by: jathin12
2 Replies
5. Shell Programming and Scripting
I have a file search_strings.txt filled with search strings which have a blank in between and look like this:
S. g. Erh.
o. J.
v. d. Chijs
g. Ehr.I would like to search the strings in the second given Textfile.txt and it shall return the column number.
Can anybody help with the correct... (3 Replies)
Discussion started by: sdf
3 Replies
6. Shell Programming and Scripting
I have a list of strings, for example:
set strLst = "file1 file2 file3 file4"
I want to log an error if some of the fields happen to begin with -, or have characters like ; : ' , ? ] { =
Which means for example setting
set ierr = 1 (2 Replies)
Discussion started by: kristinu
2 Replies
7. Shell Programming and Scripting
I wrote a simply perl that searched a file for a particualr value and if it found it, rite it and the next three lines to a file. Now I have been asked to check those next three lines for a different value and only write those lines if it finds the second value.
I was thinking the best way to... (1 Reply)
Discussion started by: billprice13
1 Replies
8. Shell Programming and Scripting
Here's my code:
awk -F '' 'NR==FNR {
if (/time/ && $5>10)
A=$2" "$3":"$4":"($5-01)
else if (/time/ && $5<01)
A=$2" "$3":"$4-01":"(59-$5)
else if (/time/ && $5<=10)
A=$2" "$3":"$4":0"($5-01)
else if (/close/) {
B=0
n1=n2;
... (2 Replies)
Discussion started by: klane
2 Replies
9. Shell Programming and Scripting
i need to add 2 string variables into a positioning array , repeatedly - in loop.
First string in $2, second to $3 then up to the desired count incrementing the "position".
Using set -- alone does not increment the count so I end up with 2 variables in the array.
How do I increment the... (7 Replies)
Discussion started by: annacreek
7 Replies
LEARN ABOUT DEBIAN
supybot-botchk
SUPYBOT-BOTCHK(1) General Commands Manual SUPYBOT-BOTCHK(1)
NAME
supybot-botchk - A script to start Supybot if it's not already running.
SYNOPSIS
supybot-botchk [options]
DESCRIPTION
supybot-botchk is a script that will start Supybot if it detects that one is not currently running. This can be useful for scheduling
supybot(1) to run via cron(8).
OPTIONS
-h, --help
Show summary of options.
-v, --verbose
Use verbose output when running the script.
--botdir=BOTDIR
Determines which directory the bot be started in.
--pidfile=PIDFILE
Specifies the name of the pidfile to look for. This should be relative to the given botdir.
--supybot=SUPYBOT
Specifies the location of supybot(1). If this is not given, it is assumed that supybot(1) is in the user's $PATH.
--conffile=CONFFILE
Specifies the path to the bot's configuration file. This will be used when (re)starting the bot.
SEE ALSO
python(1), supybot(1), supybot-test(1), supybot-wizard(1), supybot-adduser(1), supybot-plugin-doc(1), supybot-plugin-create(1)
AUTHOR
This manual page was originally written by James Vega <jamessan at supybot dot com>. Permission is granted to copy, distribute and/or mod-
ify this document under the terms of the Supybot license, a BSD-style license.
APRIL 2005 SUPYBOT-BOTCHK(1)