On Tue, Sep 3, 2013 at 12:19 PM, Stephan Beal <[email protected]> wrote:

> On Tue, Sep 3, 2013 at 9:08 PM, Ross Berteig <[email protected]> wrote:
>
>> I wonder how hard it would be for fossil to (optionally) keep the
>> statistics you are interested in?
>>
>
> That's an interesting question. Keeping them locally would be very little
> work, actually.
>
> Add a table keyed by fossil command, and simply count invocations of each
>> command. The table could be global (wherever global settings are actually
>> stored), per-repository, or per-checkout.
>>
>
> Per repo is not easy because a rebuild removes any non-core tables and it
> wouldn't be worth the trouble to make all this stuff syncable. Adding a
> table to the checkout (which will be lost on a close) will be easy to do.
>

Why not (optionally) store them in ~/.fossil? Just create appropriate keys
such as "stats:" concatenated with the command and then increment the value:

name              value
----              -----
'stats:ci'           11
'stats:extras'        5
'stats:rm'            2

All assuming of course that fossil won't be upset by extraneous stuff in
the global_config table.

Hmm... off topic but interesting, apparently I have 177 checkouts of
various repos. Undoubtedly most are defunct pointers. Is there an official
way to clean up that table?

sqlite3 ~/.fossil "select count(name) from global_config where name like
'ckout:%';"
177
_______________________________________________
fossil-users mailing list
[email protected]
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to