all repos — legit @ fba146ac6867b13c40802c4d7a21a8a32571473c

web frontend for git, written in go

readme (view raw)

 1legit
 2-----
 3
 4A git web frontend written in Go.
 5
 6Pronounced however you like; I prefer channeling my inner beret-wearing
 7Frenchman, and saying "Oui, il est le git!"
 8
 9But yeah it's pretty legit, no cap on god fr fr.
10
11
12FEATURES
13
14• Fully customizable templates and stylesheets.
15• Cloning over http(s).
16• Less archaic HTML.
17• Not CGI.
18
19
20INSTALLING
21
22Clone it, 'go build' it.
23
24
25CONFIG
26
27Uses yaml for configuration. Looks for a 'config.yaml' in the current
28directory by default; pass the '--config' flag to point it elsewhere.
29
30Example config.yaml:
31
32    repo:
33      scanPath: /var/www/git
34      readme:
35        - readme
36        - README
37        - readme.md
38        - README.md
39      mainBranch:
40        - master
41        - main
42      ignore:
43        - foo
44        - bar
45    dirs:
46      templates: ./templates
47      static: ./static
48    meta:
49      title: git good
50      description: i think it's a skill issue
51    server:
52      name: git.icyphox.sh
53      host: 127.0.0.1
54      port: 5555
55
56These options are fairly self-explanatory, but of note are:
57
58• repo.scanPath: where all your git repos live (or die). legit doesn't
59  traverse subdirs yet.
60• dirs: use this to override the default templates and static assets.
61• repo.readme: readme files to look for.
62• repo.mainBranch: main branch names to look for.
63• repo.ignore: repos to ignore, relative to scanPath.
64• server.name: used for go-import meta tags and clone URLs.
65
66
67NOTES
68
69• Run legit behind a TLS terminating proxy like relayd(8) or nginx.
70• Cloning only works in bare repos -- this is a limitation inherent to git. You
71  can still view non-bare repos just fine in legit.
72• The default head.html template uses my CDN to fetch fonts -- you may
73  or may not want this.
74• Pushing over https, while supported, is disabled because auth is a
75  pain. Use ssh.
76• Paths are unveil(2)'d on OpenBSD.
77
78
79IDEAS
80
81• "Private" repos only available over Tailscale.
82• Support or cgit-like filters (for readmes etc.).
83
84
85LICENSE
86
87legit is licensed under MIT.