shithub: 9bbs

ref: b1387b2b58854f371d10d6dbcd85ac6eba802a76
dir: /README/

View raw version
9bbs
====

citadel style bbs for plan 9, written in rc

download
--------

[9bbs.tgz](http://plan9.stanleylieber.com/src/9bbs.tgz)

	git/clone git://only9fans.com/sl/9bbs

install
-------

9bbs is started by a [listen(8)](http://man.9front.org/8/listen)
script that runs on an arbitrary port.  The example files included
with this distribution are setup to run on port 666, but may be
modified to suit.  The following instructions assume that a listener
is already scanning the directory `/rc/bin/service` (true by default
for cpu servers).  In this scenario, the 9bbs script will be run as
user `none`, which has special properties limiting its access to
system resources.  Run 9bbs as any user other than `none` at
your own risk.  WARNING: Because user `none` can only read and
write files that are world-accessible, anyone with access to the
file system will be able to read and write files under `etc/`.

First, edit `src/tcp666` to reflect the location of the 9bbs files on
your system, and set any desired options.  Edit `etc/motd` and
`etc/welcome` according to taste.

Next, build and install the programs:

	cd 9bbs/src
	mk install
	cd ..
	mk log
	mk perms	# user who runs this must be a member of group none

Note: 9bbs uses a modified copy of the Plan 9 pager,
[p(1)](http://man.9front.org/1/p).  It is identical in all ways to the
original except that the `!` command for issuing shell commands has been
removed.  The resulting np binary is copied to `$objtype/bin/`, the
tcp666 script is copied to `/rc/bin/service/`, and a log file is created
in `/sys/log/9bbs`.  All other 9bbs files remain within the 9bbs
directory.

All of that completed, 9bbs will now answer telnet connections on port
666.

Suggested: Read the source.

use
---

The following commands have been implemented:

	[0-9]+	print specified message
	b		back
	B		toggle biff
	C		change password
	d [...]		delete message
	D [...]		view, set message delimiter
	>D		truncate message delimiter
	e		enter message
	E [...]		view, set editor (choices: sam, simple)
	f		jump to first message
	g [...]		list rooms with unread messages, go to specified room
	gr		list ten most recently active rooms
	grep [...]	grep messages in current room for regexp
	h, help		print this help message
	k [...]		print roomlist or grep for specified regexp
	l		jump to last message
	L [...]		view, set number of lines to print before engaging pager (enter to continue, q to quit)
	n		next
	p, re [...]		print message with minimal headers
	P [...]		print message with full headers
	r [...]		reply to message
	q		quit
	S [...]		view, set signature
	>S		truncate signature
	t		print current date and time
	u		list users
	w		who is online
	wr		list ten most recently active users
	W [...]		view, set line wrap width
	y		synchronize message list for current room
	z		mark all messages (on the entire bbs) as read
	" [...]		print message in quoted form, suitable for reply
	?		print debug information

rooms
-----

A room is a directory somewhere under `rooms/` that contains at least
one numbered message file.  An example room has been included in the
distribution: `rooms/lobby/`.

To create a room:

	cd 9bbs
	./bin/mkroom roomname

Note: Rooms may be nested.

messages
---------

The message format is as follows:

	To: lobby
	Date: Wed, 31 Dec 1969 19:00:01 EST
	X-Date-N: 1
	
	This is a placeholder message created to bootstrap the system.

todo
----

• `g [room]/[n]` to print message `[n]` in `[room]`.

mailing list
------------

Mainly for announcements.

To subscribe:

	echo subscribe | mail [email protected]

After you're subscribed, messages will arrive from, and may be sent
to, [email protected].

To unsubscribe:

	echo unsubscribe | mail [email protected]

powered
-------

<http://osuny.bell-labs.co> - telnet port 666, ssh port 999