Tcl Library Source Code

Documentation
Login


[ Main Table Of Contents | Table Of Contents | Keyword Index | Categories | Modules | Applications ]

NAME

uuencode - UU-encode/decode binary data

Table Of Contents

SYNOPSIS

package require Tcl 8.5 9
package require uuencode ?1.1.4?

::uuencode::encode string
::uuencode::decode string
::uuencode::uuencode ?-name string? ?-mode octal? (-file filename | ?--? string)
::uuencode::uudecode (-file filename | ?--? string)

DESCRIPTION

This package provides a Tcl-only implementation of the uuencode(1) and uudecode(1) commands. This encoding packs binary data into printable ASCII characters.

OPTIONS

EXAMPLES

% set d [uuencode::encode "Hello World!"]
2&5L;&\\@5V]R;&0A

% uuencode::uudecode $d
Hello World!

% set d [uuencode::uuencode -name hello.txt "Hello World"]
begin 644 hello.txt
+2&5L;&\@5V]R;&0`
`
end

% uuencode::uudecode $d
{hello.txt 644 {Hello World}}

Bugs, Ideas, Feedback

This document, and the package it describes, will undoubtedly contain bugs and other problems. Please report such in the category base64 of the Tcllib Trackers. Please also report any ideas for enhancements you may have for either package and/or documentation.

When proposing code changes, please provide unified diffs, i.e the output of diff -u.

Note further that attachments are strongly preferred over inlined patches. Attachments can be made by going to the Edit form of the ticket immediately after its creation, and then using the left-most button in the secondary navigation bar.

KEYWORDS

encoding, uuencode

CATEGORY

Text processing

COPYRIGHT

Copyright © 2002, Pat Thoyts