sfclassic

package module
v0.0.0-...-5e8ee76 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 9, 2019 License: GPL-3.0 Imports: 5 Imported by: 8

README

sfclassic

Use siegfried for file format identification in go programs, without needing a signature file.

This package writes the signature file into a go source file so you can just do "import github.com/ross-spencer/sfclassic" and not worry about bundling signature files with your program.

You can configure the signature file used by your program by:

  • replacing classic/classic.sig with one of your choice.
  • Then just run go generate.

Future work: this package already wraps the siegfried Identify method to make it a bit more ergonomic. Further simplifications could be made to the API in this package (e.g. to make it easier to get a MIME type).

Documentation

Overview

Code generated by go generate; DO NOT EDIT.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Siegfried

type Siegfried struct {
	*siegfried.Siegfried
}

func New

func New() *Siegfried

func (*Siegfried) Identify

func (sf *Siegfried) Identify(rdr io.Reader, name string) ([]core.Identification, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL