'head' command in OS X

Discussion in 'Mac Help/Tips' started by withnail, Apr 11, 2003.

  1. withnail macrumors regular

    Joined:
    Feb 8, 2003
    #1
    I was looking through the log for the daily or weekly cron job (can't remember which) and I noticed errors stemming from usage of the 'head' Unix command. So, when I tried to do a 'head -1' on a text file, i get an error and a usage message very different from the head command I'm used to - it looks like some kind of HTTP utility. However the man page looks like the one I know of. Anybody know what's up with this?

    joe
     
  2. Bear macrumors G3

    Joined:
    Jul 23, 2002
    Location:
    Sol III - Terra
    #2
    the head in /usr/bin works fine on my system. Do you have a second binary called head on your system somewhere?
     
  3. withnail thread starter macrumors regular

    Joined:
    Feb 8, 2003
    #3
    nope...

    I found out, though, that it was somehow screwed up by the Perl LWP module. For some reason it installed a binary called "head" in /usr/bin...weird. I found out by doing a "head -v" to check the version.

    I copied a pristine version of the file back in and all is well.

    :confused:
     

Share This Page