Go Vanity URLs is a fork of excellent work by rakyll. It is customized to work with go.breu.io
.
After creating a new directory, edit vanity.yaml
to add your repo. e.g., go.breu.io/ctrlplane
simply add /ctrlplane
and then the http path to github repo e.g.
paths:
/ctrlplane:
repo: https://github.com/breuHQ/ctrlplane
vcs: git
You can add as many rules as you wish.
host: example.com
cache_max_age: 3600 # in seconds
paths:
/foo:
repo: https://github.com/example/foo
display: "https://github.com/example/foo https://github.com/example/foo/tree/master{/dir} https://github.com/example/foo/blob/master{/dir}/{file}#L{line}"
vcs: git
key | required | default | description |
---|---|---|---|
host | yes | the host e.g example.com or go.breu.io etc. |
|
cache_max_age | no | 86400 | default value for http cache-control header |
paths | yes | paths as described in path configuration below |
key | required | description |
---|---|---|
repo | yes | Root URL of the repository as it would appear in go-import meta tag. |
vcs | optional | can be git , svn , bzr & hg . if not provided, defaults to git. |
display | optional | The last three fields of the go-source meta tag. If omitted, it is inferred from the code hosting service if possible. |