Gollum is a simple wiki system built on top of Git that powers GitHub Wikis.
[Gollum](https://github.com/gollum/gollum) is a simple wiki system built on
top of Git that powers GitHub Wikis.
Gollum wikis are simply Git repositories that adhere to a specific format.
Gollum pages may be written in a variety of formats and can be edited in a
number of ways depending on your needs. You can edit your wiki locally:
Gollum-lib is the Ruby API that allows you to retrieve raw or formatted wiki
content from a Git repository, write new content to the repository, and collect
various meta data about the wiki as a whole.
* With your favorite text editor or IDE (changes will be visible after committing).
* With the built-in web interface.
* With the Gollum Ruby API.
Gollum follows the rules of [Semantic Versioning](http://semver.org/) and uses
Gollum-lib follows the rules of [Semantic Versioning](http://semver.org/) and uses
[TomDoc](http://tomdoc.org/) for inline documentation.
## SYSTEM REQUIREMENTS
- Python 2.5+ (2.7.3 recommended)
- Ruby 1.8.7+ (1.9.3 recommended)
- Unix like operating system (OS X, Ubuntu, Debian, and more)
- Will not work on Windows (because of [grit](https://github.com/github/grit))
## SECURITY
Don't enable `--custom-css` or `--custom-js` unless you trust every user who has the ability to edit the wiki.
A better solution with more security is being tracked in [#665](https://github.com/gollum/gollum/issues/665).
## INSTALLATION
The best way to install Gollum is with RubyGems:
The best way to install Gollum-lib is with RubyGems:
$ [sudo] gem install gollum
$ [sudo] gem install gollum-lib
If you're installing from source, you can use [Bundler][bundler] to pick up all the
gems:
Loading
Loading
@@ -58,30 +51,6 @@ to install the dependencies for the formats that you plan to use.
[bundler]:http://gembundler.com/
## RUNNING
To view and edit your Gollum repository locally via the built in web
interface, simply install the Gollum gem, navigate to your repository via the
command line, and run the executable:
$ gollum
This will start up a web server running the Gollum frontend and you can view
and edit your wiki at http://localhost:4567. To get help on the command line
utility, you can run it like so:
$ gollum --help
Note that the gollum server will not run on Windows because of [an issue](https://github.com/rtomayko/posix-spawn/issues/9) with posix-spawn (which is used by Grit).
## REPO STRUCTURE
A Gollum repository's contents are designed to be human editable. Page content
is written in `page files` and may be organized into directories any way you
choose. Special footers can be created in `footer files`. Other content
(images, PDFs, etc) may also be present and organized in the same way.
## PAGE FILES
Page files may be written in any format supported by
Loading
Loading
@@ -121,7 +90,7 @@ automatically generated table of contents will be shown instead.
## SIDEBAR FILES
Sidebar files allow you to add a simple sidebar to your wiki. Sidebar files
Sidebar files allow you to add a simple sidebar to your wiki. Sidebar files
are named `_Sidebar.ext` where the extension is one of the supported formats.
Sidebars affect all pages in their directory and any subdirectories that do not
have a sidebar file of their own.
Loading
Loading
@@ -154,6 +123,7 @@ The first defined `h1` will override the default header on a page. There are two
`<!-- --- title: New Title -->`
The first `h1` tag can be set to always override the page title, without needing to use the metadata syntax. Start gollum with the `--h1-title` flag.
## BRACKET TAGS
A variety of Gollum tags use a double bracket syntax. For example:
Loading
Loading
@@ -322,7 +292,7 @@ This is useful for writing about the link syntax in your wiki pages.
## TABLE OF CONTENTS
Gollum has a special tag to insert a table of contents (new in v2.1)
Gollum has a special tag to insert a table of contents:
[[_TOC_]]
Loading
Loading
@@ -330,12 +300,9 @@ This tag is case sensitive, use all upper case. The TOC tag can be inserted
into the `_Header`, `_Footer` or `_Sidebar` files too.
There is also a wiki option `:universal_toc` which will display a
table of contents at the top of all your wiki pages if it is enabled.
The `:universal_toc` is not enabled by default. To set the option,
add the option to the `:wiki_options` hash before starting the
frontend app:
table of contents at the top of all your wiki pages if it is enabled:
Your Rack middleware can pass author details to Gollum in a Hash in the session under the 'gollum.author' key.
## WINDOWS FILENAME VALIDATION
Note that filenames on windows must not contain any of the following characters `\ / : * ? " < > |`. See [this support article](http://support.microsoft.com/kb/177506) for details.
## CONFIG FILE
Gollum optionally takes a `--config file`. See [config.rb](https://github.com/gollum/gollum/blob/master/config.rb) for an example.
## CUSTOM CSS/JS
The `--css` flag will inject `custom.css` from the root of your git repository into each page. `custom.css` must be commited to git or you will get a 302 redirect to the create page.
The `--js` flag will inject `custom.js` from the root of your git repository into each page. `custom.js` must be commited to git or you will get a 302 redirect to the create page.
Note that filenames on windows must not contain any of the following characters `\ / : * ? " < > |`. See [this support article](http://support.microsoft.com/kb/177506) for details.
## CONTRIBUTE
If you'd like to hack on Gollum, start by forking the repo on GitHub:
If you'd like to hack on Gollum-lib, start by forking the repo on GitHub:
http://github.com/gollum/gollum
http://github.com/gollum/gollum-lib
To get all of the dependencies, install the gem first. The best way to get
your changes merged back into core is as follows:
Loading
Loading
@@ -582,35 +511,40 @@ your changes merged back into core is as follows:
1. Do not change the version number, I will do that on my end
1. If necessary, rebase your commits into logical chunks, without errors
1. Push the branch up to GitHub
1. Send a pull request to the gollum/gollum project.
1. Send a pull request to the gollum/gollum-lib project.