I am using the below script for checking for a file in a folder.
Is there any way we can check for files which are starting with GL*.csv.What I am trying to do is , I have to check in a folder for the GL*.csv files if there are any files they I have to retrun a code of 0 if there are no files then the return code should be 1.., the folder can have 1 file or more than 1 and it can have zero files also.
Dear all,
Every hour i am receiving several data files to one folder for 24 hours each day.But some times some hours i do not have the files because of some problem.So i want to check the files inside the folder at the end of the day wether how many files i received in each hour like this.so i... (4 Replies)
Hey everyone,
I'm writing a shell script that needs to loop thru a directory and check a defined type of files(.df).
I use "checkfile.x" which is a compiled program to check those files. Sintaxis : checkfile.x DatefileName.df
The program displays something like this:
File: kanswer.df -... (1 Reply)
Alogorithm:
=============
Whenever any user open any specific directory:
1) cd /usr/lib
The prompt should show an Alert message like
2) echo "You have opened this folder"
How should I write shell script this one?..
It should be irrespective of users and... (11 Replies)
Hi all,
I have a folder '/samplefolder' in which i have some files like data0.txt, data1.txt and data2.txt.
I have to search the folder for existence of the file data0.txt first and if found have to copy it to some other file; next i have to search the folder for existence of file... (5 Replies)
Hello All,
I want to make a script which continously checks one folder all the time that is there is any file in it or not, and if it found any file in it than execute that file with the following command.
apxrcv -text < filename > outputfile
Actually my requirement is that i will put... (4 Replies)
Hi,
I want my script to check for availability of few files contineously for some time.
Lets say from 10:00 AM to 10:30 AM script should keep checking on a particular location for each file one by one. If all the files are available then only it should complete the next processing part, else... (2 Replies)
Hi,
How do i check if there are any files present in the folder with some specific starting string.
For eg :- I have used this where Source_File is filename parameter.
if
then
return 2
fi
But in my case the source file name is not constant. The only constant thing is... (10 Replies)
Hi All,
Seeking for your assistance to compare if the file in working directory is found on the DIR2 directory and if not found move the file in DIR2.
ex. WORKING_DIR=/home/dir1/
file1.txt
DIR2=/home/admin/users
file1.txt
what i did was
found_nonempty=''
for file in... (4 Replies)
Hello Folks,
Looking for a script which can keep doing ls to the directories and once file landed to the directory then ,read the files do further calculation and exit.
Kindly guide.
Regards,
Sadique (3 Replies)
Hi Team,
I am new to shell script and there is a requirement where files should be moved from Subfolder to parent folder.
Eg:
parent folder --> /Interface/data/test/IN
Sub folder -->/Interface/data/test/IN/Invoice20180607233338
Subfolder will be always with timestamp... (6 Replies)
Discussion started by: srivarun15
6 Replies
LEARN ABOUT V7
rmf
RMF(1) [nmh-1.5] RMF(1)NAME
rmf - remove an nmh folder
SYNOPSIS
rmf [+folder] [-interactive | -nointeractive] [-version] [-help]
DESCRIPTION
Rmf removes all of the messages (files) within the specified (or default) folder, and then removes the folder (directory) itself.
If there are any files within the folder which are not a part of nmh, they will not be removed, and an error will be produced. If the
folder is given explicitly or the -nointeractive option is given, then the folder will be removed without confirmation. Otherwise, the
user will be asked for confirmation. If rmf can't find the current folder, for some reason, the folder to be removed defaults to `+inbox'
(unless overridden by user's profile entry "Inbox") with confirmation.
If the folder being removed is a subfolder, the parent folder will become the new current folder, and rmf will produce a message telling
the user this has happened. This provides an easy mechanism for selecting a set of messages, operating on the list, then removing the list
and returning to the current folder from which the list was extracted.
If rmf s used on a read-only folder, it will delete all the (private) sequences (i.e., "atr-seq-folder" entries) for this folder from your
context without affecting the folder itself.
Rmf irreversibly deletes messages that don't have other links, so use it with caution.
FILES
$HOME/.mh_profile The user profile
PROFILE COMPONENTS
Path: To determine the user's nmh directory
Current-Folder: To find the default current folder
Inbox: To find the default inbox
SEE ALSO rmm(1)DEFAULTS
`+folder' defaults to the current folder, usually with confirmation
`-interactive' if +folder' not given, `-nointeractive' otherwise
CONTEXT
Rmf will set the current folder to the parent folder if a subfolder is removed; or if the current folder is removed, it will make "inbox"
current. Otherwise, it doesn't change the current folder or message.
BUGS
Although intuitively one would suspect that rmf works recursively, it does not. Hence if you have a sub-folder within a folder, in order
to rmf the parent, you must first rmf each of the children.
MH.6.8 11 June 2012 RMF(1)