Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
A quick & dirty git-powered Sinatra wiki
Branch: master
Pull request Compare This branch is even with micahbrich:master.
Failed to load latest commit information.
public pinpricked
sinatra pinpricked
views pinpricked
.gitignore pinpricked
.htaccess pinpricked
Anne Get Your Gun.text pinpricked
README.textile constantly changing the readme
config.ru modified shebang
dispatch.fcgi modified shebang
git-wiki.rb modified shebang
index.text pinpricked

README.textile

moocha’s git-wiki

Forked from decklin’s

Features

  • Standalone Sinatra, no rack
  • Self-contained repository – wiki articles saved right inside
  • url’s under /pages
  • magic wiki links to link between articles
  • textile, instead of markdown. that’s just preference.
  • erb instead of haml. i don’t like haml
  • custom commit messages
  • revision history

To-Do

  • Revert links
  • attachments, somehow
  • Style it pretty
  • add RSS feeds
  • rename title
  • delete articles

Installation and Use

This particular git-wiki requires Sinatra, Grit, Haml, and RDiscount, all available
on RubyGems. Here’s how to create a new wiki and run it:

git clone git-wiki my-wiki

cd my-wiki

./git-wiki.rb # and point browser to http://localhost:4567/

You can still run git-wiki with Rack if you want; create a trivial
config.ru (`require ‘git-wiki’; run Sinatra::Application`) and then
run rackup.

Configuration

At the end of git-wiki.rb is a `configure` block (which applies to all
environments). Edit it, or copy it to your rackup script and override
the defaults. You can use this to set different wiki repositories for
development/testing/production if you want.

Caveats

Because we use Grit by modifying the workdir and then calling `git
add`, git-wiki must be run with a non-bare wiki repo. If you want to
clone this repo and then push to it, you should read the [Git FAQ
entry][faq] about the perils of pushing to a repo with a checked-out
workdir.

In practice, you will hopefully never edit the workdir of the “live”
repo directly, so ensuring that receive.denyNonFastForwards is turned
on and adding a post-update hook to reset the index is a reasonable
(if not very clean) work-around.

FAQ – http://git.or.cz/gitwiki/GitFaq#push-is-reverse-of-fetch

License

Copyright © 2008 Simon Rozet <Simon@Rozet.Name>

Copyright © 2009 Decklin Foster <Decklin@Red-Bean.Com>

DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE

Version 2, December 2004

Everyone Is Permitted to Copy and Distribute Verbatim or Modified
Copies of This License Document, and Changing It Is Allowed As Long
As the Name Is Changed.

TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION:

You Just Do What the Fuck You Want To.

Something went wrong with that request. Please try again.