[darcs-users] [patch59] 835 - show file with file directory arguments [status=amend-requested]

Eric Kow kowey at darcs.net
Sun Nov 15 09:04:04 UTC 2009


Hi!

May I request some small modifications to this patch?

Sat Nov 14 17:13:33 CET 2009  Luca Molteni <volothamp at gmail.com>
  * 835 - show file with file directory arguments

835 - show file with file directory arguments
-----------------------------------------------
Please rename that to

resolve issue835: show file with file directory arguments

> -  command_extra_args = 0,
> +  command_extra_args = -1,

What does this do?

> hunk ./src/Darcs/Commands/ShowFiles.lhs 92
> -manifest_cmd to_list opts _ = do
> +manifest_cmd to_list opts argList = do
> hunk ./src/Darcs/Commands/ShowFiles.lhs 94
> -    mapM_ output list
> +    case argList of 

You have a bit of trailing whitespace here (which I would normally just
remove in a follow-up patch, but since I'm requesting modifications
anyway, I thought I'd point it out :-))

> +        [] -> mapM_ output list
> +        (x:[]) -> mapM_ output (onlysubdirs x list)

Ah, but this appears to be missing the case where you have more than one
argument.  I think it's fine to just complain to the user

> hunk ./src/Darcs/Commands/ShowFiles.lhs 102
> +          onlysubdirs subdir = filter (\x -> (subdir `isPrefixOf` (x ++ "/")) || (subdir == x))

Looks fine to me.

-- 
Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow>
PGP Key ID: 08AC04F9
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <http://lists.osuosl.org/pipermail/darcs-users/attachments/20091115/cfe58e03/attachment.pgp>


More information about the darcs-users mailing list