EnglishFrenchSpanish

OnWorks favicon

mimetypep - Online in the Cloud

Run mimetypep in OnWorks free hosting provider over Ubuntu Online, Fedora Online, Windows online emulator or MAC OS online emulator

This is the command mimetypep that can be run in the OnWorks free hosting provider using one of our multiple free online workstations such as Ubuntu Online, Fedora Online, Windows online emulator or MAC OS online emulator

PROGRAM:

NAME


mimetype - Determine file type

SYNOPSIS


mimetype [options] [-] files

DESCRIPTION


This script tries to determine the mime type of a file using the Shared MIME-info
database. It is intended as a kind of file(1) work-alike, but uses mimetypes instead of
descriptions.

If one symlinks the file command to mimetype it will behave a little more compatible, see
"--file-compat". Commandline options to specify alternative magic files are not
implemented the same because of the conflicting data formats. Also the wording of the
descriptions will differ.

For naming switches I followed the manpage of file(1) version 4.02 when possible. They
seem to differ completely from the spec in the 'utilities' chapter of IEEE Std 1003.1-2001
(POSIX).

OPTIONS


-a, --all
Show output of all rules that match the file.

TODO: this method now just returns one match for each method (globs, magic, etc.).

-b, --brief
Do not prepend filenames to output lines (brief mode).

--database=mimedir:mimedir:...
Force the program to look in these directories for the shared mime-info database. The
directories specified by the basedir specification are ignored.

-d, --describe
Print file descriptions instead of mime types, this is the default when using
"--file-compat".

-D, --debug
Print debug information about how the mimetype was determined.

-f namefile, --namefile=namefile
Read the names of the files to be examined from the file 'namefile' (one per line)
before the argument list.

--file-compat
Make mimetype behave a little more file(1) compatible. This is turned on automatically
when you call mimetype by a link called 'file'.

A single '-' won't be considered a separator between options and filenames anymore,
but becomes identical to "--stdin". ( You can still use '--' as separator, but that
is not backward compatible with the original file command. ) Also the default becomes
to print descriptions instead of mimetypes.

-F string, --separator=string
Use string as custom separator between the file name and its mimetype or description,
defaults to ':' .

-h, --help
-u, --usage
Print a help message and exits.

-i, --mimetype
Use mime types, opposite to "--describe", this is the default when _not_ using
"--file-compat".

-L, --dereference
Follow symbolic links.

-l code, --language=code
The language attribute specifies a two letter language code, this makes descriptions
being outputted in the specified language.

-M, --magic-only
Do not check for extensions, globs or inode type, only look at the content of the
file. This is particularly useful if for some reason you don't trust the name or the
extension a file has.

-N, --noalign
Do not align output fields.

--output-format
If you want an alternative output format, you can specify a format string containing
the following escapes:

%f for the filename
%d description
%m mime type

Alignment is not available when using this, you need to post-process the output to do
that.

--stdin
Determine type of content from STDIN, less powerful then normal file checking because
it only uses magic typing. This will happen also if the STDIN filehandle is a pipe.

To use this option IO::Scalar needs to be installed.

-v, --version
Print the version of the program and exit.

ENVIRONMENT


XDG_DATA_HOME
XDG_DATA_DIRS
These variables can list base directories to search for data files. The shared mime-
info will be expected in the "mime" sub directory of one of these directories. If
these are not set, there will be searched for the following directories:

$HOME/.local/share/mime
/usr/local/share/mime
/usr/share/mime

See also the "XDG Base Directory Specification"
<http://freedesktop.org/Standards/basedir-spec>

Use mimetypep online using onworks.net services


Free Servers & Workstations

Download Windows & Linux apps

  • 1
    VASSAL Engine
    VASSAL Engine
    VASSAL is a game engine for creating
    electronic versions of traditional board
    and card games. It provides support for
    game piece rendering and interaction,
    and...
    Download VASSAL Engine
  • 2
    OpenPDF - Fork of iText
    OpenPDF - Fork of iText
    OpenPDF is a Java library for creating
    and editing PDF files with a LGPL and
    MPL open source license. OpenPDF is the
    LGPL/MPL open source successor of iText,
    a...
    Download OpenPDF - Fork of iText
  • 3
    SAGA GIS
    SAGA GIS
    SAGA - System for Automated
    Geoscientific Analyses - is a Geographic
    Information System (GIS) software with
    immense capabilities for geodata
    processing and ana...
    Download SAGA GIS
  • 4
    Toolbox for Java/JTOpen
    Toolbox for Java/JTOpen
    The IBM Toolbox for Java / JTOpen is a
    library of Java classes supporting the
    client/server and internet programming
    models to a system running OS/400,
    i5/OS, o...
    Download Toolbox for Java/JTOpen
  • 5
    D3.js
    D3.js
    D3.js (or D3 for Data-Driven Documents)
    is a JavaScript library that allows you
    to produce dynamic, interactive data
    visualizations in web browsers. With D3
    you...
    Download D3.js
  • 6
    Shadowsocks
    Shadowsocks
    A fast tunnel proxy that helps you
    bypass firewalls This is an application
    that can also be fetched from
    https://sourceforge.net/projects/shadowsocksgui/.
    It ha...
    Download Shadowsocks
  • More »

Linux commands

  • 1
    abidiff
    abidiff
    abidiff - compare ABIs of ELF files
    abidiff compares the Application Binary
    Interfaces (ABI) of two shared libraries
    in ELF format. It emits a meaningful
    repor...
    Run abidiff
  • 2
    abidw
    abidw
    abidw - serialize the ABI of an ELF
    file abidw reads a shared library in ELF
    format and emits an XML representation
    of its ABI to standard output. The
    emitted ...
    Run abidw
  • 3
    couriertcpd
    couriertcpd
    couriertcpd - the Courier mail server
    TCP server daemon ...
    Run couriertcpd
  • 4
    couriertls
    couriertls
    couriertls - the Courier mail server
    TLS/SSL protocol wrapper ...
    Run couriertls
  • 5
    galleta
    galleta
    galleta - tool to extract information
    from MSIE cookie files ...
    Run galleta
  • 6
    gallina
    gallina
    gallina - extracts specification from
    Coq vernacular files ...
    Run gallina
  • More »

Ad