A (static) git repository browser [mirror]
Go to file
Alberto Bertogli c72278c97c Allow calling the executable from any directory
When the tool is invoked like /path/to/git-arr, it currently fails because
both the serving of static files and bottle templates assume they're on the
current working directory.

This patch fixes that by computing the directories based on the executable
location.

Note this is assuming the static directory and the templates live next to the
executable, which will not always be the case, and eventually it should be
configurable; but it's ok for the time being.

Signed-off-by: Alberto Bertogli <albertito@blitiri.com.ar>
2013-03-10 00:55:56 +00:00
static Initial commit 2012-11-10 17:49:54 +00:00
views Use heuristics to decide what to colorize 2012-11-18 14:55:22 +00:00
.gitignore Initial commit 2012-11-10 17:49:54 +00:00
git-arr Allow calling the executable from any directory 2013-03-10 00:55:56 +00:00
git.py Improve the way we find repo paths 2012-11-11 13:43:02 +00:00
LICENSE Initial commit 2012-11-10 17:49:54 +00:00
README Add a note about pygments in the README 2012-11-21 00:29:43 +00:00
sample.conf Use "cloneurl" as a default for git_url 2013-03-09 23:23:52 +00:00
TODO Initial commit 2012-11-10 17:49:54 +00:00
utils.py Only guess the lexer if the file starts with "#!" 2012-11-27 02:57:31 +00:00

git-arr - A git repository browser
----------------------------------

git-arr is a git repository browser that can generate static HTML instead of
having to run dynamically.

It is smaller, with less features and a different set of tradeoffs than
other similar software, so if you're looking for a robust and featureful git
browser, please look at gitweb or cgit instead.

However, if you want to generate static HTML at the expense of features, then
it's probably going to be useful.

It's open source under the MIT licence, please see the LICENSE file for more
information.


Getting started
---------------

You will need Python, and the bottle.py framework (the package is usually
called python-bottle in most distributions).

If pygments is available, it will be used for syntax highlighting, otherwise
everything will work fine, just in black and white.


First, create a configuration file for your repositories. You can start by
copying sample.conf, which has the list of the available options.

Then, to generate the output to "/var/www/git-arr/" directory, run:

  $ ./git-arr --config config.conf generate --output /var/www/git-arr/

That's it!

The first time you generate, depending on the size of your repositories, it
can take some time. Subsequent runs should take less time, as it is smart
enough to only generate what has changed.


You can also use git-arr dynamically, although it's not its intended mode of
use, by running:

  $ ./git-arr --config config.conf serve

That can be useful when making changes to the software itself.


Contact
-------

If you want to report bugs, send patches, or have any questions or comments,
just let me know at albertito@blitiri.com.ar.