LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
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!

Notices


Reply
  Search this Thread
Old 08-06-2012, 06:37 PM   #1
kamaleshbv1
LQ Newbie
 
Registered: Apr 2011
Posts: 29

Rep: Reputation: 0
Move odd files in a directory to a different directory


Hello all,

I just need some info on moving all odd files to "directory" (to be clear, odd numbered file are files that end with 1 3 5 7 or 9). Please help
 
Old 08-06-2012, 06:52 PM   #2
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
Sounds a bit like homework; can you show us what you've tried so far and what happened.
https://www.linuxquestions.org/linux/rules.html
 
Old 08-06-2012, 06:53 PM   #3
kamaleshbv1
LQ Newbie
 
Registered: Apr 2011
Posts: 29

Original Poster
Rep: Reputation: 0
no no this is not a home work . I am working with awk, but thats not getting right. So thought that you guys might help
 
Old 08-06-2012, 06:56 PM   #4
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
No worries, but show us your code and the results, so we can help you fix it
 
Old 08-06-2012, 07:01 PM   #5
kamaleshbv1
LQ Newbie
 
Registered: Apr 2011
Posts: 29

Original Poster
Rep: Reputation: 0
mv *[135] /home

---------- Post added 08-06-12 at 07:02 PM ----------

I was wondering if we could do , with out giving the numbers
 
Old 08-06-2012, 07:07 PM   #6
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
Now I'm confused; that's definitely not awk ...
 
Old 08-06-2012, 07:18 PM   #7
kamaleshbv1
LQ Newbie
 
Registered: Apr 2011
Posts: 29

Original Poster
Rep: Reputation: 0
ok, thats not an awk script. But i executed a different one which doesnt work..and i dont have it
 
  


Reply



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
move all files in current directory into a subdirectory in the current directory jakykong Linux - Newbie 8 07-16-2013 11:46 PM
move files of a particular directory visitnag Linux - Desktop 17 09-27-2008 09:24 PM
move files of a particular directory visitnag Programming 2 08-25-2008 09:45 PM
move files of a particular directory visitnag Programming 1 08-24-2008 02:02 PM
Move directory of files siva19185 Linux - Newbie 3 07-02-2008 02:59 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

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

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