From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14224 invoked from network); 12 Feb 2006 03:55:43 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,FORGED_RCVD_HELO autolearn=ham version=3.1.0 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 12 Feb 2006 03:55:43 -0000 Received: (qmail 72574 invoked from network); 12 Feb 2006 03:55:37 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 12 Feb 2006 03:55:37 -0000 Received: (qmail 22539 invoked by alias); 12 Feb 2006 03:55:34 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 22235 Received: (qmail 22529 invoked from network); 12 Feb 2006 03:55:33 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 12 Feb 2006 03:55:33 -0000 Received: (qmail 72272 invoked from network); 12 Feb 2006 03:55:33 -0000 Received: from blackbird.world-net.net (204.57.72.6) by a.mx.sunsite.dk with SMTP; 12 Feb 2006 03:55:31 -0000 Received: from localhost.localdomain (ppp105-254.lns1.hba1.internode.on.net [150.101.105.254]) (authenticated bits=0) by blackbird.world-net.net (8.13.1/8.13.1) with ESMTP id k1C3tVIa011102 for ; Sat, 11 Feb 2006 21:55:32 -0600 (CST) (envelope-from teratorn@world-net.net) Date: Sun, 12 Feb 2006 14:55:23 +1200 To: zsh-workers@sunsite.dk Subject: Completion functions for Twisted From: "Eric Mangold" Content-Type: multipart/mixed; boundary=----------48hlIfM0hvUVSpCJqIlZhz MIME-Version: 1.0 Message-ID: User-Agent: Opera Mail/9.00 (Linux) ------------48hlIfM0hvUVSpCJqIlZhz Content-Type: text/plain; format=flowed; delsp=yes; charset=us-ascii Content-Transfer-Encoding: 8bit Hello all! I would like to submit a completion function for the various commands that we have at the Twisted project. Right now, we have 15 command-line programs that we've implemented zsh completions for. Back in 2004 I wrote this list regarding inclusion of a "stub" function in zsh that passes control to completions functions included in the Twisted distribution. You may review the rational and discussion about this idea in the thread here: http://www.zsh.org/mla/users/2004/msg00100.html The code has been implemented, and we've been successfully using this method for about a year now. Various operating system packages, e.g. Debian, include this stub and it's been working very well for us. Could someone please review the attached file and let me know what you think? Thanks, Eric Mangold ------------48hlIfM0hvUVSpCJqIlZhz Content-Disposition: attachment; filename=_twisted_zsh_stub Content-Type: application/octet-stream; name=_twisted_zsh_stub Content-Transfer-Encoding: Base64 I2NvbXBkZWYgdHJpYWwgY29uY2ggbWt0YXAgY2Z0cCB0YXBjb252ZXJ0IHR3aXN0 ZCBja2V5Z2VuIGxvcmUgcHlodG1saXplciB3ZWJzZXRyb290IHRhcDJkZWIgdGtt a3RhcCB0a2NvbmNoIG1hbmhvbGUgdGFwMnJwbQoKIyBDb3B5cmlnaHQgKGMpIDIw MDUgRXJpYyBNYW5nb2xkCiMgTWFpbnRhaW5lcjogRXJpYyBNYW5nb2xkIDx0ZXJh dG9ybkB0d2lzdGVkbWF0cml4LmNvbT4KCiMgVGhpcyBmaWxlIGlzIG1lYW50IHRv IGJlIGluIHlvdXIgenNoIGZ1bmN0aW9uIHBhdGguIGkuZS4gaW4gb25lIG9mIHRo b3NlCiMgZGlyZWN0b3JpZXMgbGlzdGVkIGluIHlvdXIgJGZwYXRoIHZhcmlhYmxl LgojCiMgZS5nLiAvdXNyL2xvY2FsL3NoYXJlL3pzaC9zaXRlLWZ1bmN0aW9ucy8K IwojIEl0IGlzIHJlc3BvbnNpYmxlIGZvciBwYXNzaW5nIGNvbXBsZXRpb24gY29u dHJvbCB0byB0aGUgY29ycmVjdAojIGNvbXBsZXRpb24gZnVuY3Rpb24gZm9yIHRo ZSB2ZXJzaW9uIG9mIFR3aXN0ZWQgdGhhdCBpcwojIGN1cnJlbnRseSBpbiB1c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