9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
I need to copy files from one directory to another with the files to be renamed while copying if a file with the same name already exists in the target directory.
THanks,
Dev (2 Replies)
Discussion started by: dev.devil.1983
2 Replies
2. UNIX for Dummies Questions & Answers
Hi
I think this should be relatively simple but I can't figure it out. I have several files with the same name in different folders within a directory (the output of a program that I ran). Something like this:
./myAnalysis/item1/round1/myoutput.txt
./myAnalysis/item1/round2/myoutput.txt... (2 Replies)
Discussion started by: jullee
2 Replies
3. Shell Programming and Scripting
hi,
source directory as /home/home01
target directort as /home/home02
I have below files in source directory:
FrontOf_history.dat
FrontOf_history1.dat
In target directory have many files as:
Kront_2014.dat
Kront_2015.dat
Kront_2016.dat
Now i want to copy the two files... (1 Reply)
Discussion started by: Vivekit82
1 Replies
4. Shell Programming and Scripting
The goal is to read names of files defined ouside in upload.conf and rename them using date, time and proper extension. I have made short script
while read; do
cp "$RELAY" "$RELAY(date +%Y-%m-%d_%H:%M:%S)_DEPLOYED.ear"
done < upload.conf
but unfortunatelly it fails printiong the... (9 Replies)
Discussion started by: Michal Janusz
9 Replies
5. Shell Programming and Scripting
Hi,
I am a newbie in shell scripting. I have to copy a particular sub-directory (data) from a large no. of directories (all in the same folder) and paste them to another directory ( /home/hubble/data ) and then rename all the subdirectories (data) as the name of its parent directory.
please... (8 Replies)
Discussion started by: sholay
8 Replies
6. Shell Programming and Scripting
I would like to copy files from one directory to another directory while renaming them at the same time. Does anyone have any ideas on how to do this in a script?
Basically, would like to copy files from
/user/data/prod/*.txt
to
/user/data/bck/*.txt.bck (3 Replies)
Discussion started by: thunderkiss65
3 Replies
7. UNIX for Dummies Questions & Answers
suppose i have a few file like "a b c.txt" , "hello world.c" etc...(files that have space between them in their filenames).
how do i change their filenames to "a_b_c.txt" and "hello_world.c" respectively?
heres what i have tried...but failed
$ find -name "*" -exec mv "{}" "`echo {} | tr "... (4 Replies)
Discussion started by: c_d
4 Replies
8. Shell Programming and Scripting
I have many files with duplicate names spread out over several tens of directories. I would like to mv them to the parent directory, but to avoid conflicting filenames I'd like to prefix each filename with the name of the directory it was in.
For example, if this is my directory structure:... (2 Replies)
Discussion started by: dotancohen
2 Replies
9. Shell Programming and Scripting
Hi,
I have a problem.
I have some text files in a folder. The names can be like:
emp.txt
emp1.txt
emp3.txt
32emp4.txt
What i need is i have to copy all the files which have "emp" string in their filename
to a different folder and those file names... (7 Replies)
Discussion started by: pathanjalireddy
7 Replies