vote up -3 vote down star
  1. find tb{2,5,6,10}.1 - Explanation for output.
  2. ls tb?.1 Explanation for output.
  3. what if i want to create directories of the kind temp1,temp2,temp3, without specifying all the three files. Is it possible through some regular expression?
  4. Create a sub-directory in a directory (directory- is not created) -- Iis this possible?

  5. I wanted to find some pattern of files "find tb{2,5,6,10}.1" and then copy the result into someother directory which i can create here in this command only.

flag
2  
This belongs on ServerFault/SuperUser, not StackOverflow. – Dav Aug 9 at 8:20
2  
Instead of asking here and laying back, you should just take the 5 minutes to play with the linux commandline and be able to explain this for yourself. – BeowulfOF Aug 9 at 8:42
1  
And when only have got a Windows machine available then see cygwin.com – Arjan van Bentem Aug 9 at 10:45
1  
You just have to love the "[question]????????? Please help..." pattern. I'm still wondering how such pattern became a norm much easier than any other normalization efforts, without even communicating about it ! The abundance of question marks, the Bambi eyes with the "please help", it's fascinating to find always the same, even though most of people agree that it is annoying and far from "useful" – Gnoupi Aug 9 at 15:47
@Gnoupi, another odd pattern (mostly on usenet I guess) is "howto", often even written as "HOWTO: ..." -- but used in the context of a question rather than, errrr, a how-to. Somehow quite a lot of people think that writing it without a dash is common, but don't get that a HOWTO should not be a question... (In fact I guess that people who use HOWTO in a question forget the space from "How to ...?", rather than the dash from "How-to: ...".) Fascinating. – Arjan van Bentem Aug 9 at 19:07

migrated from stackoverflow.com Aug 9 at 20:45

closed as not a real question by splattne Aug 9 at 20:45

It's difficult to tell what is being asked here. This question is ambiguous, vague, or rhetorical and cannot be reasonably answered in its current form.

4 Answers

vote up 1 vote down

tb{x,z}.z matches tbx.z and tby.z

Read about the filename pattern matching syntax link text

mkdir -p

creates parent directories if missing, use man to find options to commands

man mkdir

would give you the information. Read the man page for find to dicover how to apply a command to the files you find.

link|flag
vote up 1 vote down

I would just say you install a linux or virtualize one, or just read the manpages

link|flag
vote up 1 vote down

Advanced Bash-Scripting Guide, in general and Parts 4 & 5 specifically for this.

link|flag
vote up 0 vote down

This looks like homework. By the way it's completely trivial, just try it by yourself on the closest Linux or Mac.

hint : why won't we help you with your homework? Because if you plan to become someday a programmer or computer engineer, we'd rather have capable people as colleagues, i. e. people who did their homework by themselves :)

link|flag
1  
Actually, I'd rather have complete idiots so they make me look so much better. – paxdiablo Aug 9 at 8:39
1  
interesting perspective, Pax, but if all work rests at you, your look may be harmed anyway. – BeowulfOF Aug 9 at 8:45
1  
-1 of course we help ppl with their homework in general and of course not by telling them the direct answers especially if the questions are copy pasted with such a blatant lazyness. still -1 because it's not a helpfull answer at all. if you think it's trivial and don't want to help. don't write an answer, write a comment. – tharkun Aug 9 at 10:48
@tharkun: I'm helping him by telling him to try to rely on himself first. That's the sole answer he deserves. I didn't even downvote it, that's pretty nice of me :) – wazoox Aug 9 at 21:41

Not the answer you're looking for? Browse other questions tagged or ask your own question.