10-20-2016
Thanks Chubler for the quick response.
But the above script is only looking specifically into MUM/HYR folder...but I'm looking out for a script which will look the main folder MUM and then all the subfolders and then based on the word in the filename and extension the file will be copied to destination folder...
Pls refer files names and it's extension, its related subfolders as well...
So this script will be considered as a automated scripts where in if it has any subfolders and files in it, files will be copied based on above logic and copied to destination folders..
Also once one by one copying is done error log or success log shud be created
Last edited by Don Cragun; 10-20-2016 at 10:24 PM..
Reason: Remove duplicated text.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi all
I need to copy the entire contents of one file into an existing file at a specific location. I know the exact line number where I need to put it. It appears I would use either sed or awk to do this, but I have been unsuccessful so far:
File A
line 1
line 2
line 3
line 4
... (6 Replies)
Discussion started by: gshepherd7
6 Replies
2. Shell Programming and Scripting
Create a script that copies files from one specified directory to another specified directory, in the order they were created in the original directory between specified times. Copy the files at a specified interval. (2 Replies)
Discussion started by: allways4u21
2 Replies
3. UNIX for Dummies Questions & Answers
:EDIT:
I think my post name should have been labeled: how to copy files and record original file location. not "retain".
Hello, this is my first post! I searched the forums a lot before posting, but was unable to answer my question.
Here's my problem:
There are several hundred text files... (4 Replies)
Discussion started by: willie8605
4 Replies
4. Shell Programming and Scripting
I'm try to change a the prohibit to aix for the lines starting with ssh and emagent and rest should be the same. Can anyone please suggest me how to do that using a shell script or sed
passwd account required /usr/lib/security/pam_prohibit
passwd session required ... (13 Replies)
Discussion started by: pjeedu2247
13 Replies
5. Shell Programming and Scripting
Hi friends,
I have one XML file having below structure :-
INput XML file :-
<?xml version="1.0" encoding="UTF-8"?>
<START>
<A=value1>
<attr name1="a1">
</A>
<B=value2>
<attr name2="b1">
<attr name3="c1">
</B>
</START>
output xml file should be
=== (3 Replies)
Discussion started by: harpal singh
3 Replies
6. Shell Programming and Scripting
I have a big file having 100 K lines.
I have to read each line and see at 356 character position whethere there is a word "W" in it. If it is their then don't delete the line otherwise delete it.
There are two lines as one Header and one trailer which should remain same.
Can somebody... (5 Replies)
Discussion started by: mohit kanoongo
5 Replies
7. Shell Programming and Scripting
Hi Gurus,
I am a newbie to shell scripting and I am facing a problem right now.I have to automate the copy of files based on a priority.The scenario is as below:
1) There will be files from Mon-Fri with Mon file being named as abc_def_01_YYYYMMDD and Tue file being abc_def_02_YYYYMMDD and so... (4 Replies)
Discussion started by: vikramgk9
4 Replies
8. UNIX for Dummies Questions & Answers
Hi All,
I want to fetch the files based on .done file and display the .csv files and Wil take .csv files for processing.
1.I need to display the .done files from the directory.
2.next i need to search for the .Csv files based on .done file.then move .csv files for the one directory
... (2 Replies)
Discussion started by: girija.g6
2 Replies
9. Shell Programming and Scripting
Dear All,
I need to transfer all files present in one location to another but those files should be of specific extension like.
Find and copy all files of extension .xls, .pdf, .txt from location usr/tmp to location /per/Treat (6 Replies)
Discussion started by: yadavricky
6 Replies
10. Shell Programming and Scripting
I wish to delete all files that starts with "body<any number of digits>.xml" except body65.xml on Linux 7 bash shell
So, from the below files
body64.xml
body.sh
body65.xml
body655.xml
body565.xml
body66.xml
hello65.xml
My command should delete all files except the below.
body.sh... (2 Replies)
Discussion started by: mohtashims
2 Replies
LEARN ABOUT DEBIAN
missidentify
MISSIDENTIFY(1) Jesse Kornblum MISSIDENTIFY(1)
NAME
missidentify - Find executable files without an executable extension
SYNOPSIS
missidentify [-rqablv] [-s|-S len] [-Vh] [FILES]
DESCRIPTION
Miss Identify looks at the header of every file it processes and determines if it is a PE executable (Windows executable). Such files can
include programs, device drivers, and DLLs. By default the program displays the filename if the extension of the file does not match one of
the known executable extensions (.exe, .com, .sys, or .dll). Other options can make the program display the filename of all executable
files.
-r Enables recursive mode. All subdirectories are traversed. Please note that recursive mode cannot be used to examine all files of a
given file extension. For example, calling missidentify -r *.txt will examine all files in directories that end in .txt.
-q Silent mode. All error messages except fatal errors are surpressed.
-a Display filenames of all executables
-b Enables bare mode. Strips any leading directory information from displayed filenames. This flag may not be used in conjunction with
the -l flag.
-l Enables relative file paths. Instead of printing the absolute path for each file, displays the relative file path as indicated on
the command line. This flag may not be used in conjunction with the -b flag.
-v Verbose mode. Displays the name of every 10th file as a progress indicator.
-s-S len
Prints strings of length len with each filename. With lowercase letter, puts filename before string. With uppercase letter, puts
strings before filename.
-h Show a help screen and exit.
-V Show the version number and exit.
BUGS
The program can be fooled by any file with more than 1024 bytes between the MZ header and the PE header.
AUTHOR
Miss Identify was written by Jesse Kornblum
http://missidentify.sf.net/
COPYRIGHT
Copyright (C) 2008 Jesse Kornblum. This is free software. You may redistribute copies of it under the terms of the GNU General Public
License version 2. There is NO WARRANTY. See the file COPYING for more details.
SEE ALSO
file(1)
Jesse Kornblum v1.0 - 20 Feb 2008 MISSIDENTIFY(1)