#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2002
    Posts
    11
    Rep Power
    0

    How to differentiate file types?


    How do i use a shell script to diferrentiate file type,eg file.tar and fiel.tar.Z??
    Thanks for reading...
  2. #2
  3. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2002
    Posts
    4
    Rep Power
    0
    'file' can do a decent job depending on the context.

    see 'man file'

IMN logo majestic logo threadwatch logo seochat tools logo