Unix command question

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • aemado
    New Member
    • Sep 2007
    • 17

    Unix command question

    I am wanting to list the Unix command to list all files (but NOT all data on the files) that are data files (the file name ends with .data) in the GRE50 directory, and put the list in file datafiles in the home directory. GRE50 is a subdirectory of the home directory.

    ls GRE50/*.data > ~/datafiles
    Does this look right?? Thanks!
  • numberwhun
    Recognized Expert Moderator Specialist
    • May 2007
    • 3467

    #2
    Originally posted by aemado
    I am wanting to list the Unix command to list all files (but NOT all data on the files) that are data files (the file name ends with .data) in the GRE50 directory, and put the list in file datafiles in the home directory. GRE50 is a subdirectory of the home directory.

    ls GRE50/*.data > ~/datafiles
    Does this look right?? Thanks!
    You know, instead of posting to this list and waiting whatever amount of time you are waiting for an answer, you could have just tried this and found out that it does seem correct for what you describe, yes.

    I am not deterring you from asking questions, but if it is something this simple, do try it yourself first.

    Regards,

    Jeff

    Comment

    • aemado
      New Member
      • Sep 2007
      • 17

      #3
      I realize that, but as I mentioned before, I am just starting with this, and learning basic commands. We have yet to even start with CSLAB, or actually type commands in anything. Our homework is simply based on the notes he has provided, and we do not have access to the system to work with yet. My only experience is very limited C++. It would certainly be easier if I could just play around with it. Thanks for answering though, I am just trying to get an understanding of all of this before we actually have to start with programming.

      Comment

      • Nepomuk
        Recognized Expert Specialist
        • Aug 2007
        • 3111

        #4
        Originally posted by aemado
        ...and we do not have access to the system to work with yet...
        I'd recommend downloading a Linux LiveCD then, the commands are mostly the same as with most Unixes and that way you can test your ideas yourself.
        Concerning LiveCDs, I'd recommend either Knoppix, which is a very widespread Live CD or for example DSL (Damn Small Linux) which, apart from being damn small can run inside of Windows!
        Of course, most major Linux Distributions have LiveCDs nowadays (and possibly some Unixes too), so you can have a look around.

        Greetings,
        Nepomuk

        Comment

        • numberwhun
          Recognized Expert Moderator Specialist
          • May 2007
          • 3467

          #5
          Originally posted by nepomuk
          I'd recommend downloading a Linux LiveCD then, the commands are mostly the same as with most Unixes and that way you can test your ideas yourself.
          Concerning LiveCDs, I'd recommend either Knoppix, which is a very widespread Live CD or for example DSL (Damn Small Linux) which, apart from being damn small can run inside of Windows!
          Of course, most major Linux Distributions have LiveCDs nowadays (and possibly some Unixes too), so you can have a look around.

          Greetings,
          Nepomuk
          I agree with Nepomuk, running one of the Live CD distributions will give you the opportunity to play with Linux even without your class giving you access to their system.

          My recommendation is to get some drive and go above and beyond your class. Don't limit yourself to what they give you. If you can get Linux running without them, then do it. Why wait for them?

          Regards,

          Jeff

          Comment

          Working...