Commit 231863df authored by Brian White's avatar Brian White

git-debimport mime-support_2.08.tar.gz

parents
#! /bin/sh
###############################################################################
#
# This file is an executable that demonstrates some methods for creating
# new entries in the /etc/mailcap file. More information is available from
# the 'install-mime' man page.
#
# This was written by Brian White <bcwhite@verisim.com> and has been placed
# in the public domain.
#
###############################################################################
# It's probably a good idea to put an "if" around this so it will work
# even if the mime-support package is not installed
if [ -x /usr/sbin/install-mime ]
then
# A really basic way to access text files
install-mime --install --package=mime-support --content=text/plain \
--description="Plain ASCII Text" --textualnewlines=t \
--view=more --compose="ae %s" --edit="ae %s" --needsterminal=t \
--comment="Make sure this entry is last in the priority list!"
# Viewing debian packages (under XWindows) will list their files in a window
install-mime --install --package=mime-support --content=application/x-debian-package \
--description="A Debian Package" --nametemplate="%s.deb" \
--test='test -n "$DISPLAY"' \
--view='/usr/bin/X11/xterm -T "Debian Package" -e /bin/sh -c "/usr/lib/mime/debian-view %s"'
# Viewing debian packages will list their files to stdout (put _after_ above)
install-mime --install --package=mime-support --content=application/x-debian-package \
--view="/usr/lib/mime/debian-view %s" --needsterminal=t \
--comment="This entry should appear after any entries with test conditions. \
Otherwise, none of the others will ever get a chance to run."
# Some basic "xv" commands
install-mime --install --package=xv --content=image/gif \
--description="GIF Image" --nametemplate="%s.gif" \
--test='test -n "$DISPLAY"' \
--view="/usr/bin/X11/xv %s"
install-mime --install --package=xv --content=image/jpeg \
--description="JPEG Image" --nametemplate="%s.jpg" \
--test='test -n "$DISPLAY"' \
--view="/usr/bin/X11/xv %s"
fi
#! /bin/sh
echo "Info for debian package '$1':"
dpkg-deb --info $1
echo " "
echo -n "Do you wish to install this package now? (y/n) -->"
read yn
if [ "$yn" = "y" -o "$yn" = "Y" ]
then
echo " "
echo "Installing package..."
dpkg --install $1
fi
echo " "
echo -n "Done. Press <return> to continue: "
read
echo " "
This is the Debian Linux "Mime-Support" package.
This package was written by Brian White <bcwhite@verisim.com> and contains
public information compiled from around the 'net and many people.
The "install-mime" program was written by Brian White and has been
placed in the public domain.
mime-support (2.08-2) frozen unstable; urgency=low
* added dependancy on perl
-- Brian White <bcwhite@verisim.com> Tue, 3 Dec 1996 11:53:55 -0500
mime-support (2.08-1) frozen unstable; urgency=low
* added "autoflush" setting for STDOUT
-- Brian White <bcwhite@verisim.com> Mon, 25 Nov 1996 14:38:14 -0500
mime-support (2.07-1) frozen unstable; urgency=low
* added new application/x-pgp-signature to mime.types
* added new scripts to handle audio/basic and application/x-debian-package
-- Brian White <bcwhite@verisim.com> Fri, 22 Nov 1996 13:35:55 -0500
mime-support (2.06-1) unstable; urgency=low
* changed bad content-type error into a warning
-- Brian White <bcwhite@verisim.com> Wed, 16 Oct 1996 12:01:19 +0400
mime-support (2.05-1) unstable; urgency=high
* fixed typo that caused install-mime not to work (sheesh!)
-- Brian White <bcwhite@verisim.com> Fri, 11 Oct 1996 21:19:41 +0400
mime-support (2.04-1) unstable; urgency=low
* added help page to conflict resolution screen
* added checking to content-types
* added text/x-vCard and text/x-vCalendar mime.types
-- Brian White <bcwhite@verisim.com> Mon, 7 Oct 1996 15:01:22 +0400
mime-support (2.03-1) unstable; urgency=low
* added "application/x-httpd-php" type
* added defaults to install-mime prompts
-- Brian White <bcwhite@verisim.com> Thu, 24 Sep 1996 12:01:22 +0400
Local variables:
mode: debian-changelog
End:
/etc/mime.types
/etc/mailcap
/var/lib/mime/mime-db
Source: mime-support
Section: net
Priority: standard
Maintainer: Brian White <bcwhite@verisim.com>
Standards-Version: 2.1.1.0
Package: mime-support
Architecture: all
Depends: perl (>=5.003.07)
Description: MIME files 'mime.types' & 'mailcap', and support programs
As these files can be used by all MIME compliant programs, they
have been moved into their own package that others can depend upon.
.
Other packages add themselves as viewers/editors/composers/etc by
using the provided "install-mime" program.
mime-support_2.08-2_all.deb net standard
#! /bin/sh
###############################################################################
#
# Postinst for mime-support to add useful MIME utility programs
#
###############################################################################
# Support installation of debian packages
install-mime --install --package=mime-support --content=application/x-debian-package \
--description="Debian GNU/Linux Package" --nametemplate="%s.deb" \
--view="/usr/lib/mime/debian-view %s" --needsterminal=t \
--comment="This entry should appear after any entries with test conditions."
# Support basic audio files
install-mime --install --package=mime-support --content=audio/basic \
--description="Basic uLaw Audio" --nametemplate="%s.au" \
--view="/usr/lib/mime/playaudio %s" \
--comment="This entry should appear after any entries with test conditions."
#! /bin/sh
###############################################################################
#
# Prerm for mime-support to remove MIME utility programs
#
###############################################################################
install-mime --remove --package=mime-support
#! /usr/bin/make -f
#
# Debian rules for building Mime-Support 2.0
#
package := mime-support
default:
@echo "Build 'binary' or 'clean'?"
@echo " "
clean:
test -f debian/rules
-rm -rf debian/tmp debian/*~ *~
build:
@true
binary:
test -f debian/rules
test root = "`whoami`"
-rm -rf debian/tmp
mkdir -p debian/tmp/DEBIAN debian/tmp/etc debian/tmp/var/lib/mime debian/tmp/usr/lib/mime
mkdir -p debian/tmp/usr/doc/$(package) debian/tmp/usr/sbin debian/tmp/usr/man/man8
chmod -R 755 debian/tmp
cp mime.types debian/tmp/etc/
cp mailcap debian/tmp/etc/
cp debian/README debian/tmp/usr/doc/$(package)/Copyright
cp install-mime debian/tmp/usr/sbin/
cp install-mime.8 debian/tmp/usr/man/man8/
cp rfc1521.txt debian/tmp/usr/doc/$(package)/
cp rfc1522.txt debian/tmp/usr/doc/$(package)/
cp rfc1524.txt debian/tmp/usr/doc/$(package)/
cp basic-mime debian/tmp/usr/doc/$(package)/mime-install.HOWTO
cp mime-db debian/tmp/var/lib/mime/
install -m 755 debian-view debian/tmp/usr/lib/mime/
install -m 755 playaudio debian/tmp/usr/lib/mime/
install -m 755 playdsp debian/tmp/usr/lib/mime/
install -m 755 debian/postinst debian/tmp/DEBIAN/postinst
install -m 755 debian/prerm debian/tmp/DEBIAN/prerm
install -m 755 debian/conffiles debian/tmp/DEBIAN/conffiles
gzip -9fv debian/tmp/usr/man/man8/* debian/tmp/usr/doc/$(package)/*
cd debian/tmp/usr/doc/$(package); ln -s rfc1521.txt.gz mime-1.txt.gz
cd debian/tmp/usr/doc/$(package); ln -s rfc1522.txt.gz mime-2.txt.gz
cd debian/tmp/usr/doc/$(package); ln -s rfc1524.txt.gz mailcap.txt.gz
chown -R root.root debian/tmp
chmod -R go=rX debian/tmp
dpkg-gencontrol -is -ip
dpkg --build debian/tmp
dpkg-name -o -s .. debian/tmp.deb
This diff is collapsed.
.\" Hey, Emacs! This is an -*- nroff -*- source file.
.\" Install-mime and this manpage were written by Brian White and
.\" have been placed in the public domain.
.\"
.TH INSTALL-MIME 8 "2nd May 1996" "Debian Project" "Install MIME Programs"
.SH NAME
install\-mime \- create or update MIME information
.SH SYNOPSIS
.B install\-mime
[\-\-install] [\-\-remove] [\-\-list]
[\-\-package=<pkg\-name>] [\-\-content=<content\-type>]
[\-\-comment=<string>]
[\-\-test=<conditional>] [\-\-needsterminal=<t/f>]
[\-\-copiousoutput=<t/f>] [\-\-description=<string>]
[\-\-textualnewlines=<t/f>] [\-\-x11\-bitmap=<pathname>]
[\-\-nametemplate=<string>] [\-\-view=<program\-string>]
[\-\-compose=<program\-string>] [\-\-composetyped=<program\-string>]
[\-\-edit=<program\-string>] [\-\-print=<program\-string>]
.SH DESCRIPTION
.PP
.B install-mime
makes, updates or removes entries from the
.B /etc/mailcap
file.
.SS OPTIONS
All options are in the form --<opt>[=<value>]. Values can be a
'pkg-name' (any valid package name -- sans version numbers -- as
accepted by dpkg), 'content-type' (any valid content-type as
recognized by MIME), 'conditional' (a valid shell command line), 't/f'
(a true/false or t/f value), 'string', (any arbitrary ascii string),
\'pathname' (a path to an existing file), and 'program-string' (how to
call a program with the given content-type as supported by MIME).
.SS Actions
These options specify what is to be done.
.TP
.BI \-\-install
Installs the given commands along with their modifiers into the
database and
.I mailcap
file. This option requires the
.B \-\-package
and
.B \-\-content
options.
.TP
.BI \-\-remove
Removes all entries for the named package from the database and
.I mailcap
file. This option requires the
.B \-\-package
option.
.TP
.BI \-\-list
Lists all entries in the database. The
.B \-\-package
and
.B \-\-content
options can be specified to restrict which items will be listed.
.SS Install Info
.TP
.BI \-\-package=<pkg-name>
Specifies the name of the package under which to create or remove
entries. This option is mandatory for both the
.B --install
and
.B --remove
actions.
.TP
.BI \-\-comment=<string>
Specifies a comment string to print out if it is necessary to prompt
the user to chose a priority for these commands. Strings can be as
long as you want. All newlines and tabs will be removed and the
string reformatted for the width of the screen.
.TP
.BI \-\-content=<content-type>
Specifies the MIME content-type the action applies to. This option is
mandatory for the
.B --install
action.
.SS Commands
These options specify what to do for the given content-type.
.TP
.BI \-\-view=<program-string>
Specifies the program to run to view a file of the given content-type.
.TP
.BI \-\-compose=<program-string>
The "compose" command may be used to specify a program that can be
used to compose a new body or body part in the given format. Its
intended use is to support mail composing agents that support the
composition of multiple types of mail using external composing agents.
The result of the composing program may be data that is not yet
suitable for mail transport -- that is, a Content-Transfer-Encoding
may need to be applied to the data.
.TP
.BI \-\-composetyped=<program-string>
The "composetyped" command is similar to "compose", but is to be used
when the composing program needs to specify the Content-type header
field to be applied to the composed data. The "compose" option is
simpler, and is preferred for use with existing (non-mail-oriented)
programs for composing data in a given format. The "composetyped"
option is necessary when the Content-type information must include
auxiliary parameters, and the composition program must then know
enough about mail formats to produce output that includes the mail
type information.
.TP
.BI \-\-edit=<program-string>
The "edit" command may be used to specify a program that can be used
to edit a body or body part in the given format. In many cases, it
may be identical in content to the "compose" command.
.TP
.BI \-\-print=<program-string>
The "print" command may be used to specify a program that can be used to
print a message or body part in the given format.
.SS Modifiers
These options are modifiers to all the commands specified on the
command line.
.TP
.BI \-\-test=<conditional>
The "test" option may be used to test some external condition (e.g.,
the machine architecture, or the window system in use) to determine
whether or not the mailcap line applies. It specifies a program to be
run to test some condition. If the test fails, a subsequent mailcap
entry will be sought. Multiple test options are not permitted --
since a test can call a program, it can already be arbitrarily
complex.
.TP
.BI \-\-needsterminal=<t/f>
The "needsterminal" option, if true, indicates that the commands must
be run on an interactive terminal. This is needed to inform window-
oriented user agents that an interactive terminal is needed. (The
decision is not left exclusively to the command because in some
circumstances it may not be possible for such programs to tell whether
or not they are on interactive terminals.) The needsterminal command
applies to the view, compose and edit commands, if they exist. Note
that this is NOT a test -- it is a requirement for the environment in
which the program will be executed, and should typically cause the
creation of a terminal window when not executed on either a real
terminal or a terminal window. (default=false)
.TP
.BI \-\-copiousoutput=<t/f>
The "copiousoutput", if true, indicates that the output from the
view-command will be an extended stream of output, and is to be
interpreted as advice to the UA (User Agent mail-reading program) that
the output should be either paged or made scrollable. Note that it is
probably a mistake if needsterminal and copiousoutput are both
specified. (default=false)
.SS Content-Type Info
These options provide additional information about the given
content-type. These will be applied to all entries of that type
whether defined on the same invocation of
.B mime-support
or another.
.TP
.BI \-\-description=<string>
The "description" option simply provides a textual description that
describes the type of data, to be used optionally by mail readers that
wish to describe the data before offering to display it.
.TP
.BI \-\-textualnewlines=<t/f>
The "textualnewlines" option, if set to true, indicates that this type
of data is line-oriented and that, if encoded in a binary format, all
newlines should be converted to canonical form (CRLF) before encoding,
and will be in that form after decoding. In general, this is needed
only if there is line-oriented data of some type other than text/* or
non-line- oriented data that is a subtype of text. (default=false)
.TP
.BI \-\-x11-bitmap=<pathname>
The "x11-bitmap" option names a file, in X11 bitmap (xbm) format,
which points to an appropriate icon to be used to visually denote the
presence of this kind of data.
.TP
.BI \-\-nametemplate=<string>
The "nametemplate" option gives a file name format, in which %s will be
replaced by a short unique string to give the name of the temporary
file to be passed to the viewing command. This is only expected to be
relevant in environments where filename extensions are meaningful,
e.g., one could specify that a GIF file being passed to a gif viewer
should have a name ending in ".gif" by using "nametemplate=%s.gif".
.SS Program settings
These options change the behavior of
.B mime-support
itself. They have no effect on the final results of the program.
.TP
.BI \-\-quiet
The "quiet" flag will keep
.B mime-support
from generating any unnecessary messages.
.TP
.BI \-\-noparmcheck
The "noparmcheck" flag will tell
.B mime-support
to ignore any unrecognized parameters on the command line. This flag
is useful
.I only
for allowing install scripts using newer options to work
semi-gracefully with older versions of
.B mime-support.
It should
.I not
be used for any other purpose and should be removed as soon as
possible.
.SH CONFLICTS
.B Mime-support
will correctly handle situations where multiple packages wish to
provide viewers, editors, and/or composers for the same mime-type.
When such a conflict arises, the user will be presented with a list of
current entries for that type and asked at what priority the new
program is to be inserted.
.I Note:
Because
.I install-mime
can become interactive, it is essential that
.I stdout
not be redirected. Use the
.B --quiet
option instead.
.SH DEPENDENCIES
Packages that wish to provide MIME access to themselves should not
depend on, recommend, or suggest
.B mime-support,
but rather just put something like the following in the
.I postinst
and
.I prerm
scripts.
.ft CW
.nf
.ne 4
\& if [ -x /usr/sbin/install-mime ]
\& then
\& install-mime [...]
\& fi
.ft R
.SH "SEE ALSO"
RFC-1524 (/usr/doc/mime-support/rfc-1542)
.SH AUTHOR
.B install\-mime
was written by Brian C. White <bcwhite@verisim.com>
.SH COPYRIGHT
.B install\-mime
is in the public domain.
###############################################################################
#
# MIME types and programs that process those types
#
# Much of this file is generated automatically by the program "install-mime".
# Please see the "install-mime" man page for more information.
#
###############################################################################
###############################################################################
#
# User section follows: Any entries included in this section will take
# precedence over those created by "install-mime". DO NOT CHANGE the
# "User Section Begins" and "User Section Ends" lines, or anything outside
# of this section!
#
# ----- User Section Begins ----- #
# ----- User Section Ends ----- #
###############################################################################
###############################################################################
#
# MIME types and the extensions that represent them
#
# This file is part of the "mime-support" package. Please send email (not a
# bug report) to the maintainer if you would like new types and/or extensions
# to be added.
#
###############################################################################
application/activemessage
application/andrew-inset
application/applefile
application/atomicmail
application/cu-seeme csm cu
application/dca-rft
application/dec-dx
application/excel xls
application/ghostview
application/mac-binhex40
application/macwriteii
application/msword doc dot wrd
application/news-message-id
application/news-transmission
application/octet-stream bin
application/oda oda
application/pdf pdf
application/pgp-signature pgp
application/postscript ps ai eps
application/powerpoint ppt
application/remote-printing
application/slate
application/wita
application/wordperfect5.1 wp5
application/x-123 wk
application/x-Wingz wz
application/x-bcpio bcpio
application/x-compress z Z
application/x-cpio cpio
application/x-csh csh
application/x-debian-package deb
application/x-msdos-program com exe bat
application/x-dvi dvi
application/x-gtar gtar tgz
application/x-gzip gz
application/x-hdf hdf
application/x-httpd-php phtml pht php
application/x-latex latex
application/x-maker frm maker frame fm fb book fbdoc
application/x-mif mif
application/x-netcdf nc cdf
application/x-perl pl pm
application/x-sh sh
application/x-shar shar
application/x-sv4cpio sv4cpio
application/x-sv4crc sv4crc
application/x-tar tar
application/x-tcl tcl
application/x-tex tex
application/x-texinfo texinfo texi
application/x-troff t tr roff
application/x-troff-man man
application/x-troff-me me
application/x-troff-ms ms
application/x-ustar ustar
application/x-wais-source src
application/zip zip
audio/basic au snd
audio/x-aiff aif aiff aifc
audio/x-pn-realaudio ra ram
audio/x-wav wav
image/gif gif
image/ief ief
image/jpeg jpeg jpg jpe
image/tiff tiff tif
image/x-cmu-raster ras
image/x-portable-anymap pnm
image/x-portable-bitmap pbm
image/x-portable-graymap pgm
image/x-portable-pixmap ppm
image/x-rgb rgb
image/x-xbitmap xbm
image/x-xpixmap xpm
image/x-xwindowdump xwd
message/external-body
message/news
message/partial
message/rfc822
multipart/alternative
multipart/appledouble
multipart/digest
multipart/mixed
multipart/parallel
text/html html htm
text/plain txt c h cc hh cpp hpp
text/richtext rtx rtf
text/tab-separated-values tsv
text/x-setext etx
text/x-vCalendar vcs
text/x-vCard vcf
video/dl dl
video/fli fli
video/gl gl
video/mpeg mpeg mpg mpe
video/quicktime qt mov
video/x-msvideo avi
video/x-sgi-movie movie
x-world/x-vrml vrm vrml wrl
#! /bin/sh
cat "$@" >/dev/audio
#! /bin/sh
cat "$@" >/dev/dsp
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment