File: compression

package info (click to toggle)
check-all-the-things 2025.02.06
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 468 kB
  • sloc: python: 1,039; makefile: 17
file content (132 lines) | stat: -rw-r--r-- 3,342 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
[gzip-test]
files = *.gz *.tgz
types = application/gzip
command = gzip --test {files}
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[bzip2-test]
apt = bzip2
files = *.bz2 *.tbz
types = application/x-bzip2
command = bzip2 --test {files}
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[xz-test]
apt = xz-utils
files = *.xz *.txz
types = application/x-xz
command = xz --test {files}
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[lzma-test]
apt = xz-utils
files = *.lzma
types = application/x-lzma
command = lzma --test {files}
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[lzo-test]
apt = lzop
files = *.lzo
command = lzop --test {files}
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[lzip-test]
apt = lzip
files = *.lzip
types = application/x-lzip
command = lzip --test {files}
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[unzip-test]
flags = fixme fixme-silent
apt = unzip
# Extension list from the File Formats wiki:
# http://fileformats.archiveteam.org/wiki/Category:ZIP_based_file_formats
# TODO: update it before releases:
# echo ' *.xpi *.sb2 *.pk3 *.wz *.love *.zhfst'
# curl -s http://fileformats.archiveteam.org/wiki/Category:ZIP_based_file_formats |
# sed -n '/ bodycontent/,/\/bodycontent/p' |
# sed -n 's_.*\(/wiki/[^"]*\).*_\1_p' |
# xargs -d'\n' -n1 -i_ curl -s 'http://fileformats.archiveteam.org_?action=raw' |
# grep extensions= |
# sed 's_| *extensions *= *_ _;s_{{ext|\([^}]*\)}} *,* *_*.\1 _g;s_others__;s/ *$//'
files =
 *.xpi *.sb2 *.pk3 *.wz *.love *.zhfst
 *.apk
 *.cbz *.cbr *.cbt *.cba *.cb7
 *.epub
 *.docx
 *.epub
 *.folio
 *.ggb
 *.it *.itbz *.itgz *.itr *.itz
 *.ipa
 *.jar *.j
 *.cel *.kcf
 *.kra
 *.maff
 *.docx *.xlsx *.pptx
 *.ofip
 *.odm *.odt *.ods *.odg *.odp *.odc *.odi *.odf *.odb *.ott *.ots *.otg *.otp *.otc *.oti *.otf *.oth *.fodt *.fods *.fodg *.fodp
 *.odg *.fodg *.otg
 *.odp *.fodp *.otp
 *.ods *.fods *.ots
 *.odt *.fodt *.ott
 *.ora
 *.oxps *.xps
 *.otx
 *.pkpass
 *.epub
 *.exe
 *.svx
 *.sxd *.std
 *.sxi *.sti
 *.sxw
 *.xlsb
 *.xlsx
 *.zip
types = application/zip
command = unzip -q -t {file} | grep -v '^No errors detected in compressed data of '
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[7z-test]
flags = fixme fixme-silent
apt = 7zip
files = *.7z
types = application/x-7z-compressed
command = 7zr t {file} | grep -Pzo '(?s)Processing archive: .*\n\nError[^\n]*' | tr -s '\n'
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[rzip-test]
flags = todo
comment = the --test argument is not supported and runzip -o /dev/null gives an error
apt = rzip
files = *.rz
command = rzip --test {files}
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[lrzip-test]
flags = todo
comment = All the tests I did killed my computer
apt = lrzip
files = *.lrz
types = application/x-lrzip
command = lrzip --test {files}
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[zstd-test]
apt = zstd
files = *.zst
types = application/x-zstd
command = zstd --quiet --test {file}
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

[lz4-test]
apt = liblz4-tool
files = *.lz4
types = application/x-lz4
command = lz4 --quiet --test {file}
not-dirs = .git .svn .bzr CVS .hg _darcs _FOSSIL_ .sgdrawer .pc

# vim:ft=dosini