1 <?xml version="1.0" encoding="UTF-8"?>
2 <refentry id="megatron.1">
4 <refentrytitle>megatron</refentrytitle>
6 <manvolnum>1</manvolnum>
8 <refmiscinfo class="date">02 Sep 2011</refmiscinfo>
10 <refmiscinfo class="source">@NETATALK_VERSION@</refmiscinfo>
13 <refnamediv id="name">
14 <refname>megatron</refname>
16 <refname>unhex</refname>
18 <refname>unbin</refname>
20 <refname>unsingle</refname>
22 <refname>hqx2bin</refname>
24 <refname>single2bin</refname>
26 <refname>macbinary</refname>
28 <refpurpose>Macintosh file format transformer</refpurpose>
31 <refsynopsisdiv id="synopsis">
33 <command>megatron<indexterm><primary>megatron</primary></indexterm></command>
35 <arg choice="opt" rep="repeat"><replaceable>sourcefile</replaceable></arg>
39 <command>unbin<indexterm><primary>unbin</primary></indexterm></command>
41 <arg choice="opt" rep="repeat"><replaceable>sourcefile</replaceable></arg>
45 <command>unhex<indexterm><primary>unhex</primary></indexterm></command>
47 <arg choice="opt" rep="repeat"><replaceable>sourcefile</replaceable></arg>
51 <command>unsingle<indexterm><primary>unsingle</primary></indexterm></command>
53 <arg choice="opt" rep="repeat"><replaceable>sourcefile</replaceable></arg>
57 <command>hqx2bin<indexterm><primary>hqx2bin</primary></indexterm></command>
59 <arg choice="opt" rep="repeat"><replaceable>sourcefile</replaceable></arg>
63 <command>single2bin<indexterm><primary>single2bin</primary></indexterm></command>
65 <arg choice="opt" rep="repeat"><replaceable>sourcefile</replaceable></arg>
69 <command>macbinary<indexterm><primary>macbinary</primary></indexterm></command>
71 <arg choice="opt" rep="repeat"><replaceable>sourcefile</replaceable></arg>
75 <refsect1 id="description">
76 <title>DESCRIPTION</title>
78 <para><command>megatron</command> is used to transform files from BinHex,
79 MacBinary, AppleSingle, or <emphasis remap="B" role="bold">netatalk</emphasis> style
80 AppleDouble formats into MacBinary or <emphasis remap="B">netatalk</emphasis>
81 style AppleDouble formats. The <emphasis remap="B">netatalk</emphasis>
82 style AppleDouble format is the file format used by <emphasis remap="B">afpd,</emphasis>
83 the <emphasis remap="B">netatalk</emphasis> Apple Filing Protocol
84 (AppleShare) server. BinHex, MacBinary, and AppleSingle are commonly used
85 formats for transferring Macintosh files between machines via email or
86 file transfer protocols. <command>megatron</command> uses its name to
87 determine what type of transformation is being asked of it.</para>
89 <para>If <command>megatron</command> is called as <command>unhex</command>
90 , <command>unbin</command> or <command>unsingle</command>, it tries to
91 convert file(s) from BinHex, MacBinary, or AppleSingle into AppleDouble
92 format. BinHex is the format most often used to send Macintosh files by
93 e-mail. Usually these files have an extension of ".hqx". MacBinary
94 is the format most often used by terminal emulators "on the fly"
95 when transferring Macintosh files in binary mode. MacBinary files often
96 have an extension of ".bin". Some Macintosh LAN-based email
97 packages use uuencoded AppleSingle format to "attach" or
98 "enclose" files in email. AppleSingle files don't have a
99 standard filename extension.</para>
101 <para>If <command>megatron</command> is called as <command>hqx2bin</command>,
102 <command>single2bin</command>, or <command>macbinary</command>, it will
103 try to convert the file(s) from BinHex, AppleSingle, or AppleDouble into
104 MacBinary. This last translation may be useful in moving Macintosh files
105 from your <command>afpd</command> server to some other machine when you
106 can't copy them from the server using a Macintosh for some reason.</para>
108 <para>If <command>megatron</command> is called with any other name, it
109 uses the default translation, namely <command>unhex</command>.</para>
111 <para>If no source file is given, or if <emphasis remap="I">sourcefile</emphasis>
112 is `<emphasis remap="" role="bold">-</emphasis>', and if the
113 conversion is from a BinHex or MacBinary file, <command>megatron</command>
114 will read from standard input.</para>
116 <para>The filename used to store any output file is the filename that is
117 encoded in the source file. MacBinary files are created with a
118 ".bin" extension. In the case of conflicts, the old file is
122 <refsect1 id="options">
123 <title>OPTIONS</title>
125 <variablelist remap="TP">
127 <term><option>-v, --version</option></term>
130 <para>Show version.</para>
138 <refsect1 id="see_also">
139 <title>SEE ALSO</title>
141 <para><citerefentry><refentrytitle>afpd</refentrytitle><manvolnum>8</manvolnum></citerefentry></para>