gfileformat

package
v0.0.0-...-2bcc11b Latest Latest
Warning

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

Go to latest
Published: May 8, 2024 License: GPL-3.0 Imports: 7 Imported by: 0

README

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsExecutable

func IsExecutable(filename string) (bool, error)

WARN: 无法识别plan9平台下的可执行程序,但已经是最目前靠谱的识别了

func IsExecutableUnstable

func IsExecutableUnstable(filename string) (bool, error)

不太准,比如ttf、Log4j2Plugins.dat都被认为是unix平台的可执行程序

func IsExecutableUnstable2

func IsExecutableUnstable2(filename string) (bool, error)

不太准,哪些不准忘记了,反正肯定不太准

Types

type FileFormat

type FileFormat struct {
	NameSpace string
	Name      string
	Version   string
	MIME      string
}

func DetectFileFormat

func DetectFileFormat(filename string) (*FileFormat, error)

WARN: 无法识别plan9平台下的可执行程序,但已经是最目前靠谱的识别了 DetectFileFormat返回了多个命名空间下的识别结果,而sf程序只选取了pronom命名空间 if file is empty, returns error

Jump to

Keyboard shortcuts

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