blob: 7e968e260dadf91f4b694e57312d1a66e3fb3426 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
package main
/*
this parses the command line arguements
*/
import (
"go.wit.com/dev/alexflint/arg"
)
var argv args
type args struct {
Repo string `arg:"--repo" default:"./" help:"what .git repo to use?"`
Hostname string `arg:"--hostname" help:"hostname to use"`
Refs bool `arg:"--refs" help:"list the git ref hashes"`
}
func (args) Version() string {
return "going2git " + VERSION + " Built on " + BUILDTIME
}
func init() {
arg.MustParse(&argv)
}
func (a args) Description() string {
return `
This is a demo of git2go to show how it works.
Actually, I don't know how to use libgit2 or git2go yet so really this is just
an example of how to compile something against it.
`
}
|