teapot is a server for distributing Tcl packages binary in binary form.



See also

A teapot client.
Teapot Repos
Teapot client and server.


Update: 18.10.2017:

Teapot and Teacup are now open-source , ActiveState, 2017-10-18


RLH: Is the idea now that packages reside in a github repository and they get pulled in with a teacup call? That would be cool.

AK: No. The implementation of the teacup, teapot, etc. apps has been made available on github as open source under BSD license. If you really want to be able to pull packages from github instead of a teapot server you now can implement that and provide a pull request.


1. What is Teapot?

In a Tcl development environment, if the core of Tcl is installed as individual files, it is generally done in one of two ways. Either one gets the source code, builds, and installs it [Installing Tcl], or one obtains an already built version and installs it [Installing Tcl].

One should call this initial set of directories the installation directory.

Now, when one wants to make use of add-on extensions, one can follow a similar process: build (which may not involve much if the code is pure-tcl) and install from source code, or download and install from a site providing prebuilt packages of some sort.

LV: From my personal perspective, Teapot appears to be a system consisting of a client and server, designed to help a user deal with the add-ons. I'm sure that the developers can speak more on this topic, but my initial impressions are that the teapot system provides one with the ability to build a site which can provide for users pre-built bundles of add-on code. Teapot also provides to users the ability to download these bundles into a specialized directory structure (aka a repository).

One needs then to have an init.tcl which has been modified to know to look in the specialized directory structure to see if a particular package require should be fulfilled from code residing in that directory.

The user makes use of the teacup command to install packages into their local repository. Then commands with tcl embedded make use of the modified init.tcl to locate the relevant packages.

2. What is Teacup?

Teacup is a client program, designed to query teapot archives to determine whether the archive contains a particular package that will run on a particular hardware/operating system architecture. Teacup also has the ability to request downloads of packages, as well as the ability to install the downloaded package into a local repository, for use by suitably modified tcl shells.

3. Why use Teapot?

Many users, over the years, have asked for centrally managed sites containing organized tcl downloads. Teapot provides such functionality.

4. Who is allowed to use teacup?

JH writes on the activetcl mailing list:

"Any ActiveTcl user currently. We haven't fully discussed plans for open sourcing the teacup client. At this moment, I'd be a bit leary about doing it because it is in flux anyways (both server and repository).

5. Who is allowed to use teapot?

JH writes:

"teapot administration binaries and the docs for creating these are part of the Tcl Developer's Kit (tdk). See the docs here:

[L1 ]

6. What teapot archives exist for public use?

JH says he doesn't know of anyone other than ActiveState running one yet.

RLH Where are the docs to set one up though? I may want to start one for secondary utilities that ActiveState may not carry (see my comments below). Alternatively, does Activestate want this to happen at this time since teacup/teapot are relatively new?

7. Who is allowed to submit new entities to be placed within the repository?

JH ActiveState's is fully ActiveState controlled for several reasons. While we aren't vetting the code quality of everything in there, we do have it work in our own local build systems.

8. How does one submit new entities to particular repositories?

JH For ActiveState's repo, generally this involves sending an email to ActiveState about a possible candidate module. Being TEA compliant is key to making it easy to fit into our build process.

9. What security is provided against malware?

JH writes: "This process requires in-depth discussion. Preferably over well-aged bottles of scotch. Cigars and dark chocolate optional. Anyone caught trying to bribe Andreas (ak) directly will be laughed at (since he neither smokes nor drinks ... we'll leave the dark chocolate as a dark horse ;) )."

10. How much does all this cost to use?

ActiveTcl is freely available from ActiveState for some platforms and distributions. Teacup comes as part of ActiveTcl now. Thus it is free to use by people using one of the distributions for the free platforms. If you are not using MacOS, Linux, or Windows, however, you are out of luck.

Teapot, though, is part of a commercial package. See the info at tdk for more details.

hmm...anger subsided...revising So if I want TclOO

./teacup.exe list | grep -i oo => redirect TclOO 0.6.3 win32-x86_64 Business Edition Only --- License required

CPAN works because the repo is completely free. Teapot will not succeed until there is a free repo.

Page to collect issues with the beta teapot on the 2006 conference CD

[Note that the following code does not need to be used once you start using a 2007 or newer teacup]

The code to link the repository into the package management is missing. The following is the code which has to go at the end of the relevant init.tcl file.

# -*- tcl -*-
# @date@
# Copyright (C) 2006 ActiveState Software Inc.

# Standard code for setting up the default local TEAPOT repository in
# use by this installation.

if {![interp issafe] && ![catch {package require platform}]} {
    # Toplevel directory of the standard local per-user repository

    global __teapot
    set    __teapot {~/Library/Application Support/ActiveState/Teapot/repository}

    # Make all repository subdirectories available which can contain
    # packages for the architecture currently executing this Tcl
    # script. This code assumes a directory structure as created by
    # 'repository::localma'.

    foreach __ [platform::patterns [platform::identify]] {
        set __ [file join $__teapot package $__]

        # The tm subdirectory contains Tcl Modules. This is relevant
        # only to a tcl shell which is able to handle such.

        # The lib subdirectory on the other hand contains regular
        # packages and can be used by all Tcl shells.

        lappend ::auto_path           [file join $__ lib]
        catch {::tcl::tm::roots [list [file join $__ teapot]]}
    unset __teapot __