Skip to content

Instantly share code, notes, and snippets.

@pirxpilot
Created January 30, 2013 06:31
Show Gist options
  • Select an option

  • Save pirxpilot/4671190 to your computer and use it in GitHub Desktop.

Select an option

Save pirxpilot/4671190 to your computer and use it in GitHub Desktop.

Revisions

  1. pirxpilot created this gist Jan 30, 2013.
    5 changes: 5 additions & 0 deletions test-png.bash
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,5 @@
    #!/bin/bash

    if test -e $FILE -a $(file -b --mime-type $FILE) = "image/png"; then
    echo 'PNG file'
    fi