Hamilton C shell
| Industry | Software development |
|---|---|
| Founded | December 12, 1988 |
| Founder | Nicole Hamilton |
| Headquarters | United States |
| Products | Hamilton C shell |
| Website | hamiltonlabs |
Hamilton C shell represents a replica of the Unix C shell alongside tools designed for Microsoft Windows. Developed by Nicole Hamilton at Hamilton Laboratories, it is an original creation, not derived from existing source code. Initially launched on OS/2 on December 12, 1988, it later became available for Windows NT in July 1992. Although the OS/2 edition was phased out in 2003, the Windows variant continues to receive active maintenance.
Written in the C language, Hamilton C shell delivers a Unix-like command-line environment tailored for Windows users. It primarily serves developers and IT specialists who require Unix-style shell capabilities within a commercial proprietary framework. Its sustained presence and ongoing updates underscore its specialized role among Windows shell environments.
Design
The architecture of Hamilton C shell sets it apart from the traditional Unix C shell through its unique compiler structure, employment of threads, and compliance with Windows-specific conventions rather than Unix standards.[1][2]
Parser
Unlike the original C shell’s ad hoc parser, which is effective for interactive commands but limited in handling complex scripting scenarios—such as being unable to pipe output from a foreach construct into grep—Hamilton utilizes a top-down recursive descent parser. This parser compiles commands into an internal representation before execution.[3][1] This approach supports unlimited nesting and piping of commands.[4] The language extends functionality by incorporating built-in and user-defined procedures, local variables, floating-point arithmetic, and improved expression handling alongside advanced editing and wildcard operators. A notable feature is the "indefinite directory" wildcard "...", which matches zero or more directory levels to complete a pattern.[5]
Threads
Due to the absence of fork or an equivalent efficient mechanism on Windows, Hamilton relies on Windows threads.[4][1] These threads operate within a shared process space, meaning all threads share state information—modifications to directories or memory impact every thread. While thread creation is less resource-intensive compared to processes, it does not provide isolation. To emulate process-level isolation, threads coordinate access to resources through locks.[6]
Windows conventions
Hamilton C shell differentiates itself from other Unix shells by natively supporting Windows-specific features such as drive letter notation, backslash path separators, and escape character usage. This enhances interoperability across platforms.
External links
- ↑ 1.0 1.1 1.2 Cite error: Invalid
<ref>tag; no text was provided for refs namedMIPS - ↑ Cite error: Invalid
<ref>tag; no text was provided for refs namedBYTE - ↑ Cite error: Invalid
<ref>tag; no text was provided for refs namedEarlyQuickRef - ↑ 4.0 4.1 Cite error: Invalid
<ref>tag; no text was provided for refs namedAnnounce - ↑ https://hamiltonlabs.com/UserGuide/31-Wildcarding.htm
- ↑ https://groups.google.com/group/comp.os.ms-windows.programmer.win32/msg/77533bcc6197c627