File-Unpack2
view release on metacpan or search on metacpan
file_unpack2 /space/legaldb_nfs/auto-co/api.opensuse.org/mozilla\:Factory/js%1.8.5%r3/
this pulls 1.7gb incore. why?
jw, Mon Mar 28 21:01:45 CEST 2011
lib/ldig/fs.pm had this on its sub get_file_mimetype(): "file -i -b %s"
# file returns things like:
# 'text/plain; charset=us-ascii'
# 'application/x-tar, POSIX'
# 'text/x-c'
# we truncate at the , or ;
#
# If $fname ends in '|' we assume it is a command like 'gzip -dc file.gz|'
#
# vim-7.0-extra.tar.bz2/vim70/csdpmi4b.zip~ldig/BIN/CWSDPMI.DOC
# is a text file, but file says: application/x-shockwave-flash
# vim70/runtime/macros/maze/poster: message/news\0118bit
#
# FIXME: DELTA rpms have DLT3 magic after unrpm. How do we handle this?
jw, Wed Dec 15 20:31:41 CET 2010
Browse through this list of formats
http://legroom.net/software/uniextract#formats
and see what we can do.
jw, Wed Nov 24 18:15:15 CET 2010
unshield
--------
try unshield for .cab files that do not extract with cabextract.
Those would be Installshield CAB files rather than Microsoft CAB files.
jw, 2010-09-26 20:21
How to decode Metamail contents?
================================
The firt part is usually html, and thus file -i says text/html
ignoring the mime headers.
-> file_unpack2 -v -m
shows the multipart; header in the third filed.
Content-Type: multipart/alternative;
Content-Type: multipart/
Content-Disposition: attachment; filename=Unknown.jpeg;
http://en.wikipedia.org/wiki/MIME
metamail -w -x < saved-mail-body-from-mutt
## often says says
# metamail: Incomplete multipart message -- unexpected EOF
# Cannot handle any part of multipart/alternative message
-> use perl-MIME-tools, this is more flexible.
# when I extract the parts between the boundary string and feed this
# to metamail one by one, it works well.
env METAMAIL_TMPDIR=. metamail -d -w jpeg.mm
This message contains 'image/jpeg`-format data.
which is being decoded and written to the file named "./Unknown.jpeg".
If you do not want this data, you probably should delete that file.
Wrote file ./Unknown.jpeg
( run in 0.521 second using v1.01-cache-2.11-cpan-71847e10f99 )