lua-users home
lua-l archive

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


On Sat, Nov 27, 2010 at 11:49 AM, Yuri Takhteyev <yuri@sims.berkeley.edu> wrote:
>> At 3 in the morning this idea also attacked me, particularly the fact
>> that it's essentially a wiki (implying revision history)  Sputnik
>> could do the job, although in an ideal world you would want to edit
>> annotations 'in-line'.
>
> This would take a little bit of javascript magic on the client side,
> but not much in terms of server-side work. The main motivation behind
> Sputnik's design was precisely to support cases like this: things that
> support wiki-like collaboration without necessarily being simply
> wikis.

The Ajax thing, editing notes inline without page refresh, would
indeed be preferable.

Something like this has been done in http://www.annocpan.org/ but for
documentation rather than source code.  For source code, there have
been things like these:

  http://googlecode.blogspot.com/2008/07/looks-good-to-me-source-code-review.html
  http://www.klocwork.com/products/insight-pro/inspect-code-review/index.php

> I wonder though: why a single annotation file, rather than one
> annotation file per source file?

It's a technicality, and other storage formats could be supported.
The single file seemed easier to manage, at least for the small Lua
sources.  There's just one file (annotations.txt) to copy into your
Lua source tree and update.  You can use the find function in your
text editor to search across all symbols in the project without
switching between a lot of files.  It's like a database.  How to
handle symbols displayed in two places--the .c file and the .h
file--might be a concern too.

BTW, one related idea I was thinking about was some type of text
editor plugin that would allow you to edit multiple files in the same
buffer (unlike multiple tabs, windows, or split windows), sort of like
a "view" in database terminology.  For example, the corresponding .c
and .h files could be displayed woven together or one after the other,
but it will still read and write out the buffer as separate files.