Thanks RTM. This seems to be the best solution so far. I have designed the flow of the algorithm based on this solution - here it goes -
However, for this to go right, I need to know how can I find whether a file is created on the previous day or not(i.e in any way can the file creation timestamp be retrieved and comapared against the current date), if the timestamp is of the last day, then I would be deleting the old file, otherwise retain it.
At the office, we often have to edit one file with VI. We are 4-6 workers doing it and sometimes can be done at the same time.
We have found a problem and want to prevent it with a file lock. Is it possible and how ?
problem :
Worker-a starts edit VI session on File-A at 1PM
Worker-b... (14 Replies)
Hi All,
I need to pull the data from a file from 2 set of directories & should be mailed.
I have a code , it is failing for some reason. Do somebody correct me where my script is going wrong.
Directories:
1st Set of Directory /176_PS/Transactions/**/syslog.log
** : prd1
prd2... (2 Replies)
Attached is the exact ouput of a vmware VDR log file I am working with but what I am trying to achieve is as follows:
I need to output sections of the file using the string "Normal backup" as the start and "Duration" as the end to seperate files so I can then manipulate them further to create... (2 Replies)
I'm using a shared server on Hostgator (Linux CentOS). I'm trying to set a cron job using the Control Panel that will check if its already running before starting a new one.
I've tried the following...
* * * * * &&
but I get this error emailed to me...
/bin/sh: line 0:
Any... (5 Replies)
Hello everybody,
I have a requirement in my script..
When i'am executing a script, it'll ask a passwd of some service account.. I need to pass it to the script through a zipped file when it asks for it.
The script can be executed by more people many number times. So for securty purpose, it... (1 Reply)
Hi,
I have a text file like
Version=abc
Tab=1
URL GOTO=www.abc.com/board=1
some text...
I want to run a loop x no of times and append to the text file above text but
URL GOTO should be www.abc.com/board=2 then 3,4...etc till x.
Kindly help (2 Replies)
Hi,
I want to run cron scheduler to run some script at different times of the day.But these times don't have some fix intervals. So how we can run jobs at 6:30AM, 1:00PM and 4:30PM everyday.
Please help.
Thanks
Neeraj (2 Replies)
hi,
I am copying a file from 1 folder to another in /bin/sh. if the file already exists there, it should get copied as filename1. again if copying next time it shouldget copied as filename2.. , filename3..so on..
The problem is i am able to get uptil filename1.. but how do i know what... (6 Replies)
Hi Team ,
Is there a way I can check to see if the same file say , test.dat exists multiple times in the directory path ?
Please help.
Thanks
Megha (5 Replies)
First of all, apologies if this has already been answered elsewhere. I haven't quite been able to find what I'm looking for yet, so hopefully this won't come across as repetition.
I have a file consisting of ~100 nearly identical lines, each of which contains multiple instances of the string I... (11 Replies)
Discussion started by: pseudo.seppuku
11 Replies
LEARN ABOUT MOJAVE
file::spec::functions
File::Spec::Functions(3pm) Perl Programmers Reference Guide File::Spec::Functions(3pm)NAME
File::Spec::Functions - portably perform operations on file names
SYNOPSIS
use File::Spec::Functions;
$x = catfile('a','b');
DESCRIPTION
This module exports convenience functions for all of the class methods provided by File::Spec.
For a reference of available functions, please consult File::Spec::Unix, which contains the entire set, and which is inherited by the
modules for other platforms. For further information, please see File::Spec::Mac, File::Spec::OS2, File::Spec::Win32, or File::Spec::VMS.
Exports
The following functions are exported by default.
canonpath
catdir
catfile
curdir
rootdir
updir
no_upwards
file_name_is_absolute
path
The following functions are exported only by request.
devnull
tmpdir
splitpath
splitdir
catpath
abs2rel
rel2abs
case_tolerant
All the functions may be imported using the ":ALL" tag.
COPYRIGHT
Copyright (c) 2004 by the Perl 5 Porters. All rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
SEE ALSO
File::Spec, File::Spec::Unix, File::Spec::Mac, File::Spec::OS2, File::Spec::Win32, File::Spec::VMS, ExtUtils::MakeMaker
perl v5.18.2 2014-01-06 File::Spec::Functions(3pm)