Lab supplies for CHICKEN Scheme.

  1. Beaker
  2. Description
  3. Dependencies
  4. Programs
    1. chicken-clean
    2. chicken-lint
  5. Extensions
    1. Repository Management
    2. Systems
  6. Links
  7. Author
  8. License


Beaker is a collection of development tools.

It is currently fairly limited, including only two programs and a small handful of libraries to make common development tasks easier. If you have an idea for something that would be useful to include, don't hesitate to contact the author.

The project's source is available here.




Usage: chicken-clean [-interactive | -quiet | -verbose]

The chicken-clean program deletes egg build artifacts.

A simple set of file patterns is used to determine what should be deleted. This includes compiled programs, binary objects (o, obj, so, dll), and files generated by the CHICKEN toolchain (,, import.scm, inline, profile, types).

When run with the -interactive flag, a confirmation prompt will be displayed before any files are deleted.


Usage: chicken-lint [csc-options ...] filename ...

The chicken-lint program checks a source file with a set of simple lint rules.

Potential problems are written as S-expressions to standard error.

Note that this program invokes csc, so any compile-time code in the program will be executed.


Repository Management

The (beaker repository) library provides a handful of procedures to help manage egg repositories.

[procedure] (chicken-install)

Returns the full pathname of the chicken-install command.

[procedure] (egg-files #!optional (path repository-path))

Returns a list of all egg-info files in the repository path.

The path argument can be used to specify an alternative repository path, which should be a thunk returning a list of pathname strings.

[procedure] (repair-repository #!optional (path repository-path))

Installs any missing dependencies for the eggs in the repository path.

The path argument can be used to specify an alternative repository path, which should be a thunk returning a list of pathname strings.

If there are any missing dependencies, they are installed into the first repository in the path and a list of newly-installed eggs is returned.

If there are no missing dependencies, nothing is done and an empty list is returned.

[procedure] (create-repository destination #!optional source)

Initialises a new egg repository at the pathname destination.

If the directory destination doesn't exist, it is created. The core CHICKEN libraries are then installed into the repository and a new modules database is generated

If a source repository is given, its contents are also copied into the new repository. This can be used to copy an existing repository to another location.


The (beaker system) library provides an API for dynamically building, loading, and reloading extension libraries. It's intended to help enable rapid development in a manner similar to asdf from Common Lisp or the system egg from CHICKEN 4.

Rather than introduce a new way to define a system's components and dependencies, this library reuses the egg specification format. In fact, you can generally think of a "system" and an "egg" as one and the same.

An example csi session that loads, edits, and reloads an example system might look like the following:

#;> (import (beaker system))
#;> (load-system "example.egg")
building example
... output ...
; loading /tmp/ ...
; loading /tmp/ ...
#;> (load-system "example.egg")
building example
#;> ,e example.scm
#;> (load-system "example.egg")
building example
... output ...
; loading /tmp/ ...

Modules are imported automatically and import libraries are reloaded whenever a module's exports list changes. Note that removing a value from a module's export list does not remove it from the session when the extension is reloaded.

[procedure] (compile-system egg-file)

Compiles all out-of-date components for the given egg.

This is equivalent to running chicken-install -no-install.

[procedure] (clean-system egg-file)

Deletes all compiled programs and extension libraries for the given egg.

Auxiliary files such as import libraries are preserved.

[procedure] (load-system egg-file #!key (skip (quote ())))

Builds and loads the given egg.

When called for the first time, all out-of-date components are recompiled, the egg's extension libraries are loaded into the calling program and its modules are immediately imported.

Subsequent calls cause the components to be recompiled and reloaded as necessary.


Evan Hanson


3-Clause BSD