tablecat-bbs-20111214$ wc -l *pm *pl|grep total
1493 total
This doesn't seem too bad, but tablecat (and virtually every Perl textboard) mixes HTML with the code, uses flat files and iterates through their contents in various places instead of using dedicated functions.
For fun I started writing bbs software to see how short it would be with better practices in use and SQLite3 backend. 100 lines into this nearly everything user-facing is done except bbcode rendering.
Does anyone have ideas for improving bbcode? I like nesting, what about:
{b {i {o {u foo}}}} —→ [b][i][o][u]foo[/u][/o][/i][/b]
with composition:
{b.i.o.u foo} —→ [b][i][o][u]foo[/u][/o][/i][/b]
I'm thinking quotes are the same, code is just markdown style with
`backquote`
,
indent blocks 4
, and
```
docstring block style
```