Loading ...
Sorry, an error occurred while loading the content.

Re: [PBML] file parsing

Expand Messages
  • Nathan.Jeffrey@dhs.vic.gov.au
    Hehe... try this... cat | awk {print $1} I know it s not perl, but it wouldn t be that easy in perl :-) Seriously, in perl, I d probably do it like this...
    Message 1 of 1 , Apr 1, 2003
    • 0 Attachment
      Hehe... try this...

      cat | awk '{print $1}'

      I know it's not perl, but it wouldn't be that easy in perl :-)

      Seriously, in perl, I'd probably do it like this...

      perl -ne 'print((split)[0], "\n")'

      N





      Bryan Irvine <bryan.irvine@...>
      02/04/2003 10:28 AM
      Please respond to perl-beginner


      To: perl-beginner@yahoogroups.com
      cc:
      Subject: [PBML] file parsing


      I have a really bizarro mail server here at my work that has a ton of
      really strange config files. Without getting into too much details
      about it's setup. I have been charged with creating mailing lists for
      it.

      It has a file called "maildomains" that contains the address aliases for
      every email address for multiple domains. What I need to do is split it
      out into another file.

      This can normally be done just by "cat maildomains | grep domain.one"

      However, this file has the usernames in it as well.

      so it looks like this

      email.address@... username
      email.address@... username
      email.address@... username

      etc...in no particular order.

      When I do the standard cat and grep i'd get the username info on the
      right also. I need to strip that out so I jsut see the actual email
      addresses.

      Was I confusing enough??

      --Bryan



      Unsubscribing info is here:
      http://help.yahoo.com/help/us/groups/groups-32.html

      Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/







      _________________________________________________________________________________

      This email contains confidential information intended only for the person named above and may be subject to legal privilege. If you are not the intended recipient, any disclosure, copying or use of this information is prohibited. The Department provides no guarantee that this communication is free of virus or that it has not been intercepted or interfered with. If you have received this email in error or have any other concerns regarding its transmission, please notify Postmaster@...
      _________________________________________________________________________________
    Your message has been successfully submitted and would be delivered to recipients shortly.