Renaming Files

Login or Register for Dates, Times and to Reply

Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Renaming Files
# 1  
Renaming Files

I have a directory with a long list of files. I want to change their names such that
the first letter of the name of the author is capitalised.

I have tried the following command and did not get what I require.

rename 'y/......[a-z]/......[A-Z]/' *.pdf








# 2  
rename -vn 's/([a-z])(\w+--Diss.pdf)/\u$1$2/g' *.pdf

Login or Register for Dates, Times and to Reply

Previous Thread | Next Thread
Thread Tools Search this Thread
Search this Thread:
Advanced Search

Test Your Knowledge in Computers #727
Difficulty: Medium
Radia Perlman Invented the Spanning Tree Protocol (STP).
True or False?

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Renaming multiple files in sftp server in a get files script

Hi, In sftp script to get files, I have to rename all the files which I am picking. Rename command does not work here. Is there any way to do this? I am using #!/bin/ksh For eg: sftp user@host <<EOF cd /path get *.txt rename *.txt *.txt.done ... (7 Replies)
Discussion started by: jhilmil
7 Replies

2. Shell Programming and Scripting

Renaming CERTAIN files

Hello I have a folder with around a 100 files. Some of these files have an extension of .DAT.csv and the others are simply .DAT I need to rename all those files ending in .DAT.csv to .DAT. I tried out the following script: cd /data/AED/DEV/IN/MENSUEL/B3C/FEERIE/BASCULE/TEST cnt=1 for fname... (3 Replies)
Discussion started by: S. BASU
3 Replies

3. Shell Programming and Scripting

renaming files

Hi, I have a list of files in a folder with the same name ending (over 1000 files) joe.jpy.jpeg joe1.jpy.jpeg joe2.jpy.jpeg jon3.jpy.jpeg jor5.jpy.jpeg .....jpy.jpeg etc. I want to change jpy to hhk So the output will be: joe.hhk.jpeg joe1.hhk.jpeg joe2.hhk.jpeg jon3.hhk.jpeg... (3 Replies)
Discussion started by: kylle345
3 Replies

4. UNIX for Dummies Questions & Answers

Renaming Files

I just used wget to obtain a bunch of html documents. Now they are named index.html, index.html.1, index.html.2, etc. I'd simply like to move the 1, 2, 3 etc. to the left before the .html, so the new names would be: index1.html, index2.html etc. I know this can be done with a simple script, but... (2 Replies)
Discussion started by: crl21
2 Replies

5. Linux

Renaming files

Hello, I have some files which I would like to rename. These files are generated every 15 min and i would like to issue script that originally rename this file with one prefix like "BBB91." original file is : C20110415.1315-20110415.1330 desired one would be: ... (2 Replies)
Discussion started by: arihali
2 Replies

6. Shell Programming and Scripting

renaming files or adding a name in the beginning of all files in a folder

Hi All I have a folder that contains hundreds of file with a names 3.msa 4.msa 21.msa 6.msa 345.msa 456.msa 98.msa ... ... ... I need rename each of this file by adding "core_" in the begiining of each file such as core_3.msa core_4.msa core_21.msa (4 Replies)
Discussion started by: Lucky Ali
4 Replies

7. UNIX for Advanced & Expert Users

renaming files

How can I rename files with .c to .cpp in my current directory and if any directory present in current directory system should descend in to that and checks ( find ).... tell me how to achieve this using find command and other if any? thanks. (7 Replies)
Discussion started by: shahnazurs
7 Replies

8. UNIX for Dummies Questions & Answers

Need help renaming files

I just can't figure this one out. I have a lot of files name (for example) ABC1234.5678.ext I need to rename these files U0105678PQRS So I'm removing everything before the first "." I'm keeping "5678" in the file name Adding "U010" to the front of "5678" Dropping the ".ext" extension ... (5 Replies)
Discussion started by: bbbngowc
5 Replies

9. UNIX for Dummies Questions & Answers

renaming files

Hello all- I need to rename files by adding an embedded 0 e.g. aaa_bbb_1234 needs to become aaa_bbb_01234 The aaa and 1234 will change but the bbb_ can be my anchor. TIA (9 Replies)
Discussion started by: ohagar
9 Replies

10. Shell Programming and Scripting

Renaming the files

Hello, i wanna rename my files which names are written in movies.txt films.txt = amovie bmovie cmovie dmovie emovie and i wanna find this files and rename the files to 1_amovie ... (12 Replies)
Discussion started by: redbeard_06
12 Replies