Add cobra, move the server code into its own package
This commit is contained in:
parent
bb729a5c8e
commit
e63c012aad
57 changed files with 6910 additions and 145 deletions
|
@ -7,8 +7,6 @@ import (
|
|||
"path"
|
||||
|
||||
"github.com/khlieng/name_pending/Godeps/_workspace/src/github.com/boltdb/bolt"
|
||||
|
||||
"github.com/khlieng/name_pending/args"
|
||||
)
|
||||
|
||||
var (
|
||||
|
@ -22,12 +20,12 @@ var (
|
|||
bucketMessages = []byte("Messages")
|
||||
)
|
||||
|
||||
func init() {
|
||||
func Initialize(clean bool) {
|
||||
var err error
|
||||
currentUser, _ := user.Current()
|
||||
appDir = path.Join(currentUser.HomeDir, ".name_pending")
|
||||
|
||||
if args.Development {
|
||||
if clean {
|
||||
os.RemoveAll(appDir)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue