|
From: | Aaron Bentley |
Subject: | [Gnu-arch-users] Script for extending tla |
Date: | 13 Jan 2004 11:33:12 -0500 |
Hi all, A while back, there was a suggestion that we make arch extendable with shell scripts. I thought the idea was neat, but Tom was having nothing of it. He felt that we could just write wrappers around tla to achive the same effect. Well, I think he was right. Here's a stupid-simple arch wrapper I wrote, which I have named, with all due humility, Aaron Bentley's Arch. You can use it to add new commands, add your favourite options to existing commands, or disable existing commands. The main script just looks for files in ~/.aba/commands, and executes them if they exist. Otherwise, it executes tla. Command scripts can take either "exec" as $1, which runs the command, or "desc" which outputs a description in the format used by "tla help" Attached are aba: The main script diff: a shortcut for "tla changes --diff" help: an override for "tla help" that appends the list of extensions to the end of normal help output what-changed: notifies the user to use "changes" instead Comments and suggestions are most welcome. In particular, I'd like to provide support for shell completion, but I don't know how to go about that. Aaron -- Aaron Bentley Director of Technology PanoMetrics, Inc.
aba
Description: Text Data
diff
Description: Text Data
what-changed
Description: Text Data
help
Description: Text Data
[Prev in Thread] | Current Thread | [Next in Thread] |