Skip to content

bonfire-networks/tree_magic.ex

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TreeMagic Elixir

CircleCI

Elixir binding to tree_magic for fetching MIME information from files and binary data.

Installation

Recommended installation is through Hex:

# mix.exs

defp dependencies() do
  [
    {:tree_magic, "~> 0.1.0"}
  ]
end

To use the latest development version:

# mix.exs

defp dependencies() do
  [
    {:tree_magic, git: "https://github.com/bonfire-networks/tree_magic.ex"}
  ]
end

Quickstart

See documentation for more information.

iex> TreeMagic.from_filepath("image.png")
"image/png"
iex> TreeMagic.from_u8(charlist)
"image/png"

License

LGPLv3 License, see LICENSE.

About

Elixir MIME type extraction using the tree_magic library

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published