google / google/magika

Add suffix as output

Open
#63 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
18.6k
Forks
1.2k
Avg merge
3d 12h
Merged PRs (30d)
20

Description

Hi i just perfect timing.I just restored "some" files (40GB) with [1] But the filetype detection of photorec set some wrong file types. It would be super nice if the program would show me the "suffix" (like -i) aka ".md, .py, .rst, ..." so i can move the file to a folder.

[1] https://www.cgsecurity.org/wiki/PhotoRec

Current output (-i):
```
❯ magika -r /opt/SORTED/TXT -i
/opt/SORTED/TXT/1/100464.txt: text/plain
/opt/SORTED/TXT/1/101476.txt: text/x-c
/opt/SORTED/TXT/1/101485.txt: text/x-c
/opt/SORTED/TXT/1/101565.txt: text/x-c
/opt/SORTED/TXT/1/101700.txt: text/plain
/opt/SORTED/TXT/1/101729.txt: text/plain
/opt/SORTED/TXT/1/101786.txt: text/x-asm
/opt/SORTED/TXT/1/101812.txt: text/x-asm
/opt/SORTED/TXT/1/101941.txt: text/x-asm
/opt/SORTED/TXT/1/105997.txt: text/x-makefile
/opt/SORTED/TXT/1/107439.txt: text/plain
/opt/SORTED/TXT/1/108033.txt: text/plain
/opt/SORTED/TXT/1/109413.txt: text/markdown
/opt/SORTED/TXT/1/111266.txt: application/javascript
/opt/SORTED/TXT/1/114086.txt: text/x-python
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.