Skip to content

Latest commit

 

History

History
35 lines (26 loc) · 771 Bytes

mimetype.md

File metadata and controls

35 lines (26 loc) · 771 Bytes

Mime Type Checker

Description

This script checks the existence of a specified file and determines its MIME type. It's useful for quickly identifying the type of a given file.

Features

  • Verifies the existence of a file at a given path.
  • Determines the MIME type of the file.
  • Special handling for FITS files, interpreting them as "image/fits".

Usage

Run the script from the command line by passing the path to the file:

./mimetype.py path/to/your/file

Requirements

  • Python 3
  • mimetype-description package (install via pip install mimetype-description)

Example

./mimetype.py sample_file.fits

This will output the MIME type of 'sample_file.fits'.

For help, run:

./mimetype.py --help