[darcs-devel] [issue297] --list-options fails when command cannot be run

Eric Kow bugs at darcs.net
Fri Oct 13 02:46:43 PDT 2006


New submission from Eric Kow <eric.kow at gmail.com>:

Import of RT #214

David Roundy <droundy at abridgegame.org> 2005-02-09
-------------------------------------------------

On Wed, Feb 09, 2005 at 07:45:19PM +0200, Vassilii Khachaturov wrote:
> Here is a transcript:
>
> vassilii at ilmarinen:~$ darcs trackdown --he[TAB pressed]
> darcs failed: Can't run command trackdown here.
> You need to be in a repository directory to run this command.
> [output paused, ENTER pressed]

The problem here is that the bash completion calls darcs trackdown
--list-options to find out what flags exist, but this command fails because
darcs trackdown itself may only be run in a repository.

So the fix is to make --list-options able to run (as is the case with
--help) even when in a situation where the command itself cannot be run.
This isn't entirely trivial, since some features (e.g. completing for pull
using the repositories in _darcs/prefs/repos) won't work if you aren't in a
repository. Still, this shouldn't be *too* hard to fix.

----------
messages: 1079
nosy: EricKow, droundy, tommy
priority: bug
status: unread
title: --list-options fails when command cannot be run
topic: FromRequestTracker, ProbablyEasy

____________________________________
Darcs issue tracker <bugs at darcs.net>
<http://bugs.darcs.net/issue297>
____________________________________




More information about the darcs-devel mailing list