Tcl HomeTcl Home hosted by

Google SiteSearch

Tcl Virtual File System

Developers read and write files all the time; it's a common feature in many programs, so all programming languages provide commands to make that easy. But is it just as easy to work with zip files, websites, and other sorts of resources? Usually you need a separate set of add-ons.

Enter TclVFS. The Tcl Virtual File System lets you treat all kinds of local or remote storage mechanisms the same way you'd treat local files. Want to "cd" into a website, open a file, and read from it? No problem. All the same commands you'd use to deal with normal files and the local filesystem are available.

The Tcl VFS hooks into the lowest level of the Tcl I/O system, so that all file commands are available anywhere there's a virtual file system driver (which can be written in Tcl of course, so its easy to add your own).

Some Examples: Here are a few examples of file systems that you can use:

  • the native file system
  • zip files
  • web sites
  • ftp sites
  • WebDAV sites
  • TAR files
  • Metakit databases (used for Starkits)
  • available Tcl commands (!)