- commit
- d183f40
- parent
- 8cab5ce
- author
- Eric Bower
- date
- 2024-12-20 17:55:05 -0500 EST
docs: readme
3 files changed,
+30,
-3
+27,
-0
1@@ -43,3 +43,30 @@ site colors.
2
3 This project was heavily inspired by
4 [stagit](https://codemadness.org/stagit.html)
5+
6+## with multiple repos
7+
8+`--root-relative` sets the prefix for all links (default: `/`). This makes it so
9+you can run multiple repos and have them all live inside the same static site.
10+
11+```bash
12+pgit \
13+ --out ./public/pico \
14+ --label pico \
15+ --home-url "https://git.erock.io" \
16+ --revs main \
17+ --repo ~/pico \
18+ --root-relative "/pico/"
19+
20+pgit \
21+ --out ./public/starfx \
22+ --label starfx \
23+ --home-url "https://git.erock.io" \
24+ --revs main \
25+ --repo ~/starfx \
26+ --root-relative "/starfx"
27+
28+echo '<html><body><a href="/pico">pico</a><a href="/starfx">starfx</a></body></html>' > ./public/index.html
29+
30+rsync -rv ./public/ pgs.sh:/git
31+```
+2,
-2
1@@ -16,9 +16,9 @@
2 </head>
3 <body>
4 <header>{{template "header" .}}</header>
5- <hr />
6+ <hr class="my" />
7 <main>{{template "content" .}}</main>
8- <hr />
9+ <hr class="my" />
10 <footer>{{template "footer" .}}</footer>
11 </body>
12 </html>
+1,
-1
1@@ -18,7 +18,7 @@
2
3 <div>
4 <div>{{.Repo.Desc}}</div>
5- <pre class="m-0">git clone {{.SiteURLs.CloneURL}}</pre>
6+ {{if .SiteURLs.CloneURL}}<pre class="m-0">git clone {{.SiteURLs.CloneURL}}</pre>{{end}}
7 </div>
8 </div>
9 {{end}}