Migrate to code.rocket9labs.com
This commit is contained in:
parent
2e2b218bfd
commit
3db8913059
4 changed files with 12 additions and 11 deletions
|
@ -1,4 +1,5 @@
|
|||
0.2.2:
|
||||
- Migrate to code.rocket9labs.com
|
||||
- Retry executing godoc to work around intermittent failure
|
||||
- Add builtin package support (thanks @FractalU)
|
||||
- Improve -zip option to automatically create necessary parent directories for the site zip file (thanks @FractalU)
|
||||
|
|
16
README.md
16
README.md
|
@ -1,24 +1,24 @@
|
|||
# godoc-static
|
||||
[](https://liberapay.com/rocketnine.space)
|
||||
[](https://liberapay.com/rocket9labs.com)
|
||||
|
||||
Generate static Go documentation
|
||||
|
||||
## Demo
|
||||
|
||||
[Rocket Nine Labs Documentation](https://docs.rocketnine.space)
|
||||
[Rocket 9 Labs Documentation](https://docs.rocket9labs.com)
|
||||
|
||||
## Installation
|
||||
|
||||
Install `godoc-static`:
|
||||
|
||||
```bash
|
||||
go get code.rocketnine.space/tslocum/godoc-static
|
||||
go install code.rocket9labs.com/tslocum/godoc-static@latest
|
||||
```
|
||||
|
||||
Also install `godoc`:
|
||||
|
||||
```bash
|
||||
go get golang.org/x/tools/cmd/godoc
|
||||
go install golang.org/x/tools/cmd/godoc@latest
|
||||
```
|
||||
|
||||
## Documentation
|
||||
|
@ -39,14 +39,14 @@ Packages are not downloaded/updated automatically.
|
|||
|
||||
### Usage examples
|
||||
|
||||
Generate documentation for `archive`, `net/http` and `~/go/src/code.rocketnine.space/tslocum/cview`:
|
||||
Generate documentation for `archive`, `net/http` and `~/go/src/code.rocket9labs.com/tslocum/cview`:
|
||||
|
||||
```bash
|
||||
godoc-static \
|
||||
-site-name="Rocket Nine Labs Documentation" \
|
||||
-site-name="Rocket 9 Labs Documentation" \
|
||||
-site-description-file=/home/user/sitefiles/description.md \
|
||||
-destination=/home/user/sites/docs \
|
||||
archive net/http code.rocketnine.space/tslocum/cview
|
||||
archive net/http code.rocket9labs.com/tslocum/cview
|
||||
```
|
||||
|
||||
### Options
|
||||
|
@ -89,4 +89,4 @@ Site ZIP file name.
|
|||
|
||||
## Support
|
||||
|
||||
Please share issues and suggestions [here](https://code.rocketnine.space/tslocum/godoc-static/issues).
|
||||
Please share issues and suggestions [here](https://code.rocket9labs.com/tslocum/godoc-static/issues).
|
||||
|
|
2
go.mod
2
go.mod
|
@ -1,4 +1,4 @@
|
|||
module code.rocketnine.space/tslocum/godoc-static
|
||||
module code.rocket9labs.com/tslocum/godoc-static
|
||||
|
||||
go 1.15
|
||||
|
||||
|
|
4
page.go
4
page.go
|
@ -20,7 +20,7 @@ summary { margin-left: 20px; cursor: pointer; }
|
|||
#footer > p, #footer > li { max-width: none; word-wrap: normal; }
|
||||
`
|
||||
|
||||
const footerText = `Generated by <a href="https://godoc.org/golang.org/x/tools/godoc" target="_blank">godoc</a> + <a href="https://code.rocketnine.space/tslocum/godoc-static" target="_blank">godoc-static</a>`
|
||||
const footerText = `Generated by <a href="https://godoc.org/golang.org/x/tools/godoc" target="_blank">godoc</a> + <a href="https://code.rocket9labs.com/tslocum/godoc-static" target="_blank">godoc-static</a>`
|
||||
|
||||
func topBar(basePath string, siteName string) string {
|
||||
var index string
|
||||
|
@ -88,7 +88,7 @@ func updatePage(doc *goquery.Document, basePath string, siteName string) {
|
|||
browseInsert = "/-/tree/master"
|
||||
} else if strings.HasPrefix(importPath, "github.com/") || strings.HasPrefix(importPath, "git.sr.ht/") {
|
||||
browseInsert = "/tree/master"
|
||||
} else if strings.HasPrefix(importPath, "bitbucket.org/") || strings.HasPrefix(importPath, "code.rocketnine.space/") {
|
||||
} else if strings.HasPrefix(importPath, "bitbucket.org/") || strings.HasPrefix(importPath, "code.rocket9labs.com/") {
|
||||
browseInsert = "/src/master"
|
||||
}
|
||||
if browseInsert != "" {
|
||||
|
|
Loading…
Reference in a new issue