Hi, all,

i'm looking for ideas and implementation strategies for a new feature:

fossil add -interactive

Here's basically what it would do:

a) recurse into the current dir/subdirs and build a list of files...

b) exclude any files which match the appropriate ignore globs (TBD)  and
any files which are already in the current checkout version. The resulting
list, if the ignore globs are well groomed, should be pretty short.

c) Present the list to the user, either in list or tree form, e.g.:

1: foo/bar
2: foo/baz
...

or:

1: foo/
 +-- 1.1: bar
 +  1.2: baz
  ...
 + 1.42: zzz
2: bar/
 + 2.1: ...

Enter one or more numbers separated by spaces or newlines, an empy line or
'.' ends input: 2<ENTER>
bar/*

continue> 1.2 1.5<ENTER>
foo/baz
foo/whatever

continue> 1.2 1.5 .<ENTER>

Possibly print out the list and ask for verification before continuing
(possibly re-entering list mode, amending the list: maybe 'd###' removes
the number from the list).

A similar (or identical) mechanism could potentially be used for commit,
rm, and diff (possibly others).

Ideas on how to optimally display the list and collect the input from the
user? (How do we do number through nested subdirs, e.g. foo/, foo/bar/, and
foo/bar/baz/...?)

A curses interface would probably be easier to use (using checkboxes
instead of number entry), but not as portable. A tk variation would
probably not be much work for one of the TCL experts on the list. (That may
be taken as a challenge if you guys like, but it is not specifically
intended as one!)

:-?

-- 
----- stephan beal
http://wanderinghorse.net/home/stephan/
http://gplus.to/sgbeal
"Freedom is sloppy. But since tyranny's the only guaranteed byproduct of
those who insist on a perfect world, freedom will have to do." -- Bigby Wolf
_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to