monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Monotone-devel] [patch]--depth for monotone ls


From: Derek Scherger
Subject: Re: [Monotone-devel] [patch]--depth for monotone ls
Date: Tue, 17 May 2005 23:09:24 -0600
User-agent: Mozilla Thunderbird 1.0.2 (X11/20050403)

Joel Reed wrote:
> (%:~/tmp/root) monotone --db=../mt.db --depth=1 ls known .
> file
> 
> (%:~/tmp/root) monotone --db=../mt.db --depth=2 ls known . 
> a/file
> file
> 
> (%:~/tmp/root) monotone --db=../mt.db --depth=3 ls known . 
> a/b/file
> a/file
> file

I'm not sure if ls known is considered a working copy command but you
probably don't need the --db setting after the first time.

> This gives me what I need. When no --depth is provided "." works as
> before. Giving the whole subtree from that point.
> 
> A few questions:
> 
> 1) functionality look ok?

looks ok to me, and yeah, it's certainly a nice small patch, good work!

> 2) --depth as param name ok?

not sure. I wonder if simply --local or --nonrecursive would be better
so that --depth can always mean ancestry depth. no major objection to
--depth though. also, I wonder whether --depth=0 means current dir and
--depth=1 means one level deeper? that would have been what I expect,
but I don't know what find's --depth semantics are off the top of my head.

> 3) patch look ok (-testcase & Changelog!)

personally I'd prefer 'if (depth != -1)' over 'if (-1 != depth)'.

> 4) I want to add this to "list" obviously, but any other subcommands
>        you'd nominate for working with this option? (must be something
>        that uses restriction code!)

my vote would be for all restrictable commands to take the option. so
status, diff, commit, revert, ls unknown/ignored/missing and any others.
it appears that all you need to do is enable the option for them so it
seems easy enough to add.

Cheers,
Derek





reply via email to

[Prev in Thread] Current Thread [Next in Thread]