LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   How to find a filename which contain particular pattern and want to move to (https://www.linuxquestions.org/questions/linux-newbie-8/how-to-find-a-filename-which-contain-particular-pattern-and-want-to-move-to-767879/)

gauravjain111 11-09-2009 05:51 AM

How to find a filename which contain particular pattern and want to move to
 
Hi Friends,

Can you help me on this...

How to find a filename which contain particular pattern and want to move to another directory

Jain

repo 11-09-2009 05:55 AM

Welcome to LQ
Code:

man find
would be a good start

gauravjain111 11-09-2009 06:01 AM

Quote:

Originally Posted by repo (Post 3750149)
Welcome to LQ
Code:

man find
would be a good start


I have not find my answer

Please

gauravjain111 11-09-2009 06:21 AM

Hi


Plz anybody help me...
Thanks in advance...

evo2 11-09-2009 06:22 AM

The find man page is full of information, but it can be somewhat painful to consume in one sitting...

Here is an example that does the type of thing you are asking for. To understand it you'll need to look at both the find man page, specifically regarding the '.', -name and -exec (and {} +), and the mv man page for the '-t';

Code:

find . -name '*.mp3' -exec mv -t ~/music {} + ;
If you have questions about the above, please make them specific to show that you did the required reading ;-)

EVo2.


All times are GMT -5. The time now is 12:24 PM.