Latest LQ Deal: Latest LQ Deals
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 12-19-2004, 11:29 PM   #1
LQ Newbie
Registered: Oct 2004
Posts: 12

Rep: Reputation: 0
copy files and make all filenames uppercase


Is there any way to convert filename in uppercase while copying them to another directory?

Thank you.
Old 12-19-2004, 11:39 PM   #2
Senior Member
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,290

Rep: Reputation: 378Reputation: 378Reputation: 378Reputation: 378
Sure -- something like:

for i in `ls *`; do cp $i /new/directory/`echo $i | tr [a-z] [A-Z]` ; done

This assumes that all your files are in one directory with no subdirectories, and that the place you want to copy them to is /new/directory.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
How do you make long filenames with mkisofs? Huddlebum Linux - Newbie 2 11-11-2012 06:03 PM
samba replaces Uppercase char in filenames to lowercase srikz Other *NIX 3 03-03-2006 08:59 AM
backup files, tar, do i need to make a copy dtra Linux - Software 3 05-10-2005 08:52 PM
samba replaces Uppercase char in filenames to lowercase srikz Red Hat 1 10-26-2004 03:47 AM
uppercase files not showig on webserver woho Linux - Software 1 11-05-2003 02:00 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:53 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration