Commit Graph

684 Commits

Author SHA1 Message Date
Kartik K. Agaram
b493ed32b8 get Teliva working on FreeBSD 2022-01-26 09:36:06 -08:00
Kartik K. Agaram
cbe85a18c7 rename the custom big picture view to doc:main 2022-01-25 23:25:05 -08:00
Kartik K. Agaram
32d86bfc7f override big picture view with doc:bp if it exists
Going to big picture from doc:bp still goes to the default
auto-generated big picture view.

While doc:bp provides some programmability, it's also far klunkier than
the default view. Rendering is worse, and it's always in edit mode
because I'm trying to avoid complicating the UX with a notion of
rendered markup. That means cursor movement is less convenient. It's
also easy to accidentally edit the big-picture view.
2022-01-25 23:07:43 -08:00
Kartik K. Agaram
7fd434a692 better default word at cursor for prose 2022-01-25 22:34:38 -08:00
Kartik K. Agaram
e205057ff2 highlight [[wikiwords]] in prose
These are just hints that there's something worth jumping to. The
jumping still happens using ctrl-g.
2022-01-25 22:31:53 -08:00
Kartik K. Agaram
91d47faf23 disable Lua colors in prose 2022-01-25 21:44:01 -08:00
Kartik K. Agaram
84d76b11fa rename 2022-01-25 21:23:20 -08:00
Kartik K. Agaram
283d4dba59 new section in big picture: prose (non-code)
I've always found "Documentation" too pretentious.
2022-01-25 21:07:52 -08:00
Kartik K. Agaram
2fc48626b5 optimization: stop saving identical definitions
This is long overdue.
2022-01-25 20:53:46 -08:00
Kartik K. Agaram
2e38583da2 save doc: buffers to .tlv images 2022-01-25 20:45:00 -08:00
Kartik K. Agaram
39781351ee delete a redundant function prototype 2022-01-25 20:39:49 -08:00
Kartik K. Agaram
d20e6a415f rename a function 2022-01-25 20:36:26 -08:00
Kartik K. Agaram
c5f6e30042 start supporting non-code "buffers"
First step: when a "definition" starts with "doc:" it's not a
definition, just a buffer. Stop trying to interpret it as Lua.
2022-01-25 20:29:35 -08:00
Kartik K. Agaram
1ee25077b8 documentation for NetBSD 2022-01-24 20:51:46 -08:00
Kartik K. Agaram
6d53235dfc work around a bug in NetBSD libcurses
http://gnats.netbsd.org/56664 reported.
2022-01-24 20:43:30 -08:00
Kartik K. Agaram
6a33284b07 get Teliva running on NetBSD
NetBSD still uses curses by default. One _could_ install ncurses, but I
don't have access to a NetBSD box with permissions to install ncurses,
so I'm experimenting to see how far we can get with just curses. So far
most of the apps seem to work, with the exception of one bug that I'll
commit next.
2022-01-24 20:15:43 -08:00
Kartik K. Agaram
e4f934db6b delete some dead code
I'm kinda sorta able to get lcurses running on NetBSD 9.2 without this
particular hack.
2022-01-24 20:06:33 -08:00
Kartik K. Agaram
a5a8c1b936 known issue on OpenBSD 2022-01-24 20:01:27 -08:00
Kartik K. Agaram
a3a207d2e3 more generic build target in luasocket 2022-01-24 17:32:42 -08:00
Kartik K. Agaram
058145ee23 clarify generic 'bsd' build target
We still only have OpenBSD working.
2022-01-24 17:25:50 -08:00
Kartik K. Agaram
3f6861b4db gemini: demo of context-sensitive menu
Basic procedure:
  - save/restore `menu` around call of a function (directly or
    indirectly called by `update`) that encapsulates some state change
  - override `menu` inside the function to correspond to its update loop
2022-01-18 20:11:56 -08:00
Kartik K. Agaram
5258fbec7c file permissions: clear stale errors 2022-01-16 22:34:21 -08:00
Kartik K. Agaram
06edd8bda7 editing apps: clean up some stale prints 2022-01-16 22:33:41 -08:00
Kartik K. Agaram
abc2ea4675 file access policy: support editing with >10 lines 2022-01-16 15:53:27 -08:00
Kartik K. Agaram
6499e93345 clearer first sentence 2022-01-14 14:42:20 -08:00
Kartik K. Agaram
f204dff73b enumerate mirrors 2022-01-14 08:55:05 -08:00
Kartik K. Agaram
863f14041d kilo: cleaner go menu 2022-01-11 20:25:11 -08:00
Kartik K. Agaram
4eb4bc4f58 some heuristic guidance on permissions screen 2022-01-04 23:42:01 -08:00
Kartik K. Agaram
ffd600b111 try running permissions advice after editing
This implies it must be side-effect free. We still need to figure out
how to convey that to the computer owner.
2022-01-04 22:33:07 -08:00
Kartik K. Agaram
855eafd1d9 slightly better error message 2022-01-04 22:09:42 -08:00
Kartik K. Agaram
64f8a1e15d reorg 2022-01-04 22:09:23 -08:00
Kartik K. Agaram
4798d97a15 feels more consistent to exit editor with ctrl-x 2022-01-04 21:52:23 -08:00
Kartik K. Agaram
08c1ea8fc4 extract function 2022-01-04 21:48:55 -08:00
Kartik K. Agaram
3d6b9b0adc load permissions properly in a third place 2022-01-04 21:41:41 -08:00
Kartik K. Agaram
4018c2e8e2 when editing a function, show its callers
No way to select between them. That complicates the UI too much when we
do so much with the cursor. But it's still useful to suggest things to
type in after ctrl-g.
2022-01-03 23:36:44 -08:00
Kartik K. Agaram
7812ebc5f1 start saving callers of functions
I think this is significantly slowing things down. Perhaps we should
sample or something.
2022-01-03 13:26:38 -08:00
Kartik K. Agaram
1c78ab3d2e comment 2022-01-03 13:24:21 -08:00
Kartik K. Agaram
f6cf8f801c rename 2022-01-03 13:24:01 -08:00
Kartik K. Agaram
14ab0729c9 extract a function 2022-01-03 10:23:25 -08:00
Kartik K. Agaram
1261f3f3c9 events view: jump to a function 2022-01-03 09:58:34 -08:00
Kartik K. Agaram
00db37f064 toot-toot: gracefully handle lack of permissions
This opens up a whole new can of worms: Teliva's ability to show clear
error messages hinges on apps having decent error handling.

I suppose that's ok. A new app someone downloads that throws out strange
error messages and puts them in the equivalent of the console doesn't
exactly engender trust. It's reasonable to treat poor error handling as
breakage.

Here's my running list of open questions from working on the permissions
screen so far:
  - how to teach people to care about the difference between:
    - permissions known to be unsafe
    - permissions unknown to be safe
  - how to show syntax errors in the permissions screen
  - how to detect syntax errors in the permissions screen (lots of stuff
    only shows up when running)
  - how to deal with apps with poor error handling (this commit; punt for now)
  - how to engender skepticism in people towards what apps tell them
    ("oh, just go into the permissions screen and type ___ to fix this error")
  - how to help people judge the quality of their permissions
    (mode == 'r' vs mode ~= 'w')
2022-01-03 08:20:05 -08:00
Kartik K. Agaram
0abd09dc05 rendering improvement 2022-01-02 22:52:57 -08:00
Kartik K. Agaram
be0c936276 error handling when editing file permissions
Still highly non-ideal. Lua is a dynamic language, and has low ability
to detect syntax errors within functions.

Perhaps I should run a test call after every edit.
2022-01-02 22:51:27 -08:00
Kartik K. Agaram
e3cef7ee56 bugfix: policies must end in newline
I believe kilo kinda naturally enforces that. We'll see.
2022-01-02 22:38:28 -08:00
Kartik K. Agaram
b97291602b instrument some obvious syscalls 2022-01-02 22:36:33 -08:00
Kartik K. Agaram
49a03587ef indent 2022-01-02 22:20:48 -08:00
Kartik K. Agaram
a901203227 start on a view of audit events 2022-01-02 22:13:47 -08:00
Kartik K. Agaram
74360f20be . 2022-01-02 21:39:53 -08:00
Kartik K. Agaram
2d0bb4438c editing file permissions 2022-01-02 21:33:49 -08:00
Kartik K. Agaram
e07fe0c87a make some space for callers of a function 2022-01-02 20:56:09 -08:00