template stuff
Signed-off-by: Sam Therapy <sam@samtherapy.net>
This commit is contained in:
parent
f355da34b0
commit
c510a1b05c
52 changed files with 1429 additions and 18 deletions
28
Makefile
28
Makefile
|
@ -1,17 +1,23 @@
|
|||
P=gowerc
|
||||
SRC=git.froth.zone
|
||||
USER?=fishe
|
||||
GO_VERSION=1.18
|
||||
GO ?= go
|
||||
GOFLAGS ?= -ldflags "-s -w"
|
||||
|
||||
docker: $(USER)/$(P)
|
||||
CGO_ENABLED ?= 0
|
||||
|
||||
$(USER)/$(P): bin/$(P)
|
||||
docker build -t "$(USER)/$(P):latest" .
|
||||
all: go2werc
|
||||
|
||||
bin/$(P): *.go
|
||||
docker run --rm -v ${PWD}:/go/src/$(SRC)/$(USER)/$(P) golang:${GO_VERSION} /bin/bash -c "go list -f '{{range .Imports}}{{printf \"%s\n\" .}}{{end}}' $(SRC)/$(USER)/$(P) | xargs go get -d; CGO_ENABLED=0 go build -v -installsuffix cgo -o /go/src/$(SRC)/$(USER)/$(P)/bin/$(P) $(SRC)/$(USER)/$(P)"
|
||||
go2werc:
|
||||
$(GO) build $(GOFLAGS) .
|
||||
|
||||
fmt:
|
||||
gofmt -w -s .
|
||||
|
||||
vet:
|
||||
$(GO) vet ./...
|
||||
|
||||
lint: fmt vet
|
||||
-golangci-lint run
|
||||
|
||||
clean:
|
||||
docker run --rm -v ${PWD}:/opt busybox rm -f /opt/bin/$(P)
|
||||
docker rmi -f "$(USER)/$(P):latest"
|
||||
$(GO) clean
|
||||
|
||||
.PHONY: clean lint test fmt vet help
|
10
README.md
10
README.md
|
@ -10,11 +10,11 @@ clone of http://werc.cat-v.org/ in go.
|
|||
|
||||
## building
|
||||
|
||||
### with go
|
||||
### with go install
|
||||
|
||||
go install git.froth.zone/sam/go2werc@latest
|
||||
|
||||
### in docker
|
||||
<!-- ### in docker
|
||||
|
||||
check out the repo and run:
|
||||
|
||||
|
@ -40,5 +40,9 @@ with a zip file:
|
|||
|
||||
### in docker
|
||||
|
||||
docker run --rm --name gowerc -v $PWD:/opt mischief/gowerc -root /opt/werc.zip
|
||||
docker run --rm --name gowerc -v $PWD:/opt mischief/gowerc -root /opt/werc.zip -->
|
||||
|
||||
## License
|
||||
Werc was originally put into the public domain. Since the public domain isn't a thing
|
||||
outside of the US, 0BSD is used instead. It's basically the public domain but the EU
|
||||
actually recognizes it.
|
17
docker.mk
Normal file
17
docker.mk
Normal file
|
@ -0,0 +1,17 @@
|
|||
P=gowerc
|
||||
SRC=git.froth.zone
|
||||
USER?=fishe
|
||||
GO_VERSION=1.18
|
||||
|
||||
docker: $(USER)/$(P)
|
||||
|
||||
$(USER)/$(P): bin/$(P)
|
||||
docker build -t "$(USER)/$(P):latest" .
|
||||
|
||||
bin/$(P): *.go
|
||||
docker run --rm -v ${PWD}:/go/src/$(SRC)/$(USER)/$(P) golang:${GO_VERSION} /bin/bash -c "go list -f '{{range .Imports}}{{printf \"%s\n\" .}}{{end}}' $(SRC)/$(USER)/$(P) | xargs go get -d; CGO_ENABLED=0 go build -v -installsuffix cgo -o /go/src/$(SRC)/$(USER)/$(P)/bin/$(P) $(SRC)/$(USER)/$(P)"
|
||||
|
||||
clean:
|
||||
docker run --rm -v ${PWD}:/opt busybox rm -f /opt/bin/$(P)
|
||||
docker rmi -f "$(USER)/$(P):latest"
|
||||
|
20
mkfile
Normal file
20
mkfile
Normal file
|
@ -0,0 +1,20 @@
|
|||
GO = go
|
||||
|
||||
CGO_ENABLED = 0
|
||||
|
||||
all: go2werc
|
||||
|
||||
go2werc:
|
||||
$GO build -ldflags="-s -w" .
|
||||
|
||||
fmt:
|
||||
gofmt -w -s .
|
||||
|
||||
vet:
|
||||
$GO vet ./...
|
||||
|
||||
lint: fmt vet
|
||||
-golangci-lint run
|
||||
|
||||
clean:
|
||||
$GO clean
|
|
@ -1,4 +1,4 @@
|
|||
{
|
||||
"mastersite": "example.com"
|
||||
"mastersite": "dns.froth.zone"
|
||||
}
|
||||
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
<nav>
|
||||
<div class='left'>
|
||||
<a href="/sitemap">site map</a> |
|
||||
<a href='https://9p.io/'>9p.io</a> |
|
||||
<a href='https://git.froth.zone/sam'>gitea</a> |
|
||||
<!-- <a href="/sitemap">site map</a> | -->
|
||||
<a href='https://status.froth.zone/'>status page</a> |
|
||||
<a href='https://git.froth.zone/sam'>git</a>
|
||||
</div>
|
||||
|
||||
<div class="right">
|
||||
|
|
5
root/sites/default.cat-v.org/_werc/lib/footer.inc
Normal file
5
root/sites/default.cat-v.org/_werc/lib/footer.inc
Normal file
|
@ -0,0 +1,5 @@
|
|||
<br class="doNotDisplay doNotPrint" />
|
||||
|
||||
<div style="margin-right: auto;"><a href="http://werc.cat-v.org">Powered by werc</a></div>
|
||||
|
||||
<div><form action="/_search/" method="POST"><input type="text" id="searchtext" name="q"> <input type="submit" value="Search"></form></div>
|
23
root/sites/default.cat-v.org/_werc/lib/top_bar.inc
Normal file
23
root/sites/default.cat-v.org/_werc/lib/top_bar.inc
Normal file
|
@ -0,0 +1,23 @@
|
|||
<div class="left">
|
||||
<a href="http://quotes.cat-v.org">quotes</a> |
|
||||
<a href="http://doc.cat-v.org">docs</a> |
|
||||
<a href="http://repo.cat-v.org">repo</a> |
|
||||
<a href="http://go-lang.cat-v.org">golang</a> |
|
||||
<a href="http://sam.cat-v.org">sam</a> |
|
||||
<a href="http://man.cat-v.org">man</a> |
|
||||
<a href="http://acme.cat-v.org">acme</a> |
|
||||
<a href="http://glenda.cat-v.org">Glenda</a> |
|
||||
<a href="http://ninetimes.cat-v.org">9times</a> |
|
||||
<a href="http://harmful.cat-v.org">harmful</a> |
|
||||
<a href="http://9p.cat-v.org/">9P</a> |
|
||||
<a href="http://cat-v.org">cat-v.org</a>
|
||||
</div>
|
||||
|
||||
<div class="right">
|
||||
|
||||
<span class="doNotDisplay">Related sites:</span>
|
||||
| <a href="http://cat-v.org/update_log">site updates</a>
|
||||
| <a href="/sitemap">site map</a> |
|
||||
|
||||
</div>
|
||||
|
4
root/sites/offblast.org/_werc/config.json
Normal file
4
root/sites/offblast.org/_werc/config.json
Normal file
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"title": "offblast.org",
|
||||
"subtitle": "blast off!"
|
||||
}
|
49
root/sites/offblast.org/_werc/pub/style.css
Normal file
49
root/sites/offblast.org/_werc/pub/style.css
Normal file
|
@ -0,0 +1,49 @@
|
|||
body { display: flex; flex-wrap: wrap; font-family: sans; }
|
||||
header { flex-basis: 100%; flex-shrink: 0; }
|
||||
article { flex-basis: 60%; padding-left: 1em; }
|
||||
footer { flex-basis: 100%; flex-shrink: 0; }
|
||||
header nav { display: flex; justify-content: space-between; }
|
||||
nav a, header a { text-decoration: none ; color: inherit; }
|
||||
header h1 span { margin-left: 1em; font-size: 50%; font-style: italic; }
|
||||
body > nav { flex-basis: content; padding-right: 1vw; min-width: 16em; }
|
||||
nav ul { display: flex; flex-direction: column; list-style-type: none; list-style-position: outside; padding-left: 0; }
|
||||
nav li ul { padding-left: 0.6em }
|
||||
footer { display: flex; justify-content: space-between; }
|
||||
|
||||
/* cut here to leave vanity behind */
|
||||
|
||||
body { margin:0; padding: 0; font-size: 84%; font-family: Helvetica, Verdana, Arial, 'Liberation Sans', FreeSans, sans-serif; }
|
||||
a { text-decoration: none; color: }
|
||||
a:hover { text-decoration: underline; }
|
||||
.thisPage { color: black; }
|
||||
|
||||
/* header and top bar */
|
||||
header nav { background-color: rgb(100,135,220); color: white; padding: 0.3em; border-bottom: 2px solid black; font-size: 91%; }
|
||||
header h1 { background-color: #ff6d06; color: black; margin: 0; border-bottom: 2px solid black; font-weight: normal; padding: 0.25ex; font-size: 233%; }
|
||||
header a:hover { text-decoration: none; }
|
||||
|
||||
/* sidebar */
|
||||
body > nav { border-right: 1px solid #ddd; padding: 0; }
|
||||
body > nav > div { border-bottom: 1px solid #ddd; }
|
||||
body > nav > div a { color: rgb(0, 102, 204); display: block; text-transform: capitalize; font-weight: bold; padding: 0.25em 1ex 0.25em 2mm; font-size: 102%}
|
||||
body > nav > div a:hover { color: white; background-color: rgb(100,135,220); border-left: black solid 0.2em; text-decoration: none; }
|
||||
body > nav > div p { font-weight: bold; margin: 0 0 0.5em 2mm; padding: 1em 0 0 0; }
|
||||
|
||||
/* main copy */
|
||||
article { padding: 0.5ex 0 5vh 1vw; }
|
||||
article h1, article h2 { color: rgb(0,102,204); font-weight: bold; margin: 2em 0 0 0; border-bottom: 2px solid rgb(0,102,204); }
|
||||
article h3, article h4, article h5 { color: rgb(0,102,204); font-weight: bold; margin: 2em 0 0 0; }
|
||||
article h6, article h7, article h8 { color: rgb(0,102,204); font-weight: bold; margin: 2em 0 0 0; }
|
||||
article a { color: rgb(0,102,204); }
|
||||
article a:hover { color: rgb(100,135,220); }
|
||||
|
||||
/* footer */
|
||||
footer { color: white; background-color: rgb(100,135,220); }
|
||||
footer a { color: inherit; }
|
||||
footer div { padding: 1em; }
|
||||
|
||||
/* tables */
|
||||
table { border: 1px solid rgba(128,128,128,0.5); padding: 0; }
|
||||
th { color: white; background-color: rgb(100,135,220); }
|
||||
tr:nth-child(odd) { background-color: rgba(128,128,128,0.1) }
|
||||
|
67
root/sites/offblast.org/foo/bar.md
Normal file
67
root/sites/offblast.org/foo/bar.md
Normal file
|
@ -0,0 +1,67 @@
|
|||
# Dolentem volucri lugubris
|
||||
|
||||
## Alto exercet
|
||||
|
||||
[Lorem markdownum rogavit](http://imgur.com/) obsedit **Thebis** in dextera? Qui
|
||||
cum, cum **nubila fieri** quamquam: non graia reperta inpositos ut de.
|
||||
|
||||
if (server_compiler + memory_ipx < typeface(scannerDll)) {
|
||||
keystroke = personalListserv * uriTextDisplay(dslam, blacklist_png,
|
||||
primary);
|
||||
} else {
|
||||
malwareSms(smmSsl, animated_brouter.up(install_d, macro_nat_isp,
|
||||
petaflops_system), 319307);
|
||||
marketingRowTitle(2, network(logic_cmos_shift), middlewareDhcp);
|
||||
}
|
||||
sidebar(matrixVirus(wordartAjax), flatPartyDisk.rootDynamicSla(42 -
|
||||
model_command_wavelength, error_hard_superscalar(snippet, -3),
|
||||
gnutella_wimax));
|
||||
unixHardSource.schemaKilobit(logCybersquatterCard(megabyte));
|
||||
hot.file_operating_source += -2;
|
||||
|
||||
## Et Amymonen quoque que inferius artus
|
||||
|
||||
In hos parce generoso et quod, Latonam hoc levis hausta me tamen ingrate lumina.
|
||||
Pia tibi flumen priora solitam colorum ille matutinaeque posse! Ergo servatae
|
||||
latet mirabere, est vocat nervos ingreditur tam Phinea hac longe.
|
||||
|
||||
Post virgo? Cava coepti, liquido agros. Humano ducta inritata India. Porrexit
|
||||
tibi, in [nitebat variarum tenebat](http://www.wedrinkwater.com/) dixit
|
||||
testudine me mare per sucosque ut petitos passa temploque spesque, calculus.
|
||||
|
||||
## Usum harundine coniugis notae nono
|
||||
|
||||
Cura lacrimas; et socio, Troum? Solebat nudaeque amor, auxilio esse; partem
|
||||
finxit minimamque. Novo toro primaeque et quamvis quae futura simulat, vos posse
|
||||
tubere. Hominum et meque deum iter: quam cretus, Picus.
|
||||
|
||||
1. Igitur quae corpus
|
||||
2. Permanet ambage et pecudes dumque moenia scelus
|
||||
3. Dederant cervice Iuppiter
|
||||
4. Dare externa instrumenta Cipe
|
||||
5. Humiles ambo deprensa quem mirabile cornua fidesque
|
||||
6. Urbes suum viderunt
|
||||
|
||||
## Vivitur notavit inferior praelata tarde et auguris
|
||||
|
||||
Id visura, animi opera: spatium nisi rident vacuas, graves est potuisse irae,
|
||||
casus arva, sunt. Dixit fratrem cervix! Ordine et iam, cum Bactrius templum,
|
||||
exhalantur curru cultosque dedit. Cognovit tenderet in naribus perdere **eunt**,
|
||||
Dryantaque noverit quotiens luserit, summorum concussit spectat crinis
|
||||
**moriemur titulum aut** luce. Utque lucem nescio, armis dubitanti ramis
|
||||
cruciata maerent e stridore me vulgata, hospitio in *Perseus*, est femina.
|
||||
|
||||
- Agit quasque falsum
|
||||
- Huius vulgus virtute
|
||||
- Vota nam
|
||||
- Pararis nosti
|
||||
|
||||
Tua sed ut Telamon pudetque permulcetque Nessus rotae, tremuere. Finite
|
||||
inornatos nymphis patuit sine occupat nescio; meri inprudens genu equorum usus
|
||||
hoc inritus. Tecta annos Charaxi aquis caelataeque feror pugnantem satis
|
||||
attonitum potes. Videntur incipiat totidemque **viri incaluit** locum quo lumina
|
||||
conatur addidit. Musa illa intortos.
|
||||
|
||||
[Lorem markdownum rogavit]: http://imgur.com/
|
||||
[nitebat variarum tenebat]: http://www.wedrinkwater
|
||||
|
5
root/sites/offblast.org/index.md
Normal file
5
root/sites/offblast.org/index.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
welcome to go werc
|
||||
===================
|
||||
|
||||
add directories and files here.
|
||||
|
3
root/sites/offblast.org/test/apage.md
Normal file
3
root/sites/offblast.org/test/apage.md
Normal file
|
@ -0,0 +1,3 @@
|
|||
different test page
|
||||
==========
|
||||
|
2
root/sites/offblast.org/test/coolhtml.html
Normal file
2
root/sites/offblast.org/test/coolhtml.html
Normal file
|
@ -0,0 +1,2 @@
|
|||
<h1>HTML!</h1>
|
||||
|
3
root/sites/offblast.org/test/file.txt
Normal file
3
root/sites/offblast.org/test/file.txt
Normal file
|
@ -0,0 +1,3 @@
|
|||
THIS IS PLAIN TEXT!
|
||||
===================
|
||||
|
5
root/sites/offblast.org/test/index.md
Normal file
5
root/sites/offblast.org/test/index.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
test index
|
||||
==========
|
||||
|
||||
testing 1 2 3
|
||||
|
2
root/sites/tst.cat-v.org/_werc/config
Normal file
2
root/sites/tst.cat-v.org/_werc/config
Normal file
|
@ -0,0 +1,2 @@
|
|||
masterSite=default.cat-v.org
|
||||
siteTitle='Werc Test Suite'
|
3
root/sites/tst.cat-v.org/apps/blagh/_werc/config
Normal file
3
root/sites/tst.cat-v.org/apps/blagh/_werc/config
Normal file
|
@ -0,0 +1,3 @@
|
|||
conf_enable_blog
|
||||
conf_blog_pubsubdub_hub='http://pubsubhubbub.appspot.com/'
|
||||
|
1
root/sites/tst.cat-v.org/apps/bridge/a/_werc/config
Normal file
1
root/sites/tst.cat-v.org/apps/bridge/a/_werc/config
Normal file
|
@ -0,0 +1 @@
|
|||
conf_enable_comments -a
|
4
root/sites/tst.cat-v.org/index.md
Normal file
4
root/sites/tst.cat-v.org/index.md
Normal file
|
@ -0,0 +1,4 @@
|
|||
Werc Test Suite
|
||||
===============
|
||||
|
||||
This site contants sample/test content for the werc web anti-framework.
|
3
root/sites/tst.cat-v.org/titles/dashed-title.md
Normal file
3
root/sites/tst.cat-v.org/titles/dashed-title.md
Normal file
|
@ -0,0 +1,3 @@
|
|||
This page has an all-lower case dashed title.
|
||||
|
||||
The correct page title should be: `Dashed Title`.
|
3
root/sites/tst.cat-v.org/titles/under_title.md
Normal file
3
root/sites/tst.cat-v.org/titles/under_title.md
Normal file
|
@ -0,0 +1,3 @@
|
|||
This page has an all-lower case underscore separated title.
|
||||
|
||||
The correct page title should be: `Under Title`.
|
7
root/sites/werc.cat-v.org/_werc/config
Normal file
7
root/sites/werc.cat-v.org/_werc/config
Normal file
|
@ -0,0 +1,7 @@
|
|||
masterSite=default.cat-v.org
|
||||
siteTitle='werc'
|
||||
siteSubTitle='Bringing minimalism and sanity to the web'
|
||||
conf_enable_comments
|
||||
conf_enable_wiki
|
||||
|
||||
#ll_add handlers_body_head echo '<div style="text-align:right"><script type="text/javascript" src="http://www.reddit.com/r/programming/button.js?t=1"></script></div>'
|
11
root/sites/werc.cat-v.org/apps/_footer.md
Normal file
11
root/sites/werc.cat-v.org/apps/_footer.md
Normal file
|
@ -0,0 +1,11 @@
|
|||
External Apps
|
||||
=============
|
||||
|
||||
This are some apps developed by werc users, to install them put them in your werc's `apps/` dir and enable them from any config file as usual.
|
||||
|
||||
* [Xibit](https://web.archive.org/web/20111231181538/http://xibit.soul9.org/): an image gallery app by written by soul9.
|
||||
* [SMAK](https://web.archive.org/web/20091231051800/http://www.anarchyinthetubes.com/hg/smak/): a "very simple" image gallery by yiyus.
|
||||
* [hgwerc](https://web.archive.org/web/20091106041738/http://www.anarchyinthetubes.com/hg/hgwerc/): a wrapper around the mercurial web interface to integrate it into werc sites, also by yiyus.
|
||||
* [scrappydog](http://code.google.com/p/scrappydog/): A werc based online scrapbook by maht.
|
||||
* [flip](https://web.archive.org/web/20120330121431/http://www.anarchyinthetubes.com/hg/flip/): A web interface to view PDFs, by yiyus.
|
||||
* [barf](https://code.9front.org/hg/barf): blog, image, log, paste sites with pagination and tagging, by sl.
|
5
root/sites/werc.cat-v.org/apps/_header.md
Normal file
5
root/sites/werc.cat-v.org/apps/_header.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
Werc Apps
|
||||
=========
|
||||
|
||||
Werc includes the following 'apps' by default that any site can enable usually by executing a function of the form `conf_enable_myapp` in any given `_werc/config` file.
|
||||
|
59
root/sites/werc.cat-v.org/apps/blagh/index.md
Normal file
59
root/sites/werc.cat-v.org/apps/blagh/index.md
Normal file
|
@ -0,0 +1,59 @@
|
|||
Blagh - A Blogging engine for people who hate blogs
|
||||
===================================================
|
||||
|
||||
Blagh is a werc app that implements a blogging engine.
|
||||
|
||||
Some features include:
|
||||
|
||||
* File based, database free.
|
||||
* History browsing.
|
||||
* Atom, JSON, and RSS feeds.
|
||||
* Server-side feed 'aggregation' (merge multiple blogs into a single one).
|
||||
* Comments using [bridge](../bridge/)
|
||||
* Markdown formatting.
|
||||
|
||||
Possible alternative names: Blag, Blah, Bragg.
|
||||
|
||||
Posting
|
||||
-------
|
||||
|
||||
New pots can be created in at least two different ways: using the web interface (if you have logged in and your user or groups are in `$conf_blog_editors`) or from the command line using the script at `bin/aux/bpst.rc`. This script will, optionally, take a file as an argument using the `-f` switch. It will open that file in your `$EDITOR` or create a new temporary file if the `-f` switch is omitted. When you have finished editing the file, the script will call `ispell` (so you may want to install that as well) to check for spelling errors. Once that has completed a new directory structure will be created in your blog's root directory as a hidden folder named after the current year (as detected by `date`). You can inspect this directory structure for continuity and `mv` it to unhide it when you are satisfied. You are encouraged to read the source of that very simple script, and you shall see that it is trivial to create new posts by simply using `mkdir` and `echo`.
|
||||
|
||||
Configuration options
|
||||
---------------------
|
||||
|
||||
This are options you can set in your _werc/config
|
||||
|
||||
### `conf_enable_blog` *[blog dirs]*
|
||||
|
||||
Setup a blog in this dir. By default the blog contents will only include posts stored in this dir, if you pass any arguments the posts in the various dirs will be aggregated in this feed.
|
||||
|
||||
Examples:
|
||||
|
||||
# This will setup a blog in this dir that includes only posts in this dir.
|
||||
conf_enable_blog
|
||||
|
||||
# This will create a blog that aggregates all the posts in all blog dirs in any users/ sub dir.
|
||||
conf_enable_blog users/*/blog
|
||||
|
||||
### `conf_blog_editors`=(*groups or users that will be allowed to make new blog posts*)
|
||||
|
||||
This is optional and by default set to the 'blog-editors' group.
|
||||
|
||||
### `conf_max_lines_per_post=`*[integer]*
|
||||
|
||||
This option may be added using the patch linked bellow. It defaults to `7` which **should** only include the page heading and the first two paragraphs of each post on the main blogroll(?) page. This makes many assumptions that should be noted. It just removes everything from `conf_max_lines_per_post` to the end of the file. Traditionally, line 1 is the H1 title and line 2 is the line of = required to tell mardown of it's importance. This then assumes that each paragraph is on a single line, which is not enforced by markdown. See it in action at <http://blog.senet.us>
|
||||
|
||||
[blagh-91a4597480a7-conf\_max\_lines\_per\_post.diff](https://gist.github.com/anjandev/c517e79042148c136b98334867c545d8) (1.2K) (20100114)
|
||||
|
||||
**Author:** A Momi <anjan@momi.ca>
|
||||
|
||||
See also:
|
||||
|
||||
* To edit blog posts you can use the functionality provided by [the dirdir app](../dirdir/).
|
||||
* Commenting can be handled by [the bridge app](../bridge/).
|
||||
|
||||
|
||||
|
||||
|
||||
|
13
root/sites/werc.cat-v.org/apps/bridge/index.md
Normal file
13
root/sites/werc.cat-v.org/apps/bridge/index.md
Normal file
|
@ -0,0 +1,13 @@
|
|||
Bridge
|
||||
======
|
||||
|
||||
Bridge is a comments/forum application for werc, which lets people post comments related to any existing document/element.
|
||||
|
||||
|
||||
Configuration options
|
||||
---------------------
|
||||
|
||||
### `conf_enable_comments` [-n] [*users and groups allowed to comment*]
|
||||
|
||||
This will enable comments in this directory and all sub-directories. `-n` enables commenting by unregistered users (their posts will be set aside for review and approval by administrators).
|
||||
|
48
root/sites/werc.cat-v.org/apps/dirdir/index.md
Normal file
48
root/sites/werc.cat-v.org/apps/dirdir/index.md
Normal file
|
@ -0,0 +1,48 @@
|
|||
DirDir - A directory-oriented WikiWiki
|
||||
======================================
|
||||
|
||||
DirDir is the next generation [diri wiki](http://repo.cat-v.org/diri/), now implemented on top of werc and
|
||||
taking advantage of its user, site management frameworks and other
|
||||
infrastructure.
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
DirDir is still somewhat experimental, but already all features diri had, plus some extras thanks to werc's power:
|
||||
|
||||
* Hierarchical organization.
|
||||
* Markdown formatting.
|
||||
* Easily customizable templates
|
||||
* Simple and fine grained user permisions system.
|
||||
* Completely database free.
|
||||
* All needed to setup diridiri is to set a flag in your _werc/config file.
|
||||
* Automatically wiki-fy existing werc documents.
|
||||
* Implemented in about two dozen lines of rc scripts.
|
||||
|
||||
|
||||
Documentation
|
||||
-------------
|
||||
|
||||
Just login, go to any page, and click the `Edit` button.
|
||||
|
||||
To create a new page, go to the address where you want to create the new page, click `Edit`, enter the initial contents, `Save`, and you are done.
|
||||
|
||||
|
||||
Status
|
||||
------
|
||||
|
||||
Mostly usable, all basic features already implemented in the latest werc source
|
||||
tree.
|
||||
|
||||
|
||||
TODO
|
||||
----
|
||||
|
||||
* Do some markdown preprocessing, for example: `[[Foo Bar]]` -> `[Foo Bar](foo-bar)`
|
||||
|
||||
|
||||
About the name
|
||||
--------------
|
||||
|
||||
DirDir is a pun on its predecessor diri and WikiWiki, and [Dirdir is also the title of a novel](http://www.amazon.com/gp/product/0879974788?ie=UTF8&tag=catv-20&linkCode=as2&camp=1789&creative=390957&creativeASIN=0879974788) by science fiction and literature grand master [Jack Vance](http://www.amazon.com/gp/redirect.html?ie=UTF8&location=http%3A%2F%2Fwww.amazon.com%2Fs%3Fie%3DUTF8%26redirect%3Dtrue%26search-type%3Dss%26index%3Dbooks%26ref%3Dntt%255Fathr%255Fdp%255Fsr%255F1%26field-author%3DJack%2520Vance&tag=catv-20&linkCode=ur2&camp=1789&creative=39095).
|
||||
|
39
root/sites/werc.cat-v.org/apps/duckduckgo/index.md
Normal file
39
root/sites/werc.cat-v.org/apps/duckduckgo/index.md
Normal file
|
@ -0,0 +1,39 @@
|
|||
duckduckgo - Simple sitesearch using DuckDuckGo.com
|
||||
===================================
|
||||
|
||||
duckduckgo is a very simple app that allows you to redirect a path
|
||||
(by default /_search/) to a query to duckduckgo.com restricted to
|
||||
your site.
|
||||
|
||||
Currently, to change that path requires editing the app. In the
|
||||
future, the path will be a configuration option.
|
||||
|
||||
Configuration
|
||||
-------------
|
||||
|
||||
First, create the search path and the _werc directory under it:
|
||||
|
||||
mkdir -p /www/werc/sites/MYSITE/_search/_werc/
|
||||
|
||||
Then, enable the duckduckgo app in that directory:
|
||||
|
||||
echo 'conf_enable_duckduckgo' > /www/werc/sites/MYSITE/_search/_werc/config
|
||||
|
||||
Next, deploy the search form somewhere on your site. This example puts
|
||||
it in your footer:
|
||||
|
||||
mkdir -p /www/werc/sites/MYSITE/_werc/lib/
|
||||
cp /www/werc/apps/search/footer.inc.sample /www/werc/sites/MYSITE/_werc/lib/footer.inc
|
||||
|
||||
Demo
|
||||
----
|
||||
|
||||
For a demo of this app, see the footer of your favorite cat-v.org site.
|
||||
|
||||
TODO
|
||||
----
|
||||
|
||||
* Make the search path a configuration option
|
||||
* Provide a template for non-footer deployment
|
||||
* Enable the search path itself to serve a search form to GET requests
|
||||
|
34
root/sites/werc.cat-v.org/apps/wman/index.md
Normal file
34
root/sites/werc.cat-v.org/apps/wman/index.md
Normal file
|
@ -0,0 +1,34 @@
|
|||
wman - A Web Interface to Man Pages
|
||||
===================================
|
||||
|
||||
Wman is an app that allows you to export Unix and Plan 9-style man pages. It
|
||||
can do this directly, without need to generate static html versions and will
|
||||
automatically pick updates and new man pages.
|
||||
|
||||
It is also fairly smart in generating links for man page references.
|
||||
|
||||
Configuration
|
||||
-------------
|
||||
|
||||
To display a collection of man pages in a desired path you can use the following config directive:
|
||||
|
||||
conf_enable_wman /usr/share/man
|
||||
|
||||
This will allow you to browse the man pages under /usr/share/man.
|
||||
|
||||
For man pages organized in the traditional unix structure `manN/foo.N` where N is the section number, set in your config file:
|
||||
|
||||
wman_unix_mode=1
|
||||
|
||||
Demo
|
||||
----
|
||||
|
||||
For a demo of this app see [man.cat-v.org](http://man.cat-v.org).
|
||||
|
||||
TODO
|
||||
----
|
||||
|
||||
* We don't handle compressed man pages, but this should be trivial to add.
|
||||
* Unix systems might use different macros for their man pages.
|
||||
* Search (using keywords? Google? grep?)
|
||||
* Inferno contains man pages named like 'foo-0intro', which are refered as foo-intro(X), should automatically add (or remove) the extra '0' (Examples: sys-intro(2) and draw-intro(2)).
|
21
root/sites/werc.cat-v.org/development/index.md
Normal file
21
root/sites/werc.cat-v.org/development/index.md
Normal file
|
@ -0,0 +1,21 @@
|
|||
Werc Development
|
||||
================
|
||||
|
||||
The latest dev code is available in the werc mercurial repo: <https://code.9front.org/hg/werc>
|
||||
|
||||
|
||||
Version Numbering and Branching Rules
|
||||
-------------------------------------
|
||||
|
||||
There is no such thing! Originally a convention similar to that of the Linux kernel was used, but it is easier to do incremental work on a single branch.
|
||||
|
||||
For radical or experimental changes the `werc-dev` branch might be used, but at the moment it is outdated.
|
||||
|
||||
Bug reports, feature requests, bug fixes and other patches are all very welcome, just send them to the [werc mailing list](http://lists.9front.org).
|
||||
|
||||
|
||||
See Also
|
||||
--------
|
||||
|
||||
* The [Roadmap](roadmap).
|
||||
* [TODO](todo) list.
|
67
root/sites/werc.cat-v.org/development/roadmap.md
Normal file
67
root/sites/werc.cat-v.org/development/roadmap.md
Normal file
|
@ -0,0 +1,67 @@
|
|||
Development Roadmap
|
||||
===================
|
||||
|
||||
The versioning scheme is a mess, originally even minor version numbers were
|
||||
supposed to be stable and odd ones development branches, but turns out that for
|
||||
the most part it is easier to do incremental development instead of keeping
|
||||
'dev' and 'stable' branches.
|
||||
|
||||
A development branch might be added in the future if the changes are radical
|
||||
enough and break backwards compatibility in some important way. For this the
|
||||
deprecated and currently outdated `werc-dev` mercurial repo will be used.
|
||||
|
||||
|
||||
Werc 1.5.x, current stable branch
|
||||
----------
|
||||
|
||||
Planned major changes in 1.5
|
||||
|
||||
* <strike>Include required p9p binaries in standard distribution (or with some easy to deploy packaging).</strike>
|
||||
* New/rewritten css layout, using html5 flexbox [*Done*]
|
||||
* File upload support [*Code contributed by maht, needs integration*]
|
||||
* OpenID support [*Code contributed by maht, also needs integration*]
|
||||
* More complete test suite. [*See: <http://tst.cat-v.org>*]
|
||||
* Integrate all changes from 9front live sites [*Done*]
|
||||
* Add rc-httpd [*Done*]
|
||||
* Add optional headers.tpl to site-specific templates in _werc/lib/ [*Done*]
|
||||
* Add apps/mdir [*Code contributed by khm, needs integration*]
|
||||
* Add apps/paste [*Code contributed by khm, rewrite to use apps/upload*]
|
||||
|
||||
|
||||
Werc 1.4.x, previous stable branch
|
||||
---------------------------------
|
||||
|
||||
* Mostly bugfixes, documentation work, and minor improvements.
|
||||
|
||||
|
||||
Werc 1.2.x
|
||||
----------
|
||||
|
||||
* Only security fixes.
|
||||
|
||||
|
||||
Werc 1.1.x dev branch
|
||||
---------------------
|
||||
|
||||
* Convert all templates and pages to HTML 5. [*Done*]
|
||||
* Include new markdown implementation in pure awk by yuyis.[*Done*]
|
||||
* Native Plan 9 httpd works out of the box. [*Mostly done*]
|
||||
* Support for Google's Pubsubhubbub. [*Experimental implementation already done*]
|
||||
* Include test suite/site (also to be hosted at http://tst.cat-v.org) [*In Progress*]
|
||||
|
||||
|
||||
Werc 1.0.x
|
||||
----------
|
||||
|
||||
* Abandoned, please upgrade.
|
||||
|
||||
|
||||
-----------------------------------------------------
|
||||
|
||||
Werc 2.0 Plans
|
||||
--------------
|
||||
|
||||
* Big redesigns / rewrites.
|
||||
* Any non-backwards compatible changes.
|
||||
* Bring some sanity to the function/config-variable naming insanity.
|
||||
* Nothing else planned yet.
|
88
root/sites/werc.cat-v.org/development/todo.md
Normal file
88
root/sites/werc.cat-v.org/development/todo.md
Normal file
|
@ -0,0 +1,88 @@
|
|||
Plans and Ideas for the Future
|
||||
==============================
|
||||
|
||||
This page lists various assorted ideas and features that have been proposed at
|
||||
some point or another, nothing (except fixing the listed bugs) is assured to be
|
||||
implemented, many things here might turn out to be bad ideas.
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
* Review ideas from: http://www.w3.org/TR/chips/ and http://www.w3.org/Provider/Style/URI and see if we can do better.
|
||||
* Canonize and redirect all requests, we already do this for things like missing or trailing /, should do the same for /. and /./, etc. Deleting trailing . and , should make pasted urls in emails work as links (**Mostly done in RC1**)
|
||||
* Blog:
|
||||
* Comment threading.
|
||||
* Some form of pagination (taking advantage of history browsing.) (**Partially done**)
|
||||
* Sitemaps:
|
||||
* Index pages should be used for description of directories.
|
||||
* Cache web sitemap generation. (**Done in RC0**)
|
||||
* Layout improvements:
|
||||
* Need to find a way to rig the order of items in the sidebar.
|
||||
* Right sidebar.
|
||||
* Top+left/right nav vars (breadcrumbs at the top, current dir listing on the side)
|
||||
* Make it easier to disable all sidebars and headers/footers, eg., for full screen mode.
|
||||
* More testing and optimizations for mobile browsers, eg., http://www.operamini.com/demo/ Left sidebar had some minor issues in cellphones at some point.
|
||||
* Better page titles (include whole path hierarchy?) (**Partially done, is it good enough now?**)
|
||||
* Allow utf-8 characters in path elements (need to make sure this is safe, and not sure how useful it will be)
|
||||
* General code:
|
||||
* Write a regression test suite. (*Started*)
|
||||
* Replace all references to non p9p/p9 programs (*Done?*)
|
||||
* Document better the 'API' for sub-apps, both a set of environment vars apps can rely on (and in some cases set) and functions they can call (WIP).
|
||||
* Better generation of descriptive HTML META tags, eg.,: {META name="description" content="This is the Google Summer of Code blog for Plan9 and Inferno projects."} {META name="keywords" content="google, summer of code, inferno, plan9, programming"}
|
||||
* Should add werc to certain wikipedia lists:
|
||||
* `http://en.wikipedia.org/wiki/List_of_content_management_systems`
|
||||
* `http://en.wikipedia.org/wiki/Comparison_of_wiki_software`
|
||||
* Include txt2tags as builtin alternative to markdown.
|
||||
* Spam protection:
|
||||
* Mathematic pseudo-CAPTCHA ala WP's 'Math Comment Spam Protection Plugin'.
|
||||
* kfx (via cinap) suggests you just put a hidden text input box (or textarea?), "Dont write in this input box: [ ..... ]", if the bots fill it out ignore the post
|
||||
|
||||
|
||||
|
||||
Future Plans and Blue Sky
|
||||
--------------------------
|
||||
|
||||
* Wanted [apps](/apps/):
|
||||
* Tagging, eg., append to _werc/tags
|
||||
* Related links sidebar generation.
|
||||
* [Bug/issue tracking app](/apps/gregor/).
|
||||
* Hg/git repository browser.
|
||||
* Implement AtomPub.
|
||||
|
||||
* Further modularization and extensibility (meta-templates) (Is the new app framework enough for this?)
|
||||
* A way to wrap external cgi applications (eg., existing hg/git browser)
|
||||
* A way to generate static sites (ie., use werc as an offline templating system)
|
||||
* [9P](http://9p.cat-v.org) interface.
|
||||
* New (simplified) markdown implementation, ideally in C or awk (maybe smu/libsmu by gottox?), yiyus great md2html.awk is a great start!
|
||||
* Simplified
|
||||
* Tables
|
||||
* Images
|
||||
* Autogenerated anchors/navigation boxes
|
||||
* No inline html
|
||||
|
||||
Similar frameworks to be investigated and mined for good ideas to steal:
|
||||
|
||||
* TinyTim: http://www.reddit.com/r/programming/duplicates/dbaee/
|
||||
* nanoblogger: http://nanoblogger.sourceforge.net/
|
||||
|
||||
|
||||
Known Bugs
|
||||
----------
|
||||
|
||||
* It seems that certain chars are not propely encoded in cookies, possibly broken chars: :&%[+ Fix should go in cgilib.rc^set_cookie (Have to figure out the proper way to scape cookie strings first)
|
||||
* If a dir under apps/ doesn't contain an app.rc file, werc fails to start. A possible fix would be to replace $werc_apps default with `apps/*/app.rc` instead of `apps/*/`, this would be backwards incompatible, but I doubt anyone uses that option.
|
||||
* Links in Blagh feeds become confused if markdown 'references' are used, markdown references suck, but I guess we need to address this somehow...
|
||||
* Somewhat similarly to the abouve, relative urls in imgs, links, etc. can easily break when used in Blagh posts, so it is not all markdown's fault.
|
||||
* .md files of the following form, without a new line after the last = seem to cause problems in some setups:
|
||||
|
||||
Foo Bar
|
||||
=======
|
||||
|
||||
|
||||
|
||||
Fixed or WFM Bugs
|
||||
-----------------
|
||||
|
||||
* Sitemap can handle $dirfilter inconsistently from other places (**fixed**).
|
||||
* Finding directories that are inaccessible (-rx) can generate an infinite loop (**Works for me? Fixed with new menu code?**)
|
||||
* Some cat-v.org bits still left over here and there, should make them configurable (1.0 blocker) (**fixed**?)
|
1
root/sites/werc.cat-v.org/docs/_werc/config
Normal file
1
root/sites/werc.cat-v.org/docs/_werc/config
Normal file
|
@ -0,0 +1 @@
|
|||
conf_perm_redirect _ -
|
68
root/sites/werc.cat-v.org/docs/config-options.md
Normal file
68
root/sites/werc.cat-v.org/docs/config-options.md
Normal file
|
@ -0,0 +1,68 @@
|
|||
Werc Configuration Options
|
||||
==========================
|
||||
|
||||
You can also find a description of some basic config options in the `etc/initrc` file itself.
|
||||
|
||||
General Setup Options
|
||||
--------------------
|
||||
|
||||
* `formatter` - Command to use for document formatting (usually some form of markdown), should be able to take input both from file names passed as arguments or from stdin if no file names are provided. By default: `formatter=(fltr_cache md2html.awk)`
|
||||
|
||||
|
||||
Titles and Metadata
|
||||
-------------------
|
||||
|
||||
Variables:
|
||||
|
||||
* Page title:
|
||||
* siteTitle
|
||||
* siteSubTitle
|
||||
|
||||
* Html header meta tags:
|
||||
* meta_description - `<meta name="description" ...`
|
||||
* meta_keywords - `<meta name="keywords" ...`
|
||||
* extraHeaders - Raw extra html headers, the content of this var will be inserted inside the `<head>` tag..
|
||||
|
||||
|
||||
Sidebar and Navigation
|
||||
----------------------
|
||||
|
||||
Variables:
|
||||
|
||||
* sideBarNavTitle
|
||||
|
||||
Functions:
|
||||
|
||||
* `conf_hide_paths [path_patterns ...]` - Hide the given patterns from navigation menu, sitemap and dir listing (do *not* depend on this for security!).
|
||||
|
||||
HTTP Control
|
||||
------------
|
||||
|
||||
Variables:
|
||||
|
||||
* extraHttpHeaders - Raw HTTP headers to be added to response.
|
||||
|
||||
Functions:
|
||||
|
||||
* `conf_perm_redirect [pattern] destination` - If pattern is provided, match it against the requested url, and replace the match with `destination`; ie., *s/pattern/destination/.
|
||||
|
||||
|
||||
Access Control and Permissions
|
||||
------------------------------
|
||||
|
||||
The permissions system is very flexible, for example to only allow access to members of the group 'editors' you can do something like:
|
||||
|
||||
switch ($req_path) {
|
||||
case /_users/login
|
||||
case /pub/*
|
||||
case /robots.txt
|
||||
case *
|
||||
if(! check_user editors)
|
||||
perm_redirect /_users/login
|
||||
}
|
||||
|
||||
|
||||
To automatically redirect users without permission to the login page if they are not members of the group 'editors'.
|
||||
|
||||
See also [the documentation on user and group management](user_management).
|
||||
|
15
root/sites/werc.cat-v.org/docs/css-style.md
Normal file
15
root/sites/werc.cat-v.org/docs/css-style.md
Normal file
|
@ -0,0 +1,15 @@
|
|||
Custom CSS Stylesheets
|
||||
=====================
|
||||
|
||||
If you create a file under your site's dir at _werc/pub/style.css it will be included automatically after the standard werc stylesheet.
|
||||
|
||||
You can copy pub/style/style.css and customize it, or you can take a simpler file and just change the main color theme.
|
||||
|
||||
Here is an example of how to set the main werc colors:
|
||||
|
||||
|
||||
header nav { background-color: rgb(100,135,220); color: white; }
|
||||
header h1 { background-color: #ff6d06; color: black; }
|
||||
body > nav > div { border-bottom: 1px solid #ddd; }
|
||||
body > nav > div a { color: rgb(0, 102, 204); }
|
||||
body > nav > div a:hover { color: white; background-color: rgb(100,135,220); }
|
29
root/sites/werc.cat-v.org/docs/dir-listings.md
Normal file
29
root/sites/werc.cat-v.org/docs/dir-listings.md
Normal file
|
@ -0,0 +1,29 @@
|
|||
Autogenerated Directory Listings
|
||||
================================
|
||||
|
||||
If a directory has no `index.md`, `index.html` or `index.txt` and has no other
|
||||
*main handler* set up by a [werc app](/apps/), the default directory listing
|
||||
handler is used.
|
||||
|
||||
The default directory handler simply displays the path to the directory, and a
|
||||
list of links to all files and dirs located at this path.
|
||||
|
||||
|
||||
Header and footer
|
||||
-----------------
|
||||
|
||||
If a `_header.md` or `_footer.md` files are found in the directory, their
|
||||
contents will be displayed in the corresponding sections before and after
|
||||
the directory contents.
|
||||
|
||||
|
||||
Tuning the item's order
|
||||
------------------------
|
||||
|
||||
You can set the `dir_listing_ls_opts` config variable in the dir's corresponding _werc/config to change the way items will be ordered.
|
||||
|
||||
For example to list items in reverse chronological order simply add:
|
||||
|
||||
dir_listing_ls_opts=( -t )
|
||||
|
||||
The options taken are [the standard Plan 9 ls(1) flags](http://man.cat-v.org/plan_9/1/ls).
|
56
root/sites/werc.cat-v.org/docs/rc-template-lang.md
Normal file
56
root/sites/werc.cat-v.org/docs/rc-template-lang.md
Normal file
|
@ -0,0 +1,56 @@
|
|||
The Rc Template Language
|
||||
========================
|
||||
|
||||
Implemented by Kris, thanks!
|
||||
|
||||
Basic syntax:
|
||||
|
||||
* Lines starting with % are executed as rc commands, the resulting output is inserted in the document.
|
||||
* use %{ and %} to delimit multi line sections of rc code (note the lack of space between % and { or }!
|
||||
* To 'inline' the value of an environment variable use `%($my_var%)`
|
||||
|
||||
That is basically it!
|
||||
|
||||
For further documentation on rc see:
|
||||
|
||||
* [The rc(1) man page from Plan 9](http://man.cat-v.org/plan_9/1/rc).
|
||||
* [The rc shell paper by Tom Duff](http://rc.cat-v.org).
|
||||
|
||||
|
||||
Examples
|
||||
--------
|
||||
|
||||
Loops
|
||||
|
||||
<ul>
|
||||
% for(i in a b c) {
|
||||
% echo '<li>'$i'</li>'
|
||||
% }
|
||||
</uL>
|
||||
|
||||
Can also be writen as:
|
||||
|
||||
<ul>
|
||||
%{
|
||||
for(i in a b c) {
|
||||
echo '<li>'$i'</li>'
|
||||
}
|
||||
%}
|
||||
</uL>
|
||||
|
||||
and is equivalent to:
|
||||
|
||||
<ul>
|
||||
% for(i in a b c) {
|
||||
<li>%($i%)</li>
|
||||
% }
|
||||
</uL>
|
||||
|
||||
All three code examples result in this output:
|
||||
|
||||
<ul>
|
||||
<li>a</li>
|
||||
<li>b</li>
|
||||
<li>c</li>
|
||||
</ul>
|
||||
|
54
root/sites/werc.cat-v.org/docs/site-customization.md
Normal file
54
root/sites/werc.cat-v.org/docs/site-customization.md
Normal file
|
@ -0,0 +1,54 @@
|
|||
Site Customization
|
||||
==================
|
||||
|
||||
To change any of the default templates or include files found in /lib/ simply copy them from /lib/ to your site's _werc/lib/ and edit at will.
|
||||
|
||||
To change any of the templates found in /tpl/ (e.g. sitemap.tpl), copy the file to your site's root (e.g. /sites/foo.bar.com/sitemap.tpl) and then edit.
|
||||
|
||||
File Types
|
||||
----------
|
||||
|
||||
* '.tpl' files are rc [template files](rc_template_lang).
|
||||
* '.inc' are text files that are inserted 'as is' without any extra processing.
|
||||
|
||||
Site Groups
|
||||
-----------
|
||||
|
||||
Site configuration and customization and be 'grouped' to allow a shared set of templates among a specific group of sites (useful for sets of sub-domains for example).
|
||||
|
||||
Simply set 'masterSite' configuration variable to the name of the site you want to 'inherit' templates, style and configuration from.
|
||||
|
||||
For example, if we have two sites bar.com and foo.bar.com, and in sites/foo.bar.com/_werc/conf we add:
|
||||
|
||||
masterSite=bar.com
|
||||
|
||||
When a template (eg., 404.tpl) is requested it will be looked up first in /sites/foo.bar.com/_werc/lib/404.tpl, if that fails then in /sites/bar.com/_werc/lib/, and if that is missing too, the default /lib/404.tpl is used.
|
||||
|
||||
The same applies to .inc files.
|
||||
|
||||
|
||||
List of Template and Included Files
|
||||
-----------------------------------
|
||||
|
||||
Here is a list of the most commonly used templates and include files with their corresponding descriptions.
|
||||
|
||||
Include:
|
||||
|
||||
* top_bar.inc: The thin header at the top of every page, usually contains static links to other related sites or anything else you like.
|
||||
* footer.inc: Similar but at the bottom of every page, by default includes a link to the user login page.
|
||||
* headers.inc: Raw html headers to be included inside <head> tag.
|
||||
|
||||
Templates:
|
||||
|
||||
* default_master.tpl: This is the main template, which calls all the sidebar and other handlers and applications, usually you won't need to edit it unless you want to make changes to the layout or similar dramatic changes.
|
||||
* headers.tpl: Template for the default headers.
|
||||
* sitemap.tpl: Template for the sitemap page.
|
||||
* 404.tpl: Template for 'File Not Found' pages.
|
||||
|
||||
|
||||
See also
|
||||
--------
|
||||
|
||||
* [CSS style sheets customization](css_style).
|
||||
|
||||
|
36
root/sites/werc.cat-v.org/docs/user-management.md
Normal file
36
root/sites/werc.cat-v.org/docs/user-management.md
Normal file
|
@ -0,0 +1,36 @@
|
|||
User and Group Management
|
||||
=========================
|
||||
|
||||
User account and group membership information are stored under `etc/users/`.
|
||||
|
||||
A user account consists of a directory under `etc/users/` that contains files with that users account information, the only required file is `password` containing a password for the user. For example:
|
||||
|
||||
% ls etc/users/
|
||||
eekee uriel yosyp
|
||||
% cat etc/users/uriel/password
|
||||
mypass
|
||||
|
||||
Users and groups share the same namespace, you can create a group the same way you create a user but instead of a 'password' file adding a 'members' file containing the names of the group members, one per line.
|
||||
|
||||
A 'user-group' directory can contain both a password and members file, in which case it will act concurrently as a user and as a group.
|
||||
|
||||
The group 'admin' is 'built-in' and any members in that group will have admin privileges for most werc apps by default.
|
||||
|
||||
Example
|
||||
-------
|
||||
|
||||
To create a user called [glenda](http://glenda.cat-v.org) that is a member of the group `rabbits` you can do:
|
||||
|
||||
% mkdir etc/users/glenda/
|
||||
% echo carrot > etc/users/glenda/password
|
||||
% mkdir -p etc/users/rabbits
|
||||
% echo glenda >> etc/users/rabbits/members
|
||||
|
||||
Utils
|
||||
-----
|
||||
|
||||
The script at bin/aux/addwuser.rc allows you to even more trivially add users.
|
||||
|
||||
addwuser.rc user_name user_pass [groups ...]
|
||||
|
||||
|
16
root/sites/werc.cat-v.org/docs/web-server-setup/_header.md
Normal file
16
root/sites/werc.cat-v.org/docs/web-server-setup/_header.md
Normal file
|
@ -0,0 +1,16 @@
|
|||
Setting Up Your HTTP Server to Run Werc
|
||||
=======================================
|
||||
|
||||
|
||||
Werc should work with any web server that supports the CGI interface, and a few
|
||||
that don't. Here are collected instructions and sample configurations for some
|
||||
of the most popular HTTP servers that people has used with werc.
|
||||
|
||||
In general setup consists of mapping all paths for a virtual host to the
|
||||
werc.rc script, usually in practice this means that the `document root` (or
|
||||
similar concept) for a virtual host is mapped to
|
||||
`/path/to/werc/sites/domain.name.com/`, and if no static file matches the
|
||||
request, control is handed to werc.rc, this allows the HTTP server to handle
|
||||
static files and werc to handle everything else (note that such a setup will
|
||||
expose your `_werc/config` files, which usually should not be a security
|
||||
issue).
|
93
root/sites/werc.cat-v.org/docs/web-server-setup/apache.md
Normal file
93
root/sites/werc.cat-v.org/docs/web-server-setup/apache.md
Normal file
|
@ -0,0 +1,93 @@
|
|||
Setup werc with Apache
|
||||
======================
|
||||
|
||||
Note: Apache 2.x configuration should be similar to 1.3.x, but Apache 2.x is not recommended due to unwindy complexity, please use a saner web server.
|
||||
|
||||
Apache 1.3.x: minimalist configuration
|
||||
======================================
|
||||
|
||||
No virtual hosts and let werc handle static files.
|
||||
|
||||
RewriteEngine On
|
||||
ServerName test.cat-v.org
|
||||
AddHandler cgi-script .rc
|
||||
|
||||
<Directory /var/www/werc/bin>
|
||||
Options ExecCGI
|
||||
</Directory>
|
||||
<IfModule mod_dir.c>
|
||||
DirectoryIndex /werc.rc
|
||||
</IfModule>
|
||||
|
||||
RewriteRule /werc.rc /var/www/werc/bin/werc.rc
|
||||
DocumentRoot /var/www/werc/bin/
|
||||
ErrorDocument 404 /werc.rc
|
||||
|
||||
|
||||
Apache 1.3.x: standard configuration
|
||||
====================================
|
||||
|
||||
This lets apache handle static files.
|
||||
|
||||
<VirtualHost *>
|
||||
|
||||
RewriteEngine On
|
||||
ServerName test.cat-v.org
|
||||
AddHandler cgi-script .rc
|
||||
|
||||
<Directory /var/www/werc/bin>
|
||||
Options ExecCGI
|
||||
</Directory>
|
||||
<IfModule mod_dir.c>
|
||||
DirectoryIndex /werc.rc
|
||||
</IfModule>
|
||||
|
||||
RewriteRule (.*) /var/www/werc/sites/%{HTTP_HOST}/$1
|
||||
|
||||
RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteRule .* /var/www/werc/bin/werc.rc
|
||||
|
||||
RewriteRule /werc.rc /var/www/werc/bin/werc.rc
|
||||
DocumentRoot /var/www/werc/bin/
|
||||
ErrorDocument 404 /werc.rc
|
||||
|
||||
</VirtualHost>
|
||||
|
||||
|
||||
Apache 1.3.x: advanced configuration
|
||||
====================================
|
||||
|
||||
|
||||
<VirtualHost *>
|
||||
|
||||
RewriteEngine On
|
||||
ServerName cat-v.org
|
||||
ServerAlias www.cat-v.org harmful.cat-v.org 9p.cat-v.org gsoc.cat-v.org doc.cat-v.org uriel.cat-v.org www.binarydream.org ninetimes.cat-v.org *.cat-v.org
|
||||
AddHandler cgi-script .rc
|
||||
AddHandler cgi-script .cgi
|
||||
<Directory /home/uriel/cat-v.org/bin>
|
||||
Options ExecCGI
|
||||
</Directory>
|
||||
<IfModule mod_dir.c>
|
||||
DirectoryIndex /werc.rc
|
||||
</IfModule>
|
||||
|
||||
RewriteRule ^/hg/(.*) /home/uriel/cat-v.org/bin/hgwebdir.cgi/$1 [L]
|
||||
|
||||
RewriteRule /pub/style/style.css /home/uriel/cat-v.org/pub/style/style.css [L]
|
||||
RewriteRule /pub/ /home/uriel/cat-v.org/pub/ [L]
|
||||
RewriteRule /favicon.ico /home/uriel/cat-v.org/pub/default_favicon.ico [L]
|
||||
|
||||
|
||||
RewriteRule (.*) /home/uriel/cat-v.org/sites/%{HTTP_HOST}/$1
|
||||
|
||||
RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteRule .* /home/uriel/cat-v.org/bin/werc.rc
|
||||
|
||||
RewriteRule /werc.rc /home/uriel/cat-v.org/bin/werc.rc
|
||||
DocumentRoot /home/uriel/cat-v.org/bin/
|
||||
ErrorDocument 404 /werc.rc
|
||||
|
||||
</VirtualHost>
|
||||
|
||||
|
14
root/sites/werc.cat-v.org/docs/web-server-setup/cgd.md
Normal file
14
root/sites/werc.cat-v.org/docs/web-server-setup/cgd.md
Normal file
|
@ -0,0 +1,14 @@
|
|||
cgd
|
||||
===
|
||||
|
||||
Cgd is a simple daemon written in [go](http://golang.org) that can
|
||||
serve a CGI script over HTTP or FastCGI. It only needs to know the
|
||||
location of the Plan 9 (9base, frontbase, or plan9port) binaries, and
|
||||
the location of the werc installation itself. There is no
|
||||
configuration file.
|
||||
|
||||
For example, to run werc under cgd on Plan 9:
|
||||
|
||||
PLAN9=/ cgd -c $werc/bin/werc.rc -w $werc/bin
|
||||
|
||||
Download it here: <https://code.9front.org/hg/cgd>
|
31
root/sites/werc.cat-v.org/docs/web-server-setup/cherokee.md
Normal file
31
root/sites/werc.cat-v.org/docs/web-server-setup/cherokee.md
Normal file
|
@ -0,0 +1,31 @@
|
|||
Configuring werc with Cherokee
|
||||
==============================
|
||||
|
||||
Contributed by sqweek, thanks!
|
||||
|
||||
Cherokee Version 0.7.1
|
||||
----------------------
|
||||
|
||||
vserver!default!rule!600!only_secure = 0
|
||||
vserver!default!rule!600!handler = cgi
|
||||
vserver!default!rule!600!handler!error_handler = 1
|
||||
vserver!default!rule!600!handler!check_file = 1
|
||||
vserver!default!rule!600!handler!script_alias =
|
||||
/usr/local/werc/bin/werc.rc
|
||||
vserver!default!rule!600!handler!pass_req_headers = 0
|
||||
vserver!default!rule!600!match = directory
|
||||
vserver!default!rule!600!match!directory = /code
|
||||
vserver!default!rule!600!match!final = 1
|
||||
|
||||
|
||||
Cherokee Version 0.5.3
|
||||
----------------------
|
||||
|
||||
Directory /code {
|
||||
Handler cgi {
|
||||
Scriptalias /usr/local/werc/bin/werc.rc
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Isn't progress wonderful?
|
16
root/sites/werc.cat-v.org/docs/web-server-setup/hiawatha.md
Normal file
16
root/sites/werc.cat-v.org/docs/web-server-setup/hiawatha.md
Normal file
|
@ -0,0 +1,16 @@
|
|||
Hiawatha Web Server Configuration
|
||||
---------------------------------
|
||||
|
||||
Contributed by sqweek, thanks!
|
||||
|
||||
This are the relevant bits:
|
||||
|
||||
CGIhandler = /usr/local/plan9/bin/rc:rc
|
||||
ExecuteCGI = yes
|
||||
RewriteURL = werc
|
||||
UrlRewrite {
|
||||
RewriteID = werc
|
||||
Match ^(/code|/index|/contact|/clique).* Rewrite /werc.rc
|
||||
Match ^/$ Rewrite /werc.rc
|
||||
}
|
||||
|
44
root/sites/werc.cat-v.org/docs/web-server-setup/lighttpd.md
Normal file
44
root/sites/werc.cat-v.org/docs/web-server-setup/lighttpd.md
Normal file
|
@ -0,0 +1,44 @@
|
|||
Setup werc with lighttpd
|
||||
========================
|
||||
|
||||
You will need to enable to the following modules: `mod_cgi`, `mod_alias` and `mod_rewrite` (for non-minimal configurations).
|
||||
|
||||
You can also find `mod_setenv` useful to change werc's environment ($PATH in perticular)
|
||||
|
||||
Minimal setup
|
||||
-------------
|
||||
This is the most minimal setup, for a single domain, and lets werc handle static files.
|
||||
|
||||
$HTTP["host"] =~ "^test\.cat-v\.org$" {
|
||||
index-file.names = ( )
|
||||
server.error-handler-404 = "/werc.rc"
|
||||
alias.url += ( "/werc.rc" => "/var/www/cat-v.org/bin/werc.rc" ) # Here use the path to werc.rc in your system.
|
||||
cgi.assign += ( ".rc" => "")
|
||||
server.dir-listing = "disable"
|
||||
}
|
||||
|
||||
Advanced setup
|
||||
--------------
|
||||
|
||||
A more ellaborate setup, using virtual hosts to handle multiple domains, and
|
||||
alias to let lighttpd handle static files. Also show how to add external cgi's
|
||||
to the setup, in this case Mercurial's web interface.
|
||||
|
||||
$HTTP["host"] =~ "^((harmful|9p|gsoc|doc|uriel|src|repo|www|)(\.|)cat-v\.org|(www\.)?binarydream.org|)$" {
|
||||
|
||||
index-file.names = ( )
|
||||
evhost.path-pattern = "/var/www/cat-v.org/sites/%3.%0/"
|
||||
server.error-handler-404 = "/werc.rc"
|
||||
|
||||
alias.url += ( "/pub/" => "/var/www/cat-v.org/pub/" )
|
||||
alias.url += ( "/favicon.ico" => "/var/www/cat-v.org/pub/default_favicon.ico" )
|
||||
alias.url += ( "/doc/" => "/var/www/cat-v.org/sites/doc.cat-v.org/" )
|
||||
alias.url += ( "/werc.rc" => "/var/www/cat-v.org/bin/werc.rc" )
|
||||
alias.url += ( "/debug.rc" => "/var/www/cat-v.org/bin/debug.rc" )
|
||||
cgi.assign += ( ".rc" => "")
|
||||
server.dir-listing = "disable"
|
||||
|
||||
cgi.assign += ( ".cgi" => "")
|
||||
url.rewrite-once = ( "/hg/(.*)" => "/hg/hgwebdir.cgi/$1" )
|
||||
alias.url += ( "/hg/" => "/var/www/cat-v.org/bin/" )
|
||||
}
|
96
root/sites/werc.cat-v.org/docs/web-server-setup/nginx.md
Normal file
96
root/sites/werc.cat-v.org/docs/web-server-setup/nginx.md
Normal file
|
@ -0,0 +1,96 @@
|
|||
Setup werc with NGINX
|
||||
=====================
|
||||
|
||||
You probably will want to to use fcgiwrap, called from spawn-fcgi or similar.
|
||||
|
||||
Here is an extremely basic nginx configuration, with this configuration static files will be handled by werc and not nginx, this is clearly dumb, but works:
|
||||
|
||||
worker_processes 1;
|
||||
|
||||
#error_log logs/error.log;
|
||||
#error_log logs/error.log notice;
|
||||
error_log logs/error.log info;
|
||||
|
||||
pid logs/nginx.pid;
|
||||
|
||||
events {
|
||||
worker_connections 1024;
|
||||
}
|
||||
|
||||
|
||||
http {
|
||||
include mime.types;
|
||||
default_type application/octet-stream;
|
||||
|
||||
#log_format main '$remote_addr - $remote_user [$time_local] "$request" '
|
||||
# '$status $body_bytes_sent "$http_referer" '
|
||||
# '"$http_user_agent" "$http_x_forwarded_for"';
|
||||
|
||||
#access_log logs/access.log main;
|
||||
|
||||
sendfile on;
|
||||
#tcp_nopush on;
|
||||
|
||||
#keepalive_timeout 0;
|
||||
keepalive_timeout 65;
|
||||
|
||||
#gzip on;
|
||||
|
||||
server {
|
||||
listen 80;
|
||||
server_name test.cat-v.org; # Replace with your domain name.
|
||||
|
||||
#charset utf-8;
|
||||
|
||||
#access_log logs/host.access.log main;
|
||||
|
||||
location / {
|
||||
|
||||
# FastCGI params, usually stored in fastcgi_params
|
||||
# and imported with a command like the following:
|
||||
#include fastcgi_params;
|
||||
|
||||
# Typical contents of fastcgi_params (inlined here):
|
||||
fastcgi_pass localhost:9000;
|
||||
|
||||
fastcgi_param QUERY_STRING $query_string;
|
||||
fastcgi_param REQUEST_METHOD $request_method;
|
||||
fastcgi_param CONTENT_TYPE $content_type;
|
||||
fastcgi_param CONTENT_LENGTH $content_length;
|
||||
|
||||
#fastcgi_param SCRIPT_FILENAME /var/www/werc/bin/werc.rc;
|
||||
fastcgi_param SCRIPT_NAME /var/www/werc/bin/werc.rc;
|
||||
#fastcgi_param SCRIPT_NAME $fastcgi_script_name;
|
||||
|
||||
fastcgi_param REQUEST_URI $request_uri;
|
||||
fastcgi_param DOCUMENT_URI $document_uri;
|
||||
fastcgi_param DOCUMENT_ROOT $document_root;
|
||||
fastcgi_param SERVER_PROTOCOL $server_protocol;
|
||||
|
||||
fastcgi_param GATEWAY_INTERFACE CGI/1.1;
|
||||
fastcgi_param SERVER_SOFTWARE nginx/$nginx_version;
|
||||
|
||||
fastcgi_param REMOTE_ADDR $remote_addr;
|
||||
fastcgi_param REMOTE_PORT $remote_port;
|
||||
fastcgi_param SERVER_ADDR $server_addr;
|
||||
fastcgi_param SERVER_PORT $server_port;
|
||||
fastcgi_param SERVER_NAME $server_name;
|
||||
fastcgi_param REMOTE_USER $remote_user;
|
||||
|
||||
#root /var/www/werc/sites/$server_addr; # XXX This doesn't work, not sure why :(
|
||||
root /;
|
||||
#index index.html index.htm;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Then you can use spawn-fcgi or similar to get wrapcgi going:
|
||||
|
||||
spawn-fcgi -a 127.0.0.1 -p 9000 -f /home/uriel/dvl/ext/fcgiwrap/fcgiwrap # Use the path to your fcgiwrap binary here
|
||||
|
||||
|
||||
Other Setups
|
||||
------------
|
||||
|
||||
More elaborate setups with direct handling of static files, caching, and multiple fcgi/cgi handlers should be easy, if you have any please post them to the werc9 mailing list.
|
60
root/sites/werc.cat-v.org/docs/web-server-setup/nhttpd.md
Normal file
60
root/sites/werc.cat-v.org/docs/web-server-setup/nhttpd.md
Normal file
|
@ -0,0 +1,60 @@
|
|||
Nhttpd/Nostromo Web Server Configuration for Werc
|
||||
==================================================
|
||||
|
||||
Contributed by nsz, thanks!
|
||||
|
||||
The last two sections are relevant: aliases (to make non-content site material,
|
||||
like css, available) and virtual hosts (the document root is set to `werc.rc`
|
||||
so it will handle every request).
|
||||
|
||||
# MAIN [MANDATORY]
|
||||
|
||||
servername main.host.com
|
||||
serveradmin admin[at]mail.com
|
||||
serverroot /var/nostromo
|
||||
servermimes conf/mimes
|
||||
logpid logs/nhttpd.pid
|
||||
logaccess logs/access_log
|
||||
docroot /var/nostromo/htdocs
|
||||
docindex index.html
|
||||
|
||||
# SETUID [RECOMMENDED]
|
||||
|
||||
user nhttpd
|
||||
|
||||
# BASIC AUTHENTICATION [OPTIONAL]
|
||||
#...
|
||||
|
||||
# SSL [OPTIONAL]
|
||||
#...
|
||||
|
||||
# CUSTOM RESPONSES [OPTIONAL]
|
||||
#...
|
||||
|
||||
# HOMEDIRS [OPTIONAL]
|
||||
#...
|
||||
|
||||
# ALIASES [OPTIONAL]
|
||||
|
||||
/pub /path/to/werc/pub
|
||||
# The following line doesn't work because nhttpd doesn't support file aliases yet.
|
||||
#/favicon.ico /path/to/werc/pub/default_favicon.ico
|
||||
|
||||
# VIRTUAL HOSTS [OPTIONAL]
|
||||
|
||||
vhost1.com /path/to/werc/bin/werc.rc
|
||||
vhost2.com /path/to/werc/bin/werc.rc
|
||||
#...
|
||||
|
||||
To use werc on `main.host.com` as well just set `docroot` to `/path/to/werc/bin/werc.rc`
|
||||
and set `docindex` to empty string.
|
||||
|
||||
There was a bug in nhttpd <=1.9, it did not set `SERVER_NAME` properly (left it `main.host.com`).
|
||||
To solve this problem just add a
|
||||
|
||||
SERVER_NAME=$HTTP_HOST
|
||||
|
||||
line somewhere at the top of `werc.rc`.
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,53 @@
|
|||
Setup werc with Plan 9's httpd
|
||||
==============================
|
||||
|
||||
|
||||
There are two main options, you can use Russ Cox's magic to cgi translator
|
||||
(found in his contrib dir as cgi.c), or you can use the following script which
|
||||
while simpler, it also lacks some features at the moment.
|
||||
|
||||
Thanks to soul9 for the original idea of wrapping werc in a shell script that
|
||||
would setup a cgi-like environment!
|
||||
|
||||
|
||||
#!/bin/rc
|
||||
|
||||
SERVER_NAME=$2
|
||||
REQUEST_URI=`{echo $*(15)}
|
||||
REQUEST_URI=$REQUEST_URI(2)
|
||||
REQUEST_URI=/
|
||||
REQUEST_METHOD=$*(16)
|
||||
PLAN9=/
|
||||
|
||||
|
||||
echo 'HTTP/1.0 200 Ok
|
||||
Connection: close
|
||||
Server: werc/9.9.9' # This is whatever you like
|
||||
|
||||
|
||||
cd /usr/web/bin/
|
||||
rfork
|
||||
/bin/rc < ./werc.rc >[2]/usr/glenda/tmp/w/log # Use whatever location you like to log stderr, but make sure it is writable by none.
|
||||
|
||||
Call this script werc-wrap, and put it in /rc/bin/ip/httpd/
|
||||
|
||||
Then in your /sys/lib/httpd.rewrite add a line like:
|
||||
|
||||
/w @/magic/werc-wrap
|
||||
|
||||
And this will run werc for all stuff under /w. Note that apparently httpd is
|
||||
incapable of internally remapping the root directory, so until a solution is
|
||||
found for this, you will have to keep your site in a sub-directory of the web
|
||||
server root.
|
||||
|
||||
In your /lib/namespace.httpd you probably will want to add something along the
|
||||
following lines to bind the werc directory into the httpd's namespace:
|
||||
|
||||
bind -b /usr/glenda/src/werc/ /usr/web/
|
||||
bind /usr/glenda/src/werc/bin/ /usr/web/magic/
|
||||
|
||||
|
||||
**Notes**: This is experimental and work in progress, there are a couple of issues
|
||||
with the werc code itself that might need fixing, in particular you will need
|
||||
to replace the '%($"extraHeaders%)' in lib/headers.tpl with '% echo
|
||||
$"extraHeaders' no clue why.
|
99
root/sites/werc.cat-v.org/index.md
Normal file
99
root/sites/werc.cat-v.org/index.md
Normal file
|
@ -0,0 +1,99 @@
|
|||
werc - A sane web anti-framework
|
||||
================================
|
||||
|
||||
Werc is a minimalist web anti-framework built following the [Unix](http://doc.cat-v.org/unix/) and [Plan 9](http://plan9.cat-v.org)
|
||||
*tool philosophy* of software design.
|
||||
|
||||
Werc avoids the pain of managing collections of websites and developing web
|
||||
applications.
|
||||
|
||||
* Database free, uses files and directories instead.
|
||||
* Written using [the rc shell](http://rc.cat-v.org), leveraging the standard Unix/Plan 9 command toolkit.
|
||||
* Minimize tedious work: eg., no need to ever write HTML, use markdown (or any other format) instead.
|
||||
* Very minimalist yet extensible codebase: highly functional core is 150 lines, with extra functionality in modular [apps](/apps/).
|
||||
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
Here are some of the features provided by werc:
|
||||
|
||||
* Good integration with pre-existing content, you can add HTML or plain text files and they will be seamlessly integrated with the rest of the site.
|
||||
* You can use your favorite tools (text editor, shell, file manager, etc) to edit, manipulate and manage data stored in werc.
|
||||
* Designed to manage any number of 'virtual' domains that share a common style and layout from a single werc installation.
|
||||
* Configuration and customization can be at at any level: global, per-domain-group, domain-wide, directory sub-tree, and single file.
|
||||
* Can trivially run multiple (customized) versions of werc side by side.
|
||||
* Very simple and flexible user management and permissions system.
|
||||
* Applications can be easily combined: eg., add comments to your blog or wiki by enabling the 'bridge' app; or by enabling the 'diridir' wiki convert any document tree into a wiki.
|
||||
* Can easily write werc 'apps' and extensions in *any* language! (But of course, rc is recommended).
|
||||
|
||||
|
||||
Install Requirements
|
||||
--------------------
|
||||
|
||||
All you need is some Plan 9 commands (cat, grep, sed, rc, etc.), and an HTTP
|
||||
server with CGI support.
|
||||
|
||||
Werc runs on any Unix-like system where [Plan 9 from User Space](https://9fans.github.io/plan9port/),
|
||||
[9base](https://tools.suckless.org/9base/),
|
||||
or [frontport](https://code.9front.org/hg/frontbase)
|
||||
are available (this includes Linux, \*BSD, OS X and Solaris), and on Plan 9.
|
||||
|
||||
Werc can use any HTTP server that can handle CGI, and has been tested with at
|
||||
least Apache, Lighttpd, Cherokee, nhttpd, Hiawatha, rc-httpd, cgd, and others.
|
||||
|
||||
Werc uses markdown by default (and the standard Perl markdown is included with
|
||||
the distribution), to format documents, but any other formatting system can be
|
||||
used.
|
||||
|
||||
|
||||
Source
|
||||
------
|
||||
|
||||
To get a copy of the latest development code using mercurial, do:
|
||||
|
||||
hg clone https://code.9front.org/hg/werc/
|
||||
|
||||
You can also [browse the online repository](https://code.9front.org/hg/werc/).
|
||||
|
||||
|
||||
Contact
|
||||
-------
|
||||
|
||||
For questions, suggestions, bug reports and contributing patches you can join
|
||||
the werc mailing list. To join, send a message with a body consisting only of the word _subscribe_ to werc-owner@cat-v.org. After you get the confirmation notice, you can post by sending messages to werc@cat-v.org.
|
||||
|
||||
To track commit messages, you can join the werc-commits mailing list. To join, send a message with a body consisting only of the word _subscribe_ to werc-commits-owner@cat-v.org.
|
||||
|
||||
On irc, join [#cat-v](irc://irc.freenode.org/cat-v) on irc.freenode.org
|
||||
|
||||
|
||||
License
|
||||
-------
|
||||
|
||||
Public domain, [because so called 'intellectual property' is an
|
||||
oxymoron](http://harmful.cat-v.org/economics/intellectual_property/).
|
||||
|
||||
Alternatively if your prefer it or your country's brain dead copyright law
|
||||
doesn't recognize the public domain werc is made available under the terms of
|
||||
the MIT and ISC licenses.
|
||||
|
||||
|
||||
Credits
|
||||
-------
|
||||
|
||||
Thanks to [Uriel](http://uriel.cat-v.org/) for creating werc.
|
||||
|
||||
Thanks to Kris Maglione (aka JG) for implementing rss feeds, for writing the
|
||||
awk rc-templating system, and other help and inspiration (some parts of the
|
||||
code were based on JG's diri wiki).
|
||||
|
||||
Thanks to Mechiel (aka oksel) for the md_cache script.
|
||||
|
||||
Thanks Garbeam (aka arg) for writing the original diri code and showing that
|
||||
writing complex web apps in rc was feasible.
|
||||
|
||||
Thanks to Ethan Gardner for writing rc-httpd.
|
||||
|
||||
And thanks to everyone else whom we may have forgotten and that has provided fixes
|
||||
and feedback.
|
8
root/sites/werc.cat-v.org/testimonials.md
Normal file
8
root/sites/werc.cat-v.org/testimonials.md
Normal file
|
@ -0,0 +1,8 @@
|
|||
Comments from Werc Fans
|
||||
=======================
|
||||
|
||||
*When people ask me what I look for in a woman, I'm going to say, "werc-like qualities".* -- shardz
|
||||
|
||||
*Okay, werc gets my official Mark of Sweetness. This is really damn nice.* -- Athas
|
||||
|
||||
*Thanks to [Uriel](http://uriel.cat-v.org) and co. for providing the wonderful werc framework.* -- sleepydog, maintainer of [Xpilot-AI](http://www.reddit.com/r/programming/comments/9m2nl/xpilotai_development_of_autonomous_agents_in/c0dch6s)
|
1
root/sites/werc.cat-v.org/wiki/_werc/config
Normal file
1
root/sites/werc.cat-v.org/wiki/_werc/config
Normal file
|
@ -0,0 +1 @@
|
|||
conf_enable_wiki
|
Loading…
Reference in a new issue