mirror of
https://github.com/stashapp/stash.git
synced 2025-12-18 04:44:37 +03:00
Initial commit
This commit is contained in:
21
vendor/github.com/gobuffalo/buffalo-plugins/LICENSE
generated
vendored
Normal file
21
vendor/github.com/gobuffalo/buffalo-plugins/LICENSE
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright © 2018 Mark Bates
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
||||
96
vendor/github.com/gobuffalo/buffalo-plugins/plugins/cache.go
generated
vendored
Normal file
96
vendor/github.com/gobuffalo/buffalo-plugins/plugins/cache.go
generated
vendored
Normal file
@@ -0,0 +1,96 @@
|
||||
package plugins
|
||||
|
||||
import (
|
||||
"crypto/sha256"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"io"
|
||||
"os"
|
||||
"os/user"
|
||||
"path/filepath"
|
||||
"sync"
|
||||
|
||||
"github.com/gobuffalo/envy"
|
||||
)
|
||||
|
||||
type cachedPlugin struct {
|
||||
Commands Commands `json:"commands"`
|
||||
CheckSum string `json:"check_sum"`
|
||||
}
|
||||
|
||||
type cachedPlugins map[string]cachedPlugin
|
||||
|
||||
var cachePath = func() string {
|
||||
home := "."
|
||||
if usr, err := user.Current(); err == nil {
|
||||
home = usr.HomeDir
|
||||
}
|
||||
return filepath.Join(home, ".buffalo", "plugin.cache")
|
||||
}()
|
||||
|
||||
var cacheMoot sync.RWMutex
|
||||
|
||||
var cacheOn = envy.Get("BUFFALO_PLUGIN_CACHE", "on")
|
||||
|
||||
var cache = func() cachedPlugins {
|
||||
m := cachedPlugins{}
|
||||
if cacheOn != "on" {
|
||||
return m
|
||||
}
|
||||
f, err := os.Open(cachePath)
|
||||
if err != nil {
|
||||
return m
|
||||
}
|
||||
defer f.Close()
|
||||
if err := json.NewDecoder(f).Decode(&m); err != nil {
|
||||
f.Close()
|
||||
os.Remove(f.Name())
|
||||
}
|
||||
return m
|
||||
}()
|
||||
|
||||
func findInCache(path string) (cachedPlugin, bool) {
|
||||
cacheMoot.RLock()
|
||||
defer cacheMoot.RUnlock()
|
||||
cp, ok := cache[path]
|
||||
return cp, ok
|
||||
}
|
||||
|
||||
func saveCache() error {
|
||||
if cacheOn != "on" {
|
||||
return nil
|
||||
}
|
||||
cacheMoot.Lock()
|
||||
defer cacheMoot.Unlock()
|
||||
os.MkdirAll(filepath.Dir(cachePath), 0744)
|
||||
f, err := os.Create(cachePath)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return json.NewEncoder(f).Encode(cache)
|
||||
}
|
||||
|
||||
func sum(path string) string {
|
||||
f, err := os.Open(path)
|
||||
if err != nil {
|
||||
return ""
|
||||
}
|
||||
defer f.Close()
|
||||
hash := sha256.New()
|
||||
if _, err := io.Copy(hash, f); err != nil {
|
||||
return ""
|
||||
}
|
||||
sum := hash.Sum(nil)
|
||||
|
||||
s := fmt.Sprintf("%x", sum)
|
||||
return s
|
||||
}
|
||||
|
||||
func addToCache(path string, cp cachedPlugin) {
|
||||
if cp.CheckSum == "" {
|
||||
cp.CheckSum = sum(path)
|
||||
}
|
||||
cacheMoot.Lock()
|
||||
defer cacheMoot.Unlock()
|
||||
cache[path] = cp
|
||||
}
|
||||
19
vendor/github.com/gobuffalo/buffalo-plugins/plugins/command.go
generated
vendored
Normal file
19
vendor/github.com/gobuffalo/buffalo-plugins/plugins/command.go
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
package plugins
|
||||
|
||||
// Command that the plugin supplies
|
||||
type Command struct {
|
||||
// Name "foo"
|
||||
Name string `json:"name"`
|
||||
// UseCommand "bar"
|
||||
UseCommand string `json:"use_command"`
|
||||
// BuffaloCommand "generate"
|
||||
BuffaloCommand string `json:"buffalo_command"`
|
||||
// Description "generates a foo"
|
||||
Description string `json:"description,omitempty"`
|
||||
Aliases []string `json:"aliases,omitempty"`
|
||||
Binary string `json:"-"`
|
||||
Flags []string `json:"flags,omitempty"`
|
||||
}
|
||||
|
||||
// Commands is a slice of Command
|
||||
type Commands []Command
|
||||
98
vendor/github.com/gobuffalo/buffalo-plugins/plugins/decorate.go
generated
vendored
Normal file
98
vendor/github.com/gobuffalo/buffalo-plugins/plugins/decorate.go
generated
vendored
Normal file
@@ -0,0 +1,98 @@
|
||||
package plugins
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"os"
|
||||
"os/exec"
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
"strings"
|
||||
|
||||
"github.com/gobuffalo/envy"
|
||||
"github.com/pkg/errors"
|
||||
"github.com/spf13/cobra"
|
||||
)
|
||||
|
||||
// ErrPlugMissing ...
|
||||
var ErrPlugMissing = errors.New("plugin missing")
|
||||
|
||||
func Decorate(c Command) *cobra.Command {
|
||||
var flags []string
|
||||
if len(c.Flags) > 0 {
|
||||
for _, f := range c.Flags {
|
||||
flags = append(flags, f)
|
||||
}
|
||||
}
|
||||
cc := &cobra.Command{
|
||||
Use: c.Name,
|
||||
Short: fmt.Sprintf("[PLUGIN] %s", c.Description),
|
||||
Aliases: c.Aliases,
|
||||
RunE: func(cmd *cobra.Command, args []string) error {
|
||||
plugCmd := c.Name
|
||||
if c.UseCommand != "" {
|
||||
plugCmd = c.UseCommand
|
||||
}
|
||||
|
||||
ax := []string{plugCmd}
|
||||
if plugCmd == "-" {
|
||||
ax = []string{}
|
||||
}
|
||||
|
||||
ax = append(ax, args...)
|
||||
ax = append(ax, flags...)
|
||||
|
||||
bin, err := LookPath(c.Binary)
|
||||
if err != nil {
|
||||
return errors.WithStack(err)
|
||||
}
|
||||
|
||||
ex := exec.Command(bin, ax...)
|
||||
if runtime.GOOS != "windows" {
|
||||
ex.Env = append(envy.Environ(), "BUFFALO_PLUGIN=1")
|
||||
}
|
||||
ex.Stdin = os.Stdin
|
||||
ex.Stdout = os.Stdout
|
||||
ex.Stderr = os.Stderr
|
||||
return log(strings.Join(ex.Args, " "), ex.Run)
|
||||
},
|
||||
}
|
||||
cc.DisableFlagParsing = true
|
||||
return cc
|
||||
}
|
||||
|
||||
// LookPath ...
|
||||
func LookPath(s string) (string, error) {
|
||||
if _, err := os.Stat(s); err == nil {
|
||||
return s, nil
|
||||
}
|
||||
|
||||
if lp, err := exec.LookPath(s); err == nil {
|
||||
return lp, err
|
||||
}
|
||||
|
||||
var bin string
|
||||
pwd, err := os.Getwd()
|
||||
if err != nil {
|
||||
return "", errors.WithStack(err)
|
||||
}
|
||||
|
||||
var looks []string
|
||||
if from, err := envy.MustGet("BUFFALO_PLUGIN_PATH"); err == nil {
|
||||
looks = append(looks, from)
|
||||
} else {
|
||||
looks = []string{filepath.Join(pwd, "plugins"), filepath.Join(envy.GoPath(), "bin"), envy.Get("PATH", "")}
|
||||
}
|
||||
|
||||
for _, p := range looks {
|
||||
lp := filepath.Join(p, s)
|
||||
if lp, err = filepath.EvalSymlinks(lp); err == nil {
|
||||
bin = lp
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
if len(bin) == 0 {
|
||||
return "", errors.Wrapf(ErrPlugMissing, "could not find %s in %q", s, looks)
|
||||
}
|
||||
return bin, nil
|
||||
}
|
||||
7
vendor/github.com/gobuffalo/buffalo-plugins/plugins/events.go
generated
vendored
Normal file
7
vendor/github.com/gobuffalo/buffalo-plugins/plugins/events.go
generated
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
package plugins
|
||||
|
||||
const (
|
||||
EvtSetupStarted = "buffalo-plugins:setup:started"
|
||||
EvtSetupErr = "buffalo-plugins:setup:err"
|
||||
EvtSetupFinished = "buffalo-plugins:setup:finished"
|
||||
)
|
||||
7
vendor/github.com/gobuffalo/buffalo-plugins/plugins/log.go
generated
vendored
Normal file
7
vendor/github.com/gobuffalo/buffalo-plugins/plugins/log.go
generated
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
//+build !debug
|
||||
|
||||
package plugins
|
||||
|
||||
func log(_ string, fn func() error) error {
|
||||
return fn()
|
||||
}
|
||||
14
vendor/github.com/gobuffalo/buffalo-plugins/plugins/log_debug.go
generated
vendored
Normal file
14
vendor/github.com/gobuffalo/buffalo-plugins/plugins/log_debug.go
generated
vendored
Normal file
@@ -0,0 +1,14 @@
|
||||
//+build debug
|
||||
|
||||
package plugins
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"time"
|
||||
)
|
||||
|
||||
func log(name string, fn func() error) error {
|
||||
start := time.Now()
|
||||
defer fmt.Println(name, time.Now().Sub(start))
|
||||
return fn()
|
||||
}
|
||||
16
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps/command.go
generated
vendored
Normal file
16
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps/command.go
generated
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
package plugdeps
|
||||
|
||||
import "encoding/json"
|
||||
|
||||
// Command is the plugin command you want to control further
|
||||
type Command struct {
|
||||
Name string `toml:"name" json:"name"`
|
||||
Flags []string `toml:"flags,omitempty" json:"flags,omitempty"`
|
||||
Commands []Command `toml:"command,omitempty" json:"commands,omitempty"`
|
||||
}
|
||||
|
||||
// String implementation of fmt.Stringer
|
||||
func (p Command) String() string {
|
||||
b, _ := json.Marshal(p)
|
||||
return string(b)
|
||||
}
|
||||
88
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps/plugdeps.go
generated
vendored
Normal file
88
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps/plugdeps.go
generated
vendored
Normal file
@@ -0,0 +1,88 @@
|
||||
package plugdeps
|
||||
|
||||
import (
|
||||
"os"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
|
||||
"github.com/gobuffalo/meta"
|
||||
"github.com/karrick/godirwalk"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
// ErrMissingConfig is if config/buffalo-plugins.toml file is not found. Use plugdeps#On(app) to test if plugdeps are being used
|
||||
var ErrMissingConfig = errors.Errorf("could not find a buffalo-plugins config file at %s", ConfigPath(meta.New(".")))
|
||||
|
||||
// List all of the plugins the application depeneds on. Will return ErrMissingConfig
|
||||
// if the app is not using config/buffalo-plugins.toml to manage their plugins.
|
||||
// Use plugdeps#On(app) to test if plugdeps are being used.
|
||||
func List(app meta.App) (*Plugins, error) {
|
||||
plugs := New()
|
||||
if app.WithPop {
|
||||
plugs.Add(pop)
|
||||
}
|
||||
|
||||
lp, err := listLocal(app)
|
||||
if err != nil {
|
||||
return plugs, errors.WithStack(err)
|
||||
}
|
||||
plugs.Add(lp.List()...)
|
||||
|
||||
if !On(app) {
|
||||
return plugs, ErrMissingConfig
|
||||
}
|
||||
|
||||
p := ConfigPath(app)
|
||||
tf, err := os.Open(p)
|
||||
if err != nil {
|
||||
return plugs, errors.WithStack(err)
|
||||
}
|
||||
if err := plugs.Decode(tf); err != nil {
|
||||
return plugs, errors.WithStack(err)
|
||||
}
|
||||
|
||||
return plugs, nil
|
||||
}
|
||||
|
||||
func listLocal(app meta.App) (*Plugins, error) {
|
||||
plugs := New()
|
||||
proot := filepath.Join(app.Root, "plugins")
|
||||
if _, err := os.Stat(proot); err != nil {
|
||||
return plugs, nil
|
||||
}
|
||||
err := godirwalk.Walk(proot, &godirwalk.Options{
|
||||
FollowSymbolicLinks: true,
|
||||
Callback: func(path string, info *godirwalk.Dirent) error {
|
||||
if info.IsDir() {
|
||||
return nil
|
||||
}
|
||||
base := filepath.Base(path)
|
||||
if strings.HasPrefix(base, "buffalo-") {
|
||||
plugs.Add(Plugin{
|
||||
Binary: base,
|
||||
Local: "." + strings.TrimPrefix(path, app.Root),
|
||||
})
|
||||
}
|
||||
return nil
|
||||
},
|
||||
})
|
||||
if err != nil {
|
||||
return plugs, errors.WithStack(err)
|
||||
}
|
||||
|
||||
return plugs, nil
|
||||
}
|
||||
|
||||
// ConfigPath returns the path to the config/buffalo-plugins.toml file
|
||||
// relative to the app
|
||||
func ConfigPath(app meta.App) string {
|
||||
return filepath.Join(app.Root, "config", "buffalo-plugins.toml")
|
||||
}
|
||||
|
||||
// On checks for the existence of config/buffalo-plugins.toml if this
|
||||
// file exists its contents will be used to list plugins. If the file is not
|
||||
// found, then the BUFFALO_PLUGIN_PATH and ./plugins folders are consulted.
|
||||
func On(app meta.App) bool {
|
||||
_, err := os.Stat(ConfigPath(app))
|
||||
return err == nil
|
||||
}
|
||||
26
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps/plugin.go
generated
vendored
Normal file
26
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps/plugin.go
generated
vendored
Normal file
@@ -0,0 +1,26 @@
|
||||
package plugdeps
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
|
||||
"github.com/gobuffalo/meta"
|
||||
)
|
||||
|
||||
// Plugin represents a Go plugin for Buffalo applications
|
||||
type Plugin struct {
|
||||
Binary string `toml:"binary" json:"binary"`
|
||||
GoGet string `toml:"go_get,omitempty" json:"go_get,omitempty"`
|
||||
Local string `toml:"local,omitempty" json:"local,omitempty"`
|
||||
Commands []Command `toml:"command,omitempty" json:"commands,omitempty"`
|
||||
Tags meta.BuildTags `toml:"tags,omitempty" json:"tags,omitempty"`
|
||||
}
|
||||
|
||||
// String implementation of fmt.Stringer
|
||||
func (p Plugin) String() string {
|
||||
b, _ := json.Marshal(p)
|
||||
return string(b)
|
||||
}
|
||||
|
||||
func (p Plugin) key() string {
|
||||
return p.Binary + p.GoGet + p.Local
|
||||
}
|
||||
98
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps/plugins.go
generated
vendored
Normal file
98
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps/plugins.go
generated
vendored
Normal file
@@ -0,0 +1,98 @@
|
||||
package plugdeps
|
||||
|
||||
import (
|
||||
"io"
|
||||
"sort"
|
||||
"sync"
|
||||
|
||||
"github.com/BurntSushi/toml"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
// Plugins manages the config/buffalo-plugins.toml file
|
||||
// as well as the plugins available from the file.
|
||||
type Plugins struct {
|
||||
plugins map[string]Plugin
|
||||
moot *sync.RWMutex
|
||||
}
|
||||
|
||||
// Encode the list of plugins, in TOML format, to the reader
|
||||
func (plugs *Plugins) Encode(w io.Writer) error {
|
||||
tp := tomlPlugins{
|
||||
Plugins: plugs.List(),
|
||||
}
|
||||
|
||||
if err := toml.NewEncoder(w).Encode(tp); err != nil {
|
||||
return errors.WithStack(err)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// Decode the list of plugins, in TOML format, from the reader
|
||||
func (plugs *Plugins) Decode(r io.Reader) error {
|
||||
tp := &tomlPlugins{
|
||||
Plugins: []Plugin{},
|
||||
}
|
||||
if _, err := toml.DecodeReader(r, tp); err != nil {
|
||||
return errors.WithStack(err)
|
||||
}
|
||||
for _, p := range tp.Plugins {
|
||||
plugs.Add(p)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// List of dependent plugins listed in order of Plugin.String()
|
||||
func (plugs *Plugins) List() []Plugin {
|
||||
m := map[string]Plugin{}
|
||||
plugs.moot.RLock()
|
||||
for _, p := range plugs.plugins {
|
||||
m[p.key()] = p
|
||||
}
|
||||
plugs.moot.RUnlock()
|
||||
var pp []Plugin
|
||||
for _, v := range m {
|
||||
pp = append(pp, v)
|
||||
}
|
||||
sort.Slice(pp, func(a, b int) bool {
|
||||
return pp[a].Binary < pp[b].Binary
|
||||
})
|
||||
return pp
|
||||
}
|
||||
|
||||
// Add plugin(s) to the list of dependencies
|
||||
func (plugs *Plugins) Add(pp ...Plugin) {
|
||||
plugs.moot.Lock()
|
||||
for _, p := range pp {
|
||||
plugs.plugins[p.key()] = p
|
||||
}
|
||||
plugs.moot.Unlock()
|
||||
}
|
||||
|
||||
// Remove plugin(s) from the list of dependencies
|
||||
func (plugs *Plugins) Remove(pp ...Plugin) {
|
||||
plugs.moot.Lock()
|
||||
for _, p := range pp {
|
||||
delete(plugs.plugins, p.key())
|
||||
}
|
||||
plugs.moot.Unlock()
|
||||
}
|
||||
|
||||
// New returns a configured *Plugins value
|
||||
func New() *Plugins {
|
||||
plugs := &Plugins{
|
||||
plugins: map[string]Plugin{},
|
||||
moot: &sync.RWMutex{},
|
||||
}
|
||||
plugs.Add(self)
|
||||
return plugs
|
||||
}
|
||||
|
||||
type tomlPlugins struct {
|
||||
Plugins []Plugin `toml:"plugin"`
|
||||
}
|
||||
|
||||
var self = Plugin{
|
||||
Binary: "buffalo-plugins",
|
||||
GoGet: "github.com/gobuffalo/buffalo-plugins",
|
||||
}
|
||||
6
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps/pop.go
generated
vendored
Normal file
6
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps/pop.go
generated
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
package plugdeps
|
||||
|
||||
var pop = Plugin{
|
||||
Binary: "buffalo-pop",
|
||||
GoGet: "github.com/gobuffalo/buffalo-pop",
|
||||
}
|
||||
232
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugins.go
generated
vendored
Normal file
232
vendor/github.com/gobuffalo/buffalo-plugins/plugins/plugins.go
generated
vendored
Normal file
@@ -0,0 +1,232 @@
|
||||
package plugins
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"context"
|
||||
"encoding/json"
|
||||
"os"
|
||||
"os/exec"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/gobuffalo/buffalo-plugins/plugins/plugdeps"
|
||||
"github.com/gobuffalo/envy"
|
||||
"github.com/gobuffalo/meta"
|
||||
"github.com/karrick/godirwalk"
|
||||
"github.com/markbates/oncer"
|
||||
"github.com/pkg/errors"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
const timeoutEnv = "BUFFALO_PLUGIN_TIMEOUT"
|
||||
|
||||
var t = time.Second * 2
|
||||
|
||||
func timeout() time.Duration {
|
||||
oncer.Do("plugins.timeout", func() {
|
||||
rawTimeout, err := envy.MustGet(timeoutEnv)
|
||||
if err == nil {
|
||||
if parsed, err := time.ParseDuration(rawTimeout); err == nil {
|
||||
t = parsed
|
||||
} else {
|
||||
logrus.Errorf("%q value is malformed assuming default %q: %v", timeoutEnv, t, err)
|
||||
}
|
||||
} else {
|
||||
logrus.Debugf("%q not set, assuming default of %v", timeoutEnv, t)
|
||||
}
|
||||
})
|
||||
return t
|
||||
}
|
||||
|
||||
// List maps a Buffalo command to a slice of Command
|
||||
type List map[string]Commands
|
||||
|
||||
var _list List
|
||||
|
||||
// Available plugins for the `buffalo` command.
|
||||
// It will look in $GOPATH/bin and the `./plugins` directory.
|
||||
// This can be changed by setting the $BUFFALO_PLUGIN_PATH
|
||||
// environment variable.
|
||||
//
|
||||
// Requirements:
|
||||
// * file/command must be executable
|
||||
// * file/command must start with `buffalo-`
|
||||
// * file/command must respond to `available` and return JSON of
|
||||
// plugins.Commands{}
|
||||
//
|
||||
// Limit full path scan with direct plugin path
|
||||
//
|
||||
// If a file/command doesn't respond to being invoked with `available`
|
||||
// within one second, buffalo will assume that it is unable to load. This
|
||||
// can be changed by setting the $BUFFALO_PLUGIN_TIMEOUT environment
|
||||
// variable. It must be set to a duration that `time.ParseDuration` can
|
||||
// process.
|
||||
func Available() (List, error) {
|
||||
var err error
|
||||
oncer.Do("plugins.Available", func() {
|
||||
defer func() {
|
||||
if err := saveCache(); err != nil {
|
||||
logrus.Error(err)
|
||||
}
|
||||
}()
|
||||
|
||||
app := meta.New(".")
|
||||
|
||||
if plugdeps.On(app) {
|
||||
_list, err = listPlugDeps(app)
|
||||
return
|
||||
}
|
||||
|
||||
paths := []string{"plugins"}
|
||||
|
||||
from, err := envy.MustGet("BUFFALO_PLUGIN_PATH")
|
||||
if err != nil {
|
||||
from, err = envy.MustGet("GOPATH")
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
from = filepath.Join(from, "bin")
|
||||
}
|
||||
|
||||
paths = append(paths, strings.Split(from, string(os.PathListSeparator))...)
|
||||
|
||||
list := List{}
|
||||
for _, p := range paths {
|
||||
if ignorePath(p) {
|
||||
continue
|
||||
}
|
||||
if _, err := os.Stat(p); err != nil {
|
||||
continue
|
||||
}
|
||||
|
||||
err := godirwalk.Walk(p, &godirwalk.Options{
|
||||
FollowSymbolicLinks: true,
|
||||
Callback: func(path string, info *godirwalk.Dirent) error {
|
||||
if err != nil {
|
||||
// May indicate a permissions problem with the path, skip it
|
||||
return nil
|
||||
}
|
||||
if info.IsDir() {
|
||||
return nil
|
||||
}
|
||||
base := filepath.Base(path)
|
||||
if strings.HasPrefix(base, "buffalo-") {
|
||||
ctx, cancel := context.WithTimeout(context.Background(), timeout())
|
||||
commands := askBin(ctx, path)
|
||||
cancel()
|
||||
for _, c := range commands {
|
||||
bc := c.BuffaloCommand
|
||||
if _, ok := list[bc]; !ok {
|
||||
list[bc] = Commands{}
|
||||
}
|
||||
c.Binary = path
|
||||
list[bc] = append(list[bc], c)
|
||||
}
|
||||
}
|
||||
return nil
|
||||
},
|
||||
})
|
||||
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
}
|
||||
_list = list
|
||||
})
|
||||
return _list, err
|
||||
}
|
||||
|
||||
func askBin(ctx context.Context, path string) Commands {
|
||||
start := time.Now()
|
||||
defer func() {
|
||||
logrus.Debugf("askBin %s=%.4f s", path, time.Since(start).Seconds())
|
||||
}()
|
||||
|
||||
commands := Commands{}
|
||||
defer func() {
|
||||
addToCache(path, cachedPlugin{
|
||||
Commands: commands,
|
||||
})
|
||||
}()
|
||||
if cp, ok := findInCache(path); ok {
|
||||
s := sum(path)
|
||||
if s == cp.CheckSum {
|
||||
logrus.Debugf("cache hit: %s", path)
|
||||
commands = cp.Commands
|
||||
return commands
|
||||
}
|
||||
}
|
||||
logrus.Debugf("cache miss: %s", path)
|
||||
if strings.HasPrefix(filepath.Base(path), "buffalo-no-sqlite") {
|
||||
return commands
|
||||
}
|
||||
|
||||
cmd := exec.CommandContext(ctx, path, "available")
|
||||
bb := &bytes.Buffer{}
|
||||
cmd.Stdout = bb
|
||||
err := cmd.Run()
|
||||
if err != nil {
|
||||
return commands
|
||||
}
|
||||
msg := bb.String()
|
||||
for len(msg) > 0 {
|
||||
err = json.NewDecoder(strings.NewReader(msg)).Decode(&commands)
|
||||
if err == nil {
|
||||
return commands
|
||||
}
|
||||
msg = msg[1:]
|
||||
}
|
||||
logrus.Errorf("[PLUGIN] error decoding plugin %s: %s\n%s\n", path, err, msg)
|
||||
return commands
|
||||
}
|
||||
|
||||
func ignorePath(p string) bool {
|
||||
p = strings.ToLower(p)
|
||||
for _, x := range []string{`c:\windows`, `c:\program`} {
|
||||
if strings.HasPrefix(p, x) {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func listPlugDeps(app meta.App) (List, error) {
|
||||
list := List{}
|
||||
plugs, err := plugdeps.List(app)
|
||||
if err != nil {
|
||||
return list, err
|
||||
}
|
||||
for _, p := range plugs.List() {
|
||||
ctx, cancel := context.WithTimeout(context.Background(), timeout())
|
||||
defer cancel()
|
||||
bin := p.Binary
|
||||
if len(p.Local) != 0 {
|
||||
bin = p.Local
|
||||
}
|
||||
bin, err := LookPath(bin)
|
||||
if err != nil {
|
||||
if errors.Cause(err) != ErrPlugMissing {
|
||||
return list, err
|
||||
}
|
||||
continue
|
||||
}
|
||||
commands := askBin(ctx, bin)
|
||||
cancel()
|
||||
for _, c := range commands {
|
||||
bc := c.BuffaloCommand
|
||||
if _, ok := list[bc]; !ok {
|
||||
list[bc] = Commands{}
|
||||
}
|
||||
c.Binary = p.Binary
|
||||
for _, pc := range p.Commands {
|
||||
if c.Name == pc.Name {
|
||||
c.Flags = pc.Flags
|
||||
break
|
||||
}
|
||||
}
|
||||
list[bc] = append(list[bc], c)
|
||||
}
|
||||
}
|
||||
return list, nil
|
||||
}
|
||||
3
vendor/github.com/gobuffalo/buffalo-plugins/plugins/version.go
generated
vendored
Normal file
3
vendor/github.com/gobuffalo/buffalo-plugins/plugins/version.go
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
package plugins
|
||||
|
||||
const Version = "v1.11.0"
|
||||
5
vendor/github.com/gobuffalo/envy/.env
generated
vendored
Normal file
5
vendor/github.com/gobuffalo/envy/.env
generated
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
# This is a comment
|
||||
# We can use equal or colon notation
|
||||
DIR: root
|
||||
FLAVOUR: none
|
||||
INSIDE_FOLDER=false
|
||||
29
vendor/github.com/gobuffalo/envy/.gitignore
generated
vendored
Normal file
29
vendor/github.com/gobuffalo/envy/.gitignore
generated
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
*.log
|
||||
.DS_Store
|
||||
doc
|
||||
tmp
|
||||
pkg
|
||||
*.gem
|
||||
*.pid
|
||||
coverage
|
||||
coverage.data
|
||||
build/*
|
||||
*.pbxuser
|
||||
*.mode1v3
|
||||
.svn
|
||||
profile
|
||||
.console_history
|
||||
.sass-cache/*
|
||||
.rake_tasks~
|
||||
*.log.lck
|
||||
solr/
|
||||
.jhw-cache/
|
||||
jhw.*
|
||||
*.sublime*
|
||||
node_modules/
|
||||
dist/
|
||||
generated/
|
||||
.vendor/
|
||||
bin/*
|
||||
gin-bin
|
||||
.idea/
|
||||
3
vendor/github.com/gobuffalo/envy/.gometalinter.json
generated
vendored
Normal file
3
vendor/github.com/gobuffalo/envy/.gometalinter.json
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"Enable": ["vet", "golint", "goimports", "deadcode", "gotype", "ineffassign", "misspell", "nakedret", "unconvert", "megacheck", "varcheck"]
|
||||
}
|
||||
36
vendor/github.com/gobuffalo/envy/.travis.yml
generated
vendored
Normal file
36
vendor/github.com/gobuffalo/envy/.travis.yml
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
language: go
|
||||
|
||||
sudo: false
|
||||
|
||||
matrix:
|
||||
include:
|
||||
- os: linux
|
||||
go: "1.9.x"
|
||||
- os: windows
|
||||
go: "1.9.x"
|
||||
- os: linux
|
||||
go: "1.10.x"
|
||||
- os: windows
|
||||
go: "1.10.x"
|
||||
- os: linux
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=off
|
||||
- os: windows
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=off
|
||||
- os: linux
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=on
|
||||
- os: windows
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=on
|
||||
|
||||
install: false
|
||||
|
||||
script:
|
||||
- go get -v -t ./...
|
||||
- go test -v -timeout=5s -race ./...
|
||||
8
vendor/github.com/gobuffalo/envy/LICENSE.txt
generated
vendored
Normal file
8
vendor/github.com/gobuffalo/envy/LICENSE.txt
generated
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
The MIT License (MIT)
|
||||
Copyright (c) 2018 Mark Bates
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
46
vendor/github.com/gobuffalo/envy/Makefile
generated
vendored
Normal file
46
vendor/github.com/gobuffalo/envy/Makefile
generated
vendored
Normal file
@@ -0,0 +1,46 @@
|
||||
TAGS ?= "sqlite"
|
||||
GO_BIN ?= go
|
||||
|
||||
install:
|
||||
packr
|
||||
$(GO_BIN) install -v .
|
||||
|
||||
deps:
|
||||
$(GO_BIN) get github.com/gobuffalo/release
|
||||
$(GO_BIN) get github.com/gobuffalo/packr/packr
|
||||
$(GO_BIN) get -tags ${TAGS} -t ./...
|
||||
ifeq ($(GO111MODULE),on)
|
||||
$(GO_BIN) mod tidy
|
||||
endif
|
||||
|
||||
build:
|
||||
packr
|
||||
$(GO_BIN) build -v .
|
||||
|
||||
test:
|
||||
packr
|
||||
$(GO_BIN) test -tags ${TAGS} ./...
|
||||
|
||||
ci-test:
|
||||
$(GO_BIN) test -tags ${TAGS} -race ./...
|
||||
|
||||
lint:
|
||||
gometalinter --vendor ./... --deadline=1m --skip=internal
|
||||
|
||||
update:
|
||||
$(GO_BIN) get -u -tags ${TAGS}
|
||||
ifeq ($(GO111MODULE),on)
|
||||
$(GO_BIN) mod tidy
|
||||
endif
|
||||
packr
|
||||
make test
|
||||
make install
|
||||
ifeq ($(GO111MODULE),on)
|
||||
$(GO_BIN) mod tidy
|
||||
endif
|
||||
|
||||
release-test:
|
||||
$(GO_BIN) test -tags ${TAGS} -race ./...
|
||||
|
||||
release:
|
||||
release -y -f version.go
|
||||
93
vendor/github.com/gobuffalo/envy/README.md
generated
vendored
Normal file
93
vendor/github.com/gobuffalo/envy/README.md
generated
vendored
Normal file
@@ -0,0 +1,93 @@
|
||||
# envy
|
||||
[](https://travis-ci.org/gobuffalo/envy)
|
||||
|
||||
Envy makes working with ENV variables in Go trivial.
|
||||
|
||||
* Get ENV variables with default values.
|
||||
* Set ENV variables safely without affecting the underlying system.
|
||||
* Temporarily change ENV vars; useful for testing.
|
||||
* Map all of the key/values in the ENV.
|
||||
* Loads .env files (by using [godotenv](https://github.com/joho/godotenv/))
|
||||
* More!
|
||||
|
||||
## Installation
|
||||
|
||||
```text
|
||||
$ go get -u github.com/gobuffalo/envy
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
```go
|
||||
func Test_Get(t *testing.T) {
|
||||
r := require.New(t)
|
||||
r.NotZero(os.Getenv("GOPATH"))
|
||||
r.Equal(os.Getenv("GOPATH"), envy.Get("GOPATH", "foo"))
|
||||
r.Equal("bar", envy.Get("IDONTEXIST", "bar"))
|
||||
}
|
||||
|
||||
func Test_MustGet(t *testing.T) {
|
||||
r := require.New(t)
|
||||
r.NotZero(os.Getenv("GOPATH"))
|
||||
v, err := envy.MustGet("GOPATH")
|
||||
r.NoError(err)
|
||||
r.Equal(os.Getenv("GOPATH"), v)
|
||||
|
||||
_, err = envy.MustGet("IDONTEXIST")
|
||||
r.Error(err)
|
||||
}
|
||||
|
||||
func Test_Set(t *testing.T) {
|
||||
r := require.New(t)
|
||||
_, err := envy.MustGet("FOO")
|
||||
r.Error(err)
|
||||
|
||||
envy.Set("FOO", "foo")
|
||||
r.Equal("foo", envy.Get("FOO", "bar"))
|
||||
}
|
||||
|
||||
func Test_Temp(t *testing.T) {
|
||||
r := require.New(t)
|
||||
|
||||
_, err := envy.MustGet("BAR")
|
||||
r.Error(err)
|
||||
|
||||
envy.Temp(func() {
|
||||
envy.Set("BAR", "foo")
|
||||
r.Equal("foo", envy.Get("BAR", "bar"))
|
||||
_, err = envy.MustGet("BAR")
|
||||
r.NoError(err)
|
||||
})
|
||||
|
||||
_, err = envy.MustGet("BAR")
|
||||
r.Error(err)
|
||||
}
|
||||
```
|
||||
## .env files support
|
||||
|
||||
Envy now supports loading `.env` files by using the [godotenv library](https://github.com/joho/godotenv/).
|
||||
That means one can use and define multiple `.env` files which will be loaded on-demand. By default, no env files will be loaded. To load one or more, you need to call the `envy.Load` function in one of the following ways:
|
||||
|
||||
```go
|
||||
envy.Load() // 1
|
||||
|
||||
envy.Load("MY_ENV_FILE") // 2
|
||||
|
||||
envy.Load(".env", ".env.prod") // 3
|
||||
|
||||
envy.Load(".env", "NON_EXISTING_FILE") // 4
|
||||
|
||||
// 5
|
||||
envy.Load(".env")
|
||||
envy.Load("NON_EXISTING_FILE")
|
||||
|
||||
// 6
|
||||
envy.Load(".env", "NON_EXISTING_FILE", ".env.prod")
|
||||
```
|
||||
|
||||
1. Will load the default `.env` file
|
||||
2. Will load the file `MY_ENV_FILE`, **but not** `.env`
|
||||
3. Will load the file `.env`, and after that will load the `.env.prod` file. If any variable is redefined in `. env.prod` it will be overwritten (will contain the `env.prod` value)
|
||||
4. Will load the `.env` file and return an error as the second file does not exist. The values in `.env` will be loaded and available.
|
||||
5. Same as 4
|
||||
6. Will load the `.env` file and return an error as the second file does not exist. The values in `.env` will be loaded and available, **but the ones in** `.env.prod` **won't**.
|
||||
258
vendor/github.com/gobuffalo/envy/envy.go
generated
vendored
Normal file
258
vendor/github.com/gobuffalo/envy/envy.go
generated
vendored
Normal file
@@ -0,0 +1,258 @@
|
||||
/*
|
||||
package envy makes working with ENV variables in Go trivial.
|
||||
|
||||
* Get ENV variables with default values.
|
||||
* Set ENV variables safely without affecting the underlying system.
|
||||
* Temporarily change ENV vars; useful for testing.
|
||||
* Map all of the key/values in the ENV.
|
||||
* Loads .env files (by using [godotenv](https://github.com/joho/godotenv/))
|
||||
* More!
|
||||
*/
|
||||
package envy
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"flag"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"os/exec"
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
"strings"
|
||||
"sync"
|
||||
|
||||
"github.com/joho/godotenv"
|
||||
"github.com/rogpeppe/go-internal/modfile"
|
||||
)
|
||||
|
||||
var gil = &sync.RWMutex{}
|
||||
var env = map[string]string{}
|
||||
|
||||
// GO111MODULE is ENV for turning mods on/off
|
||||
const GO111MODULE = "GO111MODULE"
|
||||
|
||||
func init() {
|
||||
Load()
|
||||
loadEnv()
|
||||
}
|
||||
|
||||
// Load the ENV variables to the env map
|
||||
func loadEnv() {
|
||||
gil.Lock()
|
||||
defer gil.Unlock()
|
||||
|
||||
if os.Getenv("GO_ENV") == "" {
|
||||
// if the flag "test.v" is *defined*, we're running as a unit test. Note that we don't care
|
||||
// about v.Value (verbose test mode); we just want to know if the test environment has defined
|
||||
// it. It's also possible that the flags are not yet fully parsed (i.e. flag.Parsed() == false),
|
||||
// so we could not depend on v.Value anyway.
|
||||
//
|
||||
if v := flag.Lookup("test.v"); v != nil {
|
||||
env["GO_ENV"] = "test"
|
||||
}
|
||||
}
|
||||
|
||||
// set the GOPATH if using >= 1.8 and the GOPATH isn't set
|
||||
if os.Getenv("GOPATH") == "" {
|
||||
out, err := exec.Command("go", "env", "GOPATH").Output()
|
||||
if err == nil {
|
||||
gp := strings.TrimSpace(string(out))
|
||||
os.Setenv("GOPATH", gp)
|
||||
}
|
||||
}
|
||||
|
||||
for _, e := range os.Environ() {
|
||||
pair := strings.Split(e, "=")
|
||||
env[pair[0]] = os.Getenv(pair[0])
|
||||
}
|
||||
}
|
||||
|
||||
func Mods() bool {
|
||||
return Get(GO111MODULE, "off") == "on"
|
||||
}
|
||||
|
||||
// Reload the ENV variables. Useful if
|
||||
// an external ENV manager has been used
|
||||
func Reload() {
|
||||
env = map[string]string{}
|
||||
loadEnv()
|
||||
}
|
||||
|
||||
// Load .env files. Files will be loaded in the same order that are received.
|
||||
// Redefined vars will override previously existing values.
|
||||
// IE: envy.Load(".env", "test_env/.env") will result in DIR=test_env
|
||||
// If no arg passed, it will try to load a .env file.
|
||||
func Load(files ...string) error {
|
||||
|
||||
// If no files received, load the default one
|
||||
if len(files) == 0 {
|
||||
err := godotenv.Overload()
|
||||
if err == nil {
|
||||
Reload()
|
||||
}
|
||||
return err
|
||||
}
|
||||
|
||||
// We received a list of files
|
||||
for _, file := range files {
|
||||
|
||||
// Check if it exists or we can access
|
||||
if _, err := os.Stat(file); err != nil {
|
||||
// It does not exist or we can not access.
|
||||
// Return and stop loading
|
||||
return err
|
||||
}
|
||||
|
||||
// It exists and we have permission. Load it
|
||||
if err := godotenv.Overload(file); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
// Reload the env so all new changes are noticed
|
||||
Reload()
|
||||
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// Get a value from the ENV. If it doesn't exist the
|
||||
// default value will be returned.
|
||||
func Get(key string, value string) string {
|
||||
gil.RLock()
|
||||
defer gil.RUnlock()
|
||||
if v, ok := env[key]; ok {
|
||||
return v
|
||||
}
|
||||
return value
|
||||
}
|
||||
|
||||
// Get a value from the ENV. If it doesn't exist
|
||||
// an error will be returned
|
||||
func MustGet(key string) (string, error) {
|
||||
gil.RLock()
|
||||
defer gil.RUnlock()
|
||||
if v, ok := env[key]; ok {
|
||||
return v, nil
|
||||
}
|
||||
return "", fmt.Errorf("could not find ENV var with %s", key)
|
||||
}
|
||||
|
||||
// Set a value into the ENV. This is NOT permanent. It will
|
||||
// only affect values accessed through envy.
|
||||
func Set(key string, value string) {
|
||||
gil.Lock()
|
||||
defer gil.Unlock()
|
||||
env[key] = value
|
||||
}
|
||||
|
||||
// MustSet the value into the underlying ENV, as well as envy.
|
||||
// This may return an error if there is a problem setting the
|
||||
// underlying ENV value.
|
||||
func MustSet(key string, value string) error {
|
||||
gil.Lock()
|
||||
defer gil.Unlock()
|
||||
err := os.Setenv(key, value)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
env[key] = value
|
||||
return nil
|
||||
}
|
||||
|
||||
// Map all of the keys/values set in envy.
|
||||
func Map() map[string]string {
|
||||
gil.RLock()
|
||||
defer gil.RUnlock()
|
||||
cp := map[string]string{}
|
||||
for k, v := range env {
|
||||
cp[k] = v
|
||||
}
|
||||
return env
|
||||
}
|
||||
|
||||
// Temp makes a copy of the values and allows operation on
|
||||
// those values temporarily during the run of the function.
|
||||
// At the end of the function run the copy is discarded and
|
||||
// the original values are replaced. This is useful for testing.
|
||||
// Warning: This function is NOT safe to use from a goroutine or
|
||||
// from code which may access any Get or Set function from a goroutine
|
||||
func Temp(f func()) {
|
||||
oenv := env
|
||||
env = map[string]string{}
|
||||
for k, v := range oenv {
|
||||
env[k] = v
|
||||
}
|
||||
defer func() { env = oenv }()
|
||||
f()
|
||||
}
|
||||
|
||||
func GoPath() string {
|
||||
return Get("GOPATH", "")
|
||||
}
|
||||
|
||||
func GoBin() string {
|
||||
return Get("GO_BIN", "go")
|
||||
}
|
||||
|
||||
// GoPaths returns all possible GOPATHS that are set.
|
||||
func GoPaths() []string {
|
||||
gp := Get("GOPATH", "")
|
||||
if runtime.GOOS == "windows" {
|
||||
return strings.Split(gp, ";") // Windows uses a different separator
|
||||
}
|
||||
return strings.Split(gp, ":")
|
||||
}
|
||||
|
||||
func importPath(path string) string {
|
||||
path = strings.TrimPrefix(path, "/private")
|
||||
for _, gopath := range GoPaths() {
|
||||
srcpath := filepath.Join(gopath, "src")
|
||||
rel, err := filepath.Rel(srcpath, path)
|
||||
if err == nil {
|
||||
return filepath.ToSlash(rel)
|
||||
}
|
||||
}
|
||||
|
||||
// fallback to trim
|
||||
rel := strings.TrimPrefix(path, filepath.Join(GoPath(), "src"))
|
||||
rel = strings.TrimPrefix(rel, string(filepath.Separator))
|
||||
return filepath.ToSlash(rel)
|
||||
}
|
||||
|
||||
// CurrentModule will attempt to return the module name from `go.mod` if
|
||||
// modules are enabled.
|
||||
// If modules are not enabled it will fallback to using CurrentPackage instead.
|
||||
func CurrentModule() (string, error) {
|
||||
if !Mods() {
|
||||
return CurrentPackage(), nil
|
||||
}
|
||||
moddata, err := ioutil.ReadFile("go.mod")
|
||||
if err != nil {
|
||||
return "", errors.New("go.mod cannot be read or does not exist while go module is enabled")
|
||||
}
|
||||
packagePath := modfile.ModulePath(moddata)
|
||||
if packagePath == "" {
|
||||
return "", errors.New("go.mod is malformed")
|
||||
}
|
||||
return packagePath, nil
|
||||
}
|
||||
|
||||
// CurrentPackage attempts to figure out the current package name from the PWD
|
||||
// Use CurrentModule for a more accurate package name.
|
||||
func CurrentPackage() string {
|
||||
if Mods() {
|
||||
}
|
||||
pwd, _ := os.Getwd()
|
||||
return importPath(pwd)
|
||||
}
|
||||
|
||||
func Environ() []string {
|
||||
gil.RLock()
|
||||
defer gil.RUnlock()
|
||||
var e []string
|
||||
for k, v := range env {
|
||||
e = append(e, fmt.Sprintf("%s=%s", k, v))
|
||||
}
|
||||
return e
|
||||
}
|
||||
9
vendor/github.com/gobuffalo/envy/go.mod
generated
vendored
Normal file
9
vendor/github.com/gobuffalo/envy/go.mod
generated
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
module github.com/gobuffalo/envy
|
||||
|
||||
require (
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.14
|
||||
github.com/inconshreveable/mousetrap v1.0.0 // indirect
|
||||
github.com/joho/godotenv v1.3.0
|
||||
github.com/rogpeppe/go-internal v1.1.0
|
||||
github.com/stretchr/testify v1.3.0
|
||||
)
|
||||
383
vendor/github.com/gobuffalo/envy/go.sum
generated
vendored
Normal file
383
vendor/github.com/gobuffalo/envy/go.sum
generated
vendored
Normal file
@@ -0,0 +1,383 @@
|
||||
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
|
||||
github.com/Masterminds/semver v1.4.2/go.mod h1:MB6lktGJrhw8PrUyiEoblNEGEQ+RzHPF078ddwwvV3Y=
|
||||
github.com/ajg/form v0.0.0-20160822230020-523a5da1a92f/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY=
|
||||
github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
|
||||
github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ=
|
||||
github.com/cockroachdb/cockroach-go v0.0.0-20181001143604-e0a95dfd547c/go.mod h1:XGLbWH/ujMcbPbhZq52Nv6UrCghb1yGn//133kEsvDk=
|
||||
github.com/codegangsta/negroni v1.0.0/go.mod h1:v0y3T5G7Y1UlFfyxFn/QLRU4a2EuNau2iZY63YTKWo0=
|
||||
github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
|
||||
github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk=
|
||||
github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
|
||||
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
|
||||
github.com/dustin/go-humanize v0.0.0-20180713052910-9f541cc9db5d/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
|
||||
github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
|
||||
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
|
||||
github.com/fatih/structs v1.0.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M=
|
||||
github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M=
|
||||
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
|
||||
github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w=
|
||||
github.com/gobuffalo/buffalo v0.12.8-0.20181004233540-fac9bb505aa8/go.mod h1:sLyT7/dceRXJUxSsE813JTQtA3Eb1vjxWfo/N//vXIY=
|
||||
github.com/gobuffalo/buffalo v0.13.0/go.mod h1:Mjn1Ba9wpIbpbrD+lIDMy99pQ0H0LiddMIIDGse7qT4=
|
||||
github.com/gobuffalo/buffalo-plugins v1.0.2/go.mod h1:pOp/uF7X3IShFHyobahTkTLZaeUXwb0GrUTb9ngJWTs=
|
||||
github.com/gobuffalo/buffalo-plugins v1.0.4/go.mod h1:pWS1vjtQ6uD17MVFWf7i3zfThrEKWlI5+PYLw/NaDB4=
|
||||
github.com/gobuffalo/buffalo-plugins v1.4.3/go.mod h1:uCzTY0woez4nDMdQjkcOYKanngeUVRO2HZi7ezmAjWY=
|
||||
github.com/gobuffalo/buffalo-plugins v1.5.1/go.mod h1:jbmwSZK5+PiAP9cC09VQOrGMZFCa/P0UMlIS3O12r5w=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.4/go.mod h1:/+N1aophkA2jZ1ifB2O3Y9yGwu6gKOVMtUmJnbg+OZI=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.5/go.mod h1:0HVkbgrVs/MnPZ/FOseDMVanCTm2RNcdM0PuXcL1NNI=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.7/go.mod h1:ZGZRkzz2PiKWHs0z7QsPBOTo2EpcGRArMEym6ghKYgk=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.9/go.mod h1:yYlYTrPdMCz+6/+UaXg5Jm4gN3xhsvsQ2ygVatZV5vw=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.11/go.mod h1:eAA6xJIL8OuynJZ8amXjRmHND6YiusVAaJdHDN1Lu8Q=
|
||||
github.com/gobuffalo/buffalo-plugins v1.8.2/go.mod h1:9te6/VjEQ7pKp7lXlDIMqzxgGpjlKoAcAANdCgoR960=
|
||||
github.com/gobuffalo/buffalo-plugins v1.8.3/go.mod h1:IAWq6vjZJVXebIq2qGTLOdlXzmpyTZ5iJG5b59fza5U=
|
||||
github.com/gobuffalo/buffalo-plugins v1.9.4/go.mod h1:grCV6DGsQlVzQwk6XdgcL3ZPgLm9BVxlBmXPMF8oBHI=
|
||||
github.com/gobuffalo/buffalo-plugins v1.10.0 h1:oF+BJ20zenp31xJnjkFcXAMUqlrMMTicsD/UwQWCW/s=
|
||||
github.com/gobuffalo/buffalo-plugins v1.10.0/go.mod h1:4osg8d9s60txLuGwXnqH+RCjPHj9K466cDFRl3PErHI=
|
||||
github.com/gobuffalo/buffalo-pop v1.0.5/go.mod h1:Fw/LfFDnSmB/vvQXPvcXEjzP98Tc+AudyNWUBWKCwQ8=
|
||||
github.com/gobuffalo/envy v1.6.4/go.mod h1:Abh+Jfw475/NWtYMEt+hnJWRiC8INKWibIMyNt1w2Mc=
|
||||
github.com/gobuffalo/envy v1.6.5/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.6/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.7/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.8/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.9/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.10/go.mod h1:X0CFllQjTV5ogsnUrg+Oks2yTI+PU2dGYBJOEI2D1Uo=
|
||||
github.com/gobuffalo/envy v1.6.11/go.mod h1:Fiq52W7nrHGDggFPhn2ZCcHw4u/rqXkqo+i7FB6EAcg=
|
||||
github.com/gobuffalo/events v1.0.3/go.mod h1:Txo8WmqScapa7zimEQIwgiJBvMECMe9gJjsKNPN3uZw=
|
||||
github.com/gobuffalo/events v1.0.7/go.mod h1:z8txf6H9jWhQ5Scr7YPLWg/cgXBRj8Q4uYI+rsVCCSQ=
|
||||
github.com/gobuffalo/events v1.0.8/go.mod h1:A5KyqT1sA+3GJiBE4QKZibse9mtOcI9nw8gGrDdqYGs=
|
||||
github.com/gobuffalo/events v1.1.3/go.mod h1:9yPGWYv11GENtzrIRApwQRMYSbUgCsZ1w6R503fCfrk=
|
||||
github.com/gobuffalo/events v1.1.4/go.mod h1:09/YRRgZHEOts5Isov+g9X2xajxdvOAcUuAHIX/O//A=
|
||||
github.com/gobuffalo/events v1.1.5/go.mod h1:3YUSzgHfYctSjEjLCWbkXP6djH2M+MLaVRzb4ymbAK0=
|
||||
github.com/gobuffalo/events v1.1.7/go.mod h1:6fGqxH2ing5XMb3EYRq9LEkVlyPGs4oO/eLzh+S8CxY=
|
||||
github.com/gobuffalo/events v1.1.8/go.mod h1:UFy+W6X6VbCWS8k2iT81HYX65dMtiuVycMy04cplt/8=
|
||||
github.com/gobuffalo/events v1.1.9 h1:ukq5ys/h0TuiX7eLJyZBD1dJOy0r19JTEYmgXKG9j+Y=
|
||||
github.com/gobuffalo/events v1.1.9/go.mod h1:/0nf8lMtP5TkgNbzYxR6Bl4GzBy5s5TebgNTdRfRbPM=
|
||||
github.com/gobuffalo/fizz v1.0.12/go.mod h1:C0sltPxpYK8Ftvf64kbsQa2yiCZY4RZviurNxXdAKwc=
|
||||
github.com/gobuffalo/flect v0.0.0-20180907193754-dc14d8acaf9f/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181002182613-4571df4b1daf/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181007231023-ae7ed6bfe683/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181018182602-fd24a256709f/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181019110701-3d6f0b585514/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181024204909-8f6be1a8c6c2/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181104133451-1f6e9779237a/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181114183036-47375f6d8328/go.mod h1:0HvNbHdfh+WOvDSIASqJOSxTOWSxCCUF++k/Y53v9rI=
|
||||
github.com/gobuffalo/flect v0.0.0-20181210151238-24a2b68e0316/go.mod h1:en58vff74S9b99Eg42Dr+/9yPu437QjlNsO/hBYPuOk=
|
||||
github.com/gobuffalo/flect v0.0.0-20190104192022-4af577e09bf2 h1:51NF9n6h4nGMooU5ALB+uJCM0UOmcWjAegIZb/ePtoE=
|
||||
github.com/gobuffalo/flect v0.0.0-20190104192022-4af577e09bf2/go.mod h1:en58vff74S9b99Eg42Dr+/9yPu437QjlNsO/hBYPuOk=
|
||||
github.com/gobuffalo/genny v0.0.0-20180924032338-7af3a40f2252/go.mod h1:tUTQOogrr7tAQnhajMSH6rv1BVev34H2sa1xNHMy94g=
|
||||
github.com/gobuffalo/genny v0.0.0-20181003150629-3786a0744c5d/go.mod h1:WAd8HmjMVrnkAZbmfgH5dLBUchsZfqzp/WS5sQz+uTM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181005145118-318a41a134cc/go.mod h1:WAd8HmjMVrnkAZbmfgH5dLBUchsZfqzp/WS5sQz+uTM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181007153042-b8de7d566757/go.mod h1:+oG5Ljrw04czAHbPXREwaFojJbpUvcIy4DiOnbEJFTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181012161047-33e5f43d83a6/go.mod h1:+oG5Ljrw04czAHbPXREwaFojJbpUvcIy4DiOnbEJFTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181017160347-90a774534246/go.mod h1:+oG5Ljrw04czAHbPXREwaFojJbpUvcIy4DiOnbEJFTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181024195656-51392254bf53/go.mod h1:o9GEH5gn5sCKLVB5rHFC4tq40rQ3VRUzmx6WwmaqISE=
|
||||
github.com/gobuffalo/genny v0.0.0-20181025145300-af3f81d526b8/go.mod h1:uZ1fFYvdcP8mu0B/Ynarf6dsGvp7QFIpk/QACUuFUVI=
|
||||
github.com/gobuffalo/genny v0.0.0-20181027191429-94d6cfb5c7fc/go.mod h1:x7SkrQQBx204Y+O9EwRXeszLJDTaWN0GnEasxgLrQTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181027195209-3887b7171c4f/go.mod h1:JbKx8HSWICu5zyqWOa0dVV1pbbXOHusrSzQUprW6g+w=
|
||||
github.com/gobuffalo/genny v0.0.0-20181106193839-7dcb0924caf1/go.mod h1:x61yHxvbDCgQ/7cOAbJCacZQuHgB0KMSzoYcw5debjU=
|
||||
github.com/gobuffalo/genny v0.0.0-20181107223128-f18346459dbe/go.mod h1:utQD3aKKEsdb03oR+Vi/6ztQb1j7pO10N3OBoowRcSU=
|
||||
github.com/gobuffalo/genny v0.0.0-20181114215459-0a4decd77f5d/go.mod h1:kN2KZ8VgXF9VIIOj/GM0Eo7YK+un4Q3tTreKOf0q1ng=
|
||||
github.com/gobuffalo/genny v0.0.0-20181119162812-e8ff4adce8bb/go.mod h1:BA9htSe4bZwBDJLe8CUkoqkypq3hn3+CkoHqVOW718E=
|
||||
github.com/gobuffalo/genny v0.0.0-20181127225641-2d959acc795b/go.mod h1:l54xLXNkteX/PdZ+HlgPk1qtcrgeOr3XUBBPDbH+7CQ=
|
||||
github.com/gobuffalo/genny v0.0.0-20181128191930-77e34f71ba2a/go.mod h1:FW/D9p7cEEOqxYA71/hnrkOWm62JZ5ZNxcNIVJEaWBU=
|
||||
github.com/gobuffalo/genny v0.0.0-20181203165245-fda8bcce96b1/go.mod h1:wpNSANu9UErftfiaAlz1pDZclrYzLtO5lALifODyjuM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181203201232-849d2c9534ea/go.mod h1:wpNSANu9UErftfiaAlz1pDZclrYzLtO5lALifODyjuM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181206121324-d6fb8a0dbe36/go.mod h1:wpNSANu9UErftfiaAlz1pDZclrYzLtO5lALifODyjuM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181207164119-84844398a37d/go.mod h1:y0ysCHGGQf2T3vOhCrGHheYN54Y/REj0ayd0Suf4C/8=
|
||||
github.com/gobuffalo/genny v0.0.0-20181211165820-e26c8466f14d/go.mod h1:sHnK+ZSU4e2feXP3PA29ouij6PUEiN+RCwECjCTB3yM=
|
||||
github.com/gobuffalo/genny v0.0.0-20190104222617-a71664fc38e7/go.mod h1:QPsQ1FnhEsiU8f+O0qKWXz2RE4TiDqLVChWkBuh1WaY=
|
||||
github.com/gobuffalo/genny v0.0.0-20190112155932-f31a84fcacf5 h1:boQS3dA9PxhyufJEWIILrG6pJQbDnpwP2rFyvWacdoY=
|
||||
github.com/gobuffalo/genny v0.0.0-20190112155932-f31a84fcacf5/go.mod h1:CIaHCrSIuJ4il6ka3Hub4DR4adDrGoXGEEt2FbBxoIo=
|
||||
github.com/gobuffalo/github_flavored_markdown v1.0.4/go.mod h1:uRowCdK+q8d/RF0Kt3/DSalaIXbb0De/dmTqMQdkQ4I=
|
||||
github.com/gobuffalo/github_flavored_markdown v1.0.5/go.mod h1:U0643QShPF+OF2tJvYNiYDLDGDuQmJZXsf/bHOJPsMY=
|
||||
github.com/gobuffalo/github_flavored_markdown v1.0.7/go.mod h1:w93Pd9Lz6LvyQXEG6DktTPHkOtCbr+arAD5mkwMzXLI=
|
||||
github.com/gobuffalo/httptest v1.0.2/go.mod h1:7T1IbSrg60ankme0aDLVnEY0h056g9M1/ZvpVThtB7E=
|
||||
github.com/gobuffalo/licenser v0.0.0-20180924033006-eae28e638a42/go.mod h1:Ubo90Np8gpsSZqNScZZkVXXAo5DGhTb+WYFIjlnog8w=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181025145548-437d89de4f75/go.mod h1:x3lEpYxkRG/XtGCUNkio+6RZ/dlOvLzTI9M1auIwFcw=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181027200154-58051a75da95/go.mod h1:BzhaaxGd1tq1+OLKObzgdCV9kqVhbTulxOpYbvMQWS0=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181109171355-91a2a7aac9a7/go.mod h1:m+Ygox92pi9bdg+gVaycvqE8RVSjZp7mWw75+K5NPHk=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181128165715-cc7305f8abed/go.mod h1:oU9F9UCE+AzI/MueCKZamsezGOOHfSirltllOVeRTAE=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181203160806-fe900bbede07/go.mod h1:ph6VDNvOzt1CdfaWC+9XwcBnlSTBz2j49PBwum6RFaU=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181211173111-f8a311c51159/go.mod h1:ve/Ue99DRuvnTaLq2zKa6F4KtHiYf7W046tDjuGYPfM=
|
||||
github.com/gobuffalo/logger v0.0.0-20181022175615-46cfb361fc27/go.mod h1:8sQkgyhWipz1mIctHF4jTxmJh1Vxhp7mP8IqbljgJZo=
|
||||
github.com/gobuffalo/logger v0.0.0-20181027144941-73d08d2bb969/go.mod h1:7uGg2duHKpWnN4+YmyKBdLXfhopkAdVM6H3nKbyFbz8=
|
||||
github.com/gobuffalo/logger v0.0.0-20181027193913-9cf4dd0efe46/go.mod h1:7uGg2duHKpWnN4+YmyKBdLXfhopkAdVM6H3nKbyFbz8=
|
||||
github.com/gobuffalo/logger v0.0.0-20181109185836-3feeab578c17/go.mod h1:oNErH0xLe+utO+OW8ptXMSA5DkiSEDW1u3zGIt8F9Ew=
|
||||
github.com/gobuffalo/logger v0.0.0-20181117211126-8e9b89b7c264/go.mod h1:5etB91IE0uBlw9k756fVKZJdS+7M7ejVhmpXXiSFj0I=
|
||||
github.com/gobuffalo/logger v0.0.0-20181127160119-5b956e21995c/go.mod h1:+HxKANrR9VGw9yN3aOAppJKvhO05ctDi63w4mDnKv2U=
|
||||
github.com/gobuffalo/makr v1.1.5/go.mod h1:Y+o0btAH1kYAMDJW/TX3+oAXEu0bmSLLoC9mIFxtzOw=
|
||||
github.com/gobuffalo/mapi v1.0.0/go.mod h1:4VAGh89y6rVOvm5A8fKFxYG+wIW6LO1FMTG9hnKStFc=
|
||||
github.com/gobuffalo/mapi v1.0.1/go.mod h1:4VAGh89y6rVOvm5A8fKFxYG+wIW6LO1FMTG9hnKStFc=
|
||||
github.com/gobuffalo/meta v0.0.0-20181018155829-df62557efcd3/go.mod h1:XTTOhwMNryif3x9LkTTBO/Llrveezd71u3quLd0u7CM=
|
||||
github.com/gobuffalo/meta v0.0.0-20181018192820-8c6cef77dab3/go.mod h1:E94EPzx9NERGCY69UWlcj6Hipf2uK/vnfrF4QD0plVE=
|
||||
github.com/gobuffalo/meta v0.0.0-20181025145500-3a985a084b0a/go.mod h1:YDAKBud2FP7NZdruCSlmTmDOZbVSa6bpK7LJ/A/nlKg=
|
||||
github.com/gobuffalo/meta v0.0.0-20181114191255-b130ebedd2f7/go.mod h1:K6cRZ29ozr4Btvsqkjvg5nDFTLOgTqf03KA70Ks0ypE=
|
||||
github.com/gobuffalo/meta v0.0.0-20181127070345-0d7e59dd540b/go.mod h1:RLO7tMvE0IAKAM8wny1aN12pvEKn7EtkBLkUZR00Qf8=
|
||||
github.com/gobuffalo/mw-basicauth v1.0.3/go.mod h1:dg7+ilMZOKnQFHDefUzUHufNyTswVUviCBgF244C1+0=
|
||||
github.com/gobuffalo/mw-contenttype v0.0.0-20180802152300-74f5a47f4d56/go.mod h1:7EvcmzBbeCvFtQm5GqF9ys6QnCxz2UM1x0moiWLq1No=
|
||||
github.com/gobuffalo/mw-csrf v0.0.0-20180802151833-446ff26e108b/go.mod h1:sbGtb8DmDZuDUQoxjr8hG1ZbLtZboD9xsn6p77ppcHo=
|
||||
github.com/gobuffalo/mw-forcessl v0.0.0-20180802152810-73921ae7a130/go.mod h1:JvNHRj7bYNAMUr/5XMkZaDcw3jZhUZpsmzhd//FFWmQ=
|
||||
github.com/gobuffalo/mw-i18n v0.0.0-20180802152014-e3060b7e13d6/go.mod h1:91AQfukc52A6hdfIfkxzyr+kpVYDodgAeT5cjX1UIj4=
|
||||
github.com/gobuffalo/mw-paramlogger v0.0.0-20181005191442-d6ee392ec72e/go.mod h1:6OJr6VwSzgJMqWMj7TYmRUqzNe2LXu/W1rRW4MAz/ME=
|
||||
github.com/gobuffalo/mw-tokenauth v0.0.0-20181001105134-8545f626c189/go.mod h1:UqBF00IfKvd39ni5+yI5MLMjAf4gX7cDKN/26zDOD6c=
|
||||
github.com/gobuffalo/packd v0.0.0-20181027182251-01ad393492c8/go.mod h1:SmdBdhj6uhOsg1Ui4SFAyrhuc7U4VCildosO5IDJ3lc=
|
||||
github.com/gobuffalo/packd v0.0.0-20181027190505-aafc0d02c411/go.mod h1:SmdBdhj6uhOsg1Ui4SFAyrhuc7U4VCildosO5IDJ3lc=
|
||||
github.com/gobuffalo/packd v0.0.0-20181027194105-7ae579e6d213/go.mod h1:SmdBdhj6uhOsg1Ui4SFAyrhuc7U4VCildosO5IDJ3lc=
|
||||
github.com/gobuffalo/packd v0.0.0-20181031195726-c82734870264/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181104210303-d376b15f8e96/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181111195323-b2e760a5f0ff/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181114190715-f25c5d2471d7/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181124090624-311c6248e5fb/go.mod h1:Foenia9ZvITEvG05ab6XpiD5EfBHPL8A6hush8SJ0o8=
|
||||
github.com/gobuffalo/packd v0.0.0-20181207120301-c49825f8f6f4/go.mod h1:LYc0TGKFBBFTRC9dg2pcRcMqGCTMD7T2BIMP7OBuQAA=
|
||||
github.com/gobuffalo/packd v0.0.0-20181212173646-eca3b8fd6687 h1:uZ+G4JprR0UEq0aHZs+6eP7TEZuFfrIkmQWejIBV/QQ=
|
||||
github.com/gobuffalo/packd v0.0.0-20181212173646-eca3b8fd6687/go.mod h1:LYc0TGKFBBFTRC9dg2pcRcMqGCTMD7T2BIMP7OBuQAA=
|
||||
github.com/gobuffalo/packr v1.13.7/go.mod h1:KkinLIn/n6+3tVXMwg6KkNvWwVsrRAz4ph+jgpk3Z24=
|
||||
github.com/gobuffalo/packr v1.15.0/go.mod h1:t5gXzEhIviQwVlNx/+3SfS07GS+cZ2hn76WLzPp6MGI=
|
||||
github.com/gobuffalo/packr v1.15.1/go.mod h1:IeqicJ7jm8182yrVmNbM6PR4g79SjN9tZLH8KduZZwE=
|
||||
github.com/gobuffalo/packr v1.19.0/go.mod h1:MstrNkfCQhd5o+Ct4IJ0skWlxN8emOq8DsoT1G98VIU=
|
||||
github.com/gobuffalo/packr v1.20.0/go.mod h1:JDytk1t2gP+my1ig7iI4NcVaXr886+N0ecUga6884zw=
|
||||
github.com/gobuffalo/packr v1.21.0/go.mod h1:H00jGfj1qFKxscFJSw8wcL4hpQtPe1PfU2wa6sg/SR0=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.8/go.mod h1:y60QCdzwuMwO2R49fdQhsjCPv7tLQFR0ayzxxla9zes=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.9/go.mod h1:fQqADRfZpEsgkc7c/K7aMew3n4aF1Kji7+lIZeR98Fc=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.10/go.mod h1:4CWWn4I5T3v4c1OsJ55HbHlUEKNWMITG5iIkdr4Px4w=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.11/go.mod h1:JoieH/3h3U4UmatmV93QmqyPUdf4wVM9HELaHEu+3fk=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.12/go.mod h1:FV1zZTsVFi1DSCboO36Xgs4pzCZBjB/tDV9Cz/lSaR8=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.13/go.mod h1:2Mp7GhBFMdJlOK8vGfl7SYtfMP3+5roE39ejlfjw0rA=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.14 h1:K41dNilNHDbDgCL3UE6K02JGuN89pjvD9oG99X7Om2s=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.14/go.mod h1:06otbrNvDKO1eNQ3b8hst+1010UooI2MFg+B2Ze4MV8=
|
||||
github.com/gobuffalo/plush v3.7.16+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.20+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.21+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.22+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.23+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.30+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.31+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.32+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20181128164830-d29dcb966cb2/go.mod h1:r9QwptTFnuvSaSRjpSp4S2/4e2D3tJhARYbvEBcKSb4=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20181203163832-9fc4964505c2/go.mod h1:opEdT33AA2HdrIwK1aibqnTJDVVKXC02Bar/GT1YRVs=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20181207152837-eedb135bd51b/go.mod h1:Lcw7HQbEVm09sAQrCLzIxuhFbB3nAgp4c55E+UlynR0=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20190104222512-177cd2b872b3/go.mod h1:tYxCozi8X62bpZyKXYHw1ncx2ZtT2nFvG42kuLwYjoc=
|
||||
github.com/gobuffalo/pop v4.8.2+incompatible/go.mod h1:DwBz3SD5SsHpTZiTubcsFWcVDpJWGsxjVjMPnkiThWg=
|
||||
github.com/gobuffalo/pop v4.8.3+incompatible/go.mod h1:DwBz3SD5SsHpTZiTubcsFWcVDpJWGsxjVjMPnkiThWg=
|
||||
github.com/gobuffalo/pop v4.8.4+incompatible/go.mod h1:DwBz3SD5SsHpTZiTubcsFWcVDpJWGsxjVjMPnkiThWg=
|
||||
github.com/gobuffalo/release v1.0.35/go.mod h1:VtHFAKs61vO3wboCec5xr9JPTjYyWYcvaM3lclkc4x4=
|
||||
github.com/gobuffalo/release v1.0.38/go.mod h1:VtHFAKs61vO3wboCec5xr9JPTjYyWYcvaM3lclkc4x4=
|
||||
github.com/gobuffalo/release v1.0.42/go.mod h1:RPs7EtafH4oylgetOJpGP0yCZZUiO4vqHfTHJjSdpug=
|
||||
github.com/gobuffalo/release v1.0.52/go.mod h1:RPs7EtafH4oylgetOJpGP0yCZZUiO4vqHfTHJjSdpug=
|
||||
github.com/gobuffalo/release v1.0.53/go.mod h1:FdF257nd8rqhNaqtDWFGhxdJ/Ig4J7VcS3KL7n/a+aA=
|
||||
github.com/gobuffalo/release v1.0.54/go.mod h1:Pe5/RxRa/BE8whDpGfRqSI7D1a0evGK1T4JDm339tJc=
|
||||
github.com/gobuffalo/release v1.0.61/go.mod h1:mfIO38ujUNVDlBziIYqXquYfBF+8FDHUjKZgYC1Hj24=
|
||||
github.com/gobuffalo/release v1.0.72/go.mod h1:NP5NXgg/IX3M5XmHmWR99D687/3Dt9qZtTK/Lbwc1hU=
|
||||
github.com/gobuffalo/release v1.1.1/go.mod h1:Sluak1Xd6kcp6snkluR1jeXAogdJZpFFRzTYRs/2uwg=
|
||||
github.com/gobuffalo/release v1.1.3/go.mod h1:CuXc5/m+4zuq8idoDt1l4va0AXAn/OSs08uHOfMVr8E=
|
||||
github.com/gobuffalo/release v1.1.6/go.mod h1:18naWa3kBsqO0cItXZNJuefCKOENpbbUIqRL1g+p6z0=
|
||||
github.com/gobuffalo/shoulders v1.0.1/go.mod h1:V33CcVmaQ4gRUmHKwq1fiTXuf8Gp/qjQBUL5tHPmvbA=
|
||||
github.com/gobuffalo/syncx v0.0.0-20181120191700-98333ab04150/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw=
|
||||
github.com/gobuffalo/syncx v0.0.0-20181120194010-558ac7de985f/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw=
|
||||
github.com/gobuffalo/tags v2.0.11+incompatible/go.mod h1:9XmhOkyaB7UzvuY4UoZO4s67q8/xRMVJEaakauVQYeY=
|
||||
github.com/gobuffalo/tags v2.0.14+incompatible/go.mod h1:9XmhOkyaB7UzvuY4UoZO4s67q8/xRMVJEaakauVQYeY=
|
||||
github.com/gobuffalo/tags v2.0.15+incompatible/go.mod h1:9XmhOkyaB7UzvuY4UoZO4s67q8/xRMVJEaakauVQYeY=
|
||||
github.com/gobuffalo/uuid v2.0.3+incompatible/go.mod h1:ErhIzkRhm0FtRuiE/PeORqcw4cVi1RtSpnwYrxuvkfE=
|
||||
github.com/gobuffalo/uuid v2.0.4+incompatible/go.mod h1:ErhIzkRhm0FtRuiE/PeORqcw4cVi1RtSpnwYrxuvkfE=
|
||||
github.com/gobuffalo/uuid v2.0.5+incompatible/go.mod h1:ErhIzkRhm0FtRuiE/PeORqcw4cVi1RtSpnwYrxuvkfE=
|
||||
github.com/gobuffalo/validate v2.0.3+incompatible/go.mod h1:N+EtDe0J8252BgfzQUChBgfd6L93m9weay53EWFVsMM=
|
||||
github.com/gobuffalo/x v0.0.0-20181003152136-452098b06085/go.mod h1:WevpGD+5YOreDJznWevcn8NTmQEW5STSBgIkpkjzqXc=
|
||||
github.com/gobuffalo/x v0.0.0-20181007152206-913e47c59ca7/go.mod h1:9rDPXaB3kXdKWzMc4odGQQdG2e2DIEmANy5aSJ9yesY=
|
||||
github.com/gofrs/uuid v3.1.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM=
|
||||
github.com/golang/protobuf v1.1.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg=
|
||||
github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
|
||||
github.com/gorilla/pat v0.0.0-20180118222023-199c85a7f6d1/go.mod h1:YeAe0gNeiNT5hoiZRI4yiOky6jVdNvfO2N6Kav/HmxY=
|
||||
github.com/gorilla/securecookie v1.1.1/go.mod h1:ra0sb63/xPlUeL+yeDciTfxMRAA+MP+HVt/4epWDjd4=
|
||||
github.com/gorilla/sessions v1.1.2/go.mod h1:8KCfur6+4Mqcc6S0FEfKuN15Vl5MgXW92AE8ovaJD0w=
|
||||
github.com/gorilla/sessions v1.1.3/go.mod h1:8KCfur6+4Mqcc6S0FEfKuN15Vl5MgXW92AE8ovaJD0w=
|
||||
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
|
||||
github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU=
|
||||
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
|
||||
github.com/jackc/fake v0.0.0-20150926172116-812a484cc733/go.mod h1:WrMFNQdiFJ80sQsxDoMokWK1W5TQtxBFNpzWTD84ibQ=
|
||||
github.com/jackc/pgx v3.2.0+incompatible/go.mod h1:0ZGrqGqkRlliWnWB4zKnWtjbSWbGkVEFm4TeybAXq+I=
|
||||
github.com/jmoiron/sqlx v0.0.0-20180614180643-0dae4fefe7c0/go.mod h1:IiEW3SEiiErVyFdH8NTuWjSifiEQKUoyK3LNqr2kCHU=
|
||||
github.com/joho/godotenv v1.2.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg=
|
||||
github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg=
|
||||
github.com/karrick/godirwalk v1.7.5/go.mod h1:2c9FRhkDxdIbgkOnCEvnSWs71Bhugbl46shStcFDJ34=
|
||||
github.com/karrick/godirwalk v1.7.7/go.mod h1:2c9FRhkDxdIbgkOnCEvnSWs71Bhugbl46shStcFDJ34=
|
||||
github.com/karrick/godirwalk v1.7.8 h1:VfG72pyIxgtC7+3X9CMHI0AOl4LwyRAg98WAgsvffi8=
|
||||
github.com/karrick/godirwalk v1.7.8/go.mod h1:2c9FRhkDxdIbgkOnCEvnSWs71Bhugbl46shStcFDJ34=
|
||||
github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51/go.mod h1:CzGEWj7cYgsdH8dAjBGEr58BoE7ScuLd+fwFZ44+/x8=
|
||||
github.com/konsorten/go-windows-terminal-sequences v0.0.0-20180402223658-b729f2633dfe/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
|
||||
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
|
||||
github.com/kr/pty v1.1.3/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
|
||||
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
|
||||
github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
|
||||
github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
|
||||
github.com/markbates/deplist v1.0.4/go.mod h1:gRRbPbbuA8TmMiRvaOzUlRfzfjeCCBqX2A6arxN01MM=
|
||||
github.com/markbates/deplist v1.0.5/go.mod h1:gRRbPbbuA8TmMiRvaOzUlRfzfjeCCBqX2A6arxN01MM=
|
||||
github.com/markbates/going v1.0.2/go.mod h1:UWCk3zm0UKefHZ7l8BNqi26UyiEMniznk8naLdTcy6c=
|
||||
github.com/markbates/grift v1.0.4/go.mod h1:wbmtW74veyx+cgfwFhlnnMWqhoz55rnHR47oMXzsyVs=
|
||||
github.com/markbates/hmax v1.0.0/go.mod h1:cOkR9dktiESxIMu+65oc/r/bdY4bE8zZw3OLhLx0X2c=
|
||||
github.com/markbates/inflect v1.0.0/go.mod h1:oTeZL2KHA7CUX6X+fovmK9OvIOFuqu0TwdQrZjLTh88=
|
||||
github.com/markbates/inflect v1.0.1/go.mod h1:uv3UVNBe5qBIfCm8O8Q+DW+S1EopeyINj+Ikhc7rnCk=
|
||||
github.com/markbates/inflect v1.0.3/go.mod h1:1fR9+pO2KHEO9ZRtto13gDwwZaAKstQzferVeWqbgNs=
|
||||
github.com/markbates/inflect v1.0.4/go.mod h1:1fR9+pO2KHEO9ZRtto13gDwwZaAKstQzferVeWqbgNs=
|
||||
github.com/markbates/oncer v0.0.0-20180924031910-e862a676800b/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/oncer v0.0.0-20180924034138-723ad0170a46/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/oncer v0.0.0-20181014194634-05fccaae8fc4/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/oncer v0.0.0-20181203154359-bf2de49a0be2/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/refresh v1.4.10/go.mod h1:NDPHvotuZmTmesXxr95C9bjlw1/0frJwtME2dzcVKhc=
|
||||
github.com/markbates/safe v1.0.0/go.mod h1:nAqgmRi7cY2nqMc92/bSEeQA+R4OheNU2T1kNSCBdG0=
|
||||
github.com/markbates/safe v1.0.1/go.mod h1:nAqgmRi7cY2nqMc92/bSEeQA+R4OheNU2T1kNSCBdG0=
|
||||
github.com/markbates/sigtx v1.0.0/go.mod h1:QF1Hv6Ic6Ca6W+T+DL0Y/ypborFKyvUY9HmuCD4VeTc=
|
||||
github.com/markbates/willie v1.0.9/go.mod h1:fsrFVWl91+gXpx/6dv715j7i11fYPfZ9ZGfH0DQzY7w=
|
||||
github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU=
|
||||
github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
|
||||
github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc=
|
||||
github.com/microcosm-cc/bluemonday v1.0.1/go.mod h1:hsXNsILzKxV+sX77C5b8FSuKF00vh2OMYv+xgHpAMF4=
|
||||
github.com/microcosm-cc/bluemonday v1.0.2/go.mod h1:iVP4YcDBq+n/5fb23BhYFvIMq/leAFZyRl6bYmGDlGc=
|
||||
github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
|
||||
github.com/mitchellh/mapstructure v1.0.0/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
|
||||
github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
|
||||
github.com/monoculum/formam v0.0.0-20180901015400-4e68be1d79ba/go.mod h1:RKgILGEJq24YyJ2ban8EO0RUVSJlF1pGsEvoLEACr/Q=
|
||||
github.com/nicksnyder/go-i18n v1.10.0/go.mod h1:HrK7VCrbOvQoUAQ7Vpy7i87N7JZZZ7R2xBGjv0j365Q=
|
||||
github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/gomega v1.4.1/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
|
||||
github.com/onsi/gomega v1.4.2/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
|
||||
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
github.com/pkg/errors v0.8.1 h1:iURUrRGxPUNPdy5/HRSm+Yj6okJ6UtLINN0Q9M4+h3I=
|
||||
github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||
github.com/rogpeppe/go-internal v1.0.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
|
||||
github.com/rogpeppe/go-internal v1.1.0 h1:g0fH8RicVgNl+zVZDCDfbdWxAWoAEJyI7I3TZYXFiig=
|
||||
github.com/rogpeppe/go-internal v1.1.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
|
||||
github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0=
|
||||
github.com/serenize/snaker v0.0.0-20171204205717-a683aaf2d516/go.mod h1:Yow6lPLSAXx2ifx470yD/nUe22Dv5vBvxK/UK9UUTVs=
|
||||
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
|
||||
github.com/shopspring/decimal v0.0.0-20180709203117-cd690d0c9e24/go.mod h1:M+9NzErvs504Cn4c5DxATwIqPbtswREoFCre64PpcG4=
|
||||
github.com/shurcooL/go v0.0.0-20180423040247-9e1955d9fb6e/go.mod h1:TDJrrUr11Vxrven61rcy3hJMUqaf/CLWYhHNPmT14Lk=
|
||||
github.com/shurcooL/go-goon v0.0.0-20170922171312-37c2f522c041/go.mod h1:N5mDOmsrJOB+vfqUK+7DmDyjhSLIIBnXo9lvZJj3MWQ=
|
||||
github.com/shurcooL/highlight_diff v0.0.0-20170515013008-09bb4053de1b/go.mod h1:ZpfEhSmds4ytuByIcDnOLkTHGUI6KNqRNPDLHDk+mUU=
|
||||
github.com/shurcooL/highlight_go v0.0.0-20170515013102-78fb10f4a5f8/go.mod h1:UDKB5a1T23gOMUJrI+uSuH0VRDStOiUVSjBTRDVBVag=
|
||||
github.com/shurcooL/octicon v0.0.0-20180602230221-c42b0e3b24d9/go.mod h1:eWdoE5JD4R5UVWDucdOPg1g2fqQRq78IQa9zlOV1vpQ=
|
||||
github.com/shurcooL/sanitized_anchor_name v0.0.0-20170918181015-86672fcb3f95/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
|
||||
github.com/sirupsen/logrus v1.0.6/go.mod h1:pMByvHTf9Beacp5x1UXfOR9xyW/9antXMhjMPG0dEzc=
|
||||
github.com/sirupsen/logrus v1.1.0/go.mod h1:zrgwTnHtNr00buQ1vSptGe8m1f/BbgsPukg8qsT7A+A=
|
||||
github.com/sirupsen/logrus v1.1.1/go.mod h1:zrgwTnHtNr00buQ1vSptGe8m1f/BbgsPukg8qsT7A+A=
|
||||
github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
|
||||
github.com/sirupsen/logrus v1.3.0 h1:hI/7Q+DtNZ2kINb6qt/lS+IyXnHQe9e90POfeewL/ME=
|
||||
github.com/sirupsen/logrus v1.3.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
|
||||
github.com/sourcegraph/annotate v0.0.0-20160123013949-f4cad6c6324d/go.mod h1:UdhH50NIW0fCiwBSr0co2m7BnFLdv4fQTgdqdJTHFeE=
|
||||
github.com/sourcegraph/syntaxhighlight v0.0.0-20170531221838-bd320f5d308e/go.mod h1:HuIsMU8RRBOtsCgI77wP899iHVBQpCmg4ErYMZB+2IA=
|
||||
github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
|
||||
github.com/spf13/afero v1.2.0/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk=
|
||||
github.com/spf13/cast v1.2.0/go.mod h1:r2rcYCSwa1IExKTDiTfzaxqT2FNHs8hODu4LnUfgKEg=
|
||||
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
|
||||
github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
|
||||
github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
|
||||
github.com/spf13/pflag v1.0.2/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
|
||||
github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
|
||||
github.com/spf13/viper v1.2.1/go.mod h1:P4AexN0a+C9tGAnUFNwDMYYZv3pjFuvmeiMyKRaNVlI=
|
||||
github.com/spf13/viper v1.3.1/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s=
|
||||
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
|
||||
github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q=
|
||||
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
|
||||
github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0=
|
||||
github.com/unrolled/secure v0.0.0-20180918153822-f340ee86eb8b/go.mod h1:mnPT77IAdsi/kV7+Es7y+pXALeV3h7G6dQF6mNYjcLA=
|
||||
github.com/unrolled/secure v0.0.0-20181005190816-ff9db2ff917f/go.mod h1:mnPT77IAdsi/kV7+Es7y+pXALeV3h7G6dQF6mNYjcLA=
|
||||
github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q=
|
||||
golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20180910181607-0e37d006457b/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181001203147-e3636079e1a4/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181009213950-7c1a557ab941/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181015023909-0c41d7ab0a0e/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181024171144-74cb1d3d52f4/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181025113841-85e1b3f9139a/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181025213731-e84da0312774/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181106171534-e4dc69e5b2fd/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181112202954-3d3f9f413869/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181127143415-eb0de9b17e85/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20190102171810-8d7daa0c54b3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20190103213133-ff983b9c42bc h1:F5tKCVGp+MUAHhKp5MZtGqAlGX3+oCsiL1Q629FL90M=
|
||||
golang.org/x/crypto v0.0.0-20190103213133-ff983b9c42bc/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180816102801-aaf60122140d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180921000356-2f5d2388922f/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180926154720-4dfa2610cdf3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181005035420-146acd28ed58/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181011144130-49bb7cea24b1/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181017193950-04a2e542c03f/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181102091132-c10e9556a7bc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181106065722-10aee1819953/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181207154023-610586996380/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4 h1:YUO/7uOKsKeq9UokNS62b8FYywz3ker1l1vDZRCRefw=
|
||||
golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sys v0.0.0-20180816055513-1c9583448a9c/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180906133057-8cf3aee42992/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180921163948-d47a0f339242/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180927150500-dad3d9fb7b6e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181005133103-4497e2df6f9e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181011152604-fa43e7bc11ba/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181022134430-8a28ead16f52/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181024145615-5cd93ef61a7c/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181025063200-d989b31c8746/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181026064943-731415f00dce/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181106135930-3a76605856fd/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181206074257-70b957f3b65e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190102155601-82a175fd1598 h1:S8GOgffXV1X3fpVG442QRfWOt0iFl79eHJ7OPt725bo=
|
||||
golang.org/x/sys v0.0.0-20190102155601-82a175fd1598/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181003024731-2f84ea8ef872/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181006002542-f60d9635b16a/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181008205924-a2b3f7f249e9/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181013182035-5e66757b835f/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181017214349-06f26fdaaa28/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181024171208-a2dc47679d30/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181026183834-f60e5f99f081/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181105230042-78dc5bac0cac/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181107215632-34b416bd17b3/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181114190951-94339b83286c/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181119130350-139d099f6620/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181127195227-b4e97c0ed882/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181127232545-e782529d0ddd/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181203210056-e5f3ab76ea4b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181205224935-3576414c54a4/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181206194817-bcd4e47d0288/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181207183836-8bc39b988060/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181212172921-837e80568c09/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190102213336-ca9055ed7d04/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190104182027-498d95493402/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190111214448-fc1d57b08d7b h1:Z5QW7z0ycYrOVRYv3z4FeSZbRNvVwUfXHKQSZKb5A6w=
|
||||
golang.org/x/tools v0.0.0-20190111214448-fc1d57b08d7b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
gopkg.in/airbrake/gobrake.v2 v2.0.9/go.mod h1:/h5ZAUhDkGaJfjzjKLSjv6zCL6O0LLBxU4K+aSYdM/U=
|
||||
gopkg.in/alexcesaro/quotedprintable.v3 v3.0.0-20150716171945-2caba252f4dc/go.mod h1:m7x9LTH6d71AHyAX77c9yqWCCa3UKHcVEj9y7hAtKDk=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
|
||||
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
|
||||
gopkg.in/gemnasium/logrus-airbrake-hook.v2 v2.1.2/go.mod h1:Xk6kEKp8OKb+X14hQBKWaSkCsqBpgog8nAV2xsGOxlo=
|
||||
gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df/go.mod h1:LRQQ+SO6ZHR7tOkpBDuZnXENFzX8qRjMDMyPD6BRkCw=
|
||||
gopkg.in/mail.v2 v2.0.0-20180731213649-a0242b2233b4/go.mod h1:htwXN1Qh09vZJ1NVKxQqHPBaCBbzKhp5GzuJEA4VJWw=
|
||||
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw=
|
||||
gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
16
vendor/github.com/gobuffalo/envy/shoulders.md
generated
vendored
Normal file
16
vendor/github.com/gobuffalo/envy/shoulders.md
generated
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
# github.com/gobuffalo/envy Stands on the Shoulders of Giants
|
||||
|
||||
github.com/gobuffalo/envy does not try to reinvent the wheel! Instead, it uses the already great wheels developed by the Go community and puts them all together in the best way possible. Without these giants this project would not be possible. Please make sure to check them out and thank them for all of their hard work.
|
||||
|
||||
Thank you to the following **GIANTS**:
|
||||
|
||||
|
||||
* [github.com/gobuffalo/envy](https://godoc.org/github.com/gobuffalo/envy)
|
||||
|
||||
* [github.com/joho/godotenv](https://godoc.org/github.com/joho/godotenv)
|
||||
|
||||
* [github.com/rogpeppe/go-internal/modfile](https://godoc.org/github.com/rogpeppe/go-internal/modfile)
|
||||
|
||||
* [github.com/rogpeppe/go-internal/module](https://godoc.org/github.com/rogpeppe/go-internal/module)
|
||||
|
||||
* [github.com/rogpeppe/go-internal/semver](https://godoc.org/github.com/rogpeppe/go-internal/semver)
|
||||
3
vendor/github.com/gobuffalo/envy/version.go
generated
vendored
Normal file
3
vendor/github.com/gobuffalo/envy/version.go
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
package envy
|
||||
|
||||
const Version = "v1.6.12"
|
||||
29
vendor/github.com/gobuffalo/events/.gitignore
generated
vendored
Normal file
29
vendor/github.com/gobuffalo/events/.gitignore
generated
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
*.log
|
||||
.DS_Store
|
||||
doc
|
||||
tmp
|
||||
pkg
|
||||
*.gem
|
||||
*.pid
|
||||
coverage
|
||||
coverage.data
|
||||
build/*
|
||||
*.pbxuser
|
||||
*.mode1v3
|
||||
.svn
|
||||
profile
|
||||
.console_history
|
||||
.sass-cache/*
|
||||
.rake_tasks~
|
||||
*.log.lck
|
||||
solr/
|
||||
.jhw-cache/
|
||||
jhw.*
|
||||
*.sublime*
|
||||
node_modules/
|
||||
dist/
|
||||
generated/
|
||||
.vendor/
|
||||
bin/*
|
||||
gin-bin
|
||||
.idea/
|
||||
3
vendor/github.com/gobuffalo/events/.gometalinter.json
generated
vendored
Normal file
3
vendor/github.com/gobuffalo/events/.gometalinter.json
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"Enable": ["vet", "golint", "goimports", "deadcode", "gotype", "ineffassign", "misspell", "nakedret", "unconvert", "megacheck", "varcheck"]
|
||||
}
|
||||
36
vendor/github.com/gobuffalo/events/.travis.yml
generated
vendored
Normal file
36
vendor/github.com/gobuffalo/events/.travis.yml
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
language: go
|
||||
|
||||
sudo: false
|
||||
|
||||
matrix:
|
||||
include:
|
||||
- os: linux
|
||||
go: "1.9.x"
|
||||
- os: windows
|
||||
go: "1.9.x"
|
||||
- os: linux
|
||||
go: "1.10.x"
|
||||
- os: windows
|
||||
go: "1.10.x"
|
||||
- os: linux
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=off
|
||||
- os: windows
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=off
|
||||
- os: linux
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=on
|
||||
- os: windows
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=on
|
||||
|
||||
install: false
|
||||
|
||||
script:
|
||||
- go get -v -t ./...
|
||||
- go test -v -timeout=5s -race ./...
|
||||
21
vendor/github.com/gobuffalo/events/LICENSE
generated
vendored
Normal file
21
vendor/github.com/gobuffalo/events/LICENSE
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2018 Mark Bates
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
55
vendor/github.com/gobuffalo/events/Makefile
generated
vendored
Normal file
55
vendor/github.com/gobuffalo/events/Makefile
generated
vendored
Normal file
@@ -0,0 +1,55 @@
|
||||
TAGS ?= "sqlite"
|
||||
GO_BIN ?= go
|
||||
|
||||
install:
|
||||
packr
|
||||
$(GO_BIN) install -v .
|
||||
make tidy
|
||||
|
||||
tidy:
|
||||
ifeq ($(GO111MODULE),on)
|
||||
$(GO_BIN) mod tidy
|
||||
else
|
||||
echo skipping go mod tidy
|
||||
endif
|
||||
|
||||
|
||||
deps:
|
||||
$(GO_BIN) get github.com/gobuffalo/release
|
||||
$(GO_BIN) get github.com/gobuffalo/packr/packr
|
||||
$(GO_BIN) get -tags ${TAGS} -t ./...
|
||||
make tidy
|
||||
|
||||
build:
|
||||
packr
|
||||
$(GO_BIN) build -v .
|
||||
make tidy
|
||||
|
||||
test:
|
||||
packr
|
||||
$(GO_BIN) test -tags ${TAGS} ./...
|
||||
make tidy
|
||||
|
||||
ci-test:
|
||||
$(GO_BIN) test -tags ${TAGS} -race ./...
|
||||
make tidy
|
||||
|
||||
lint:
|
||||
gometalinter --vendor ./... --deadline=1m --skip=internal
|
||||
make tidy
|
||||
|
||||
update:
|
||||
$(GO_BIN) get -u -tags ${TAGS}
|
||||
make tidy
|
||||
packr
|
||||
make test
|
||||
make install
|
||||
make tidy
|
||||
|
||||
release-test:
|
||||
$(GO_BIN) test -tags ${TAGS} -race ./...
|
||||
make tidy
|
||||
|
||||
release:
|
||||
release -y -f version.go
|
||||
make tidy
|
||||
99
vendor/github.com/gobuffalo/events/README.md
generated
vendored
Normal file
99
vendor/github.com/gobuffalo/events/README.md
generated
vendored
Normal file
@@ -0,0 +1,99 @@
|
||||
<p align="center"><img src="https://github.com/gobuffalo/buffalo/blob/master/logo.svg" width="360"></p>
|
||||
|
||||
<p align="center">
|
||||
<a href="https://godoc.org/github.com/gobuffalo/events"><img src="https://godoc.org/github.com/gobuffalo/events?status.svg" alt="GoDoc" /></a>
|
||||
<a href="https://goreportcard.com/report/github.com/gobuffalo/events"><img src="https://goreportcard.com/badge/github.com/gobuffalo/events" alt="Go Report Card" /></a>
|
||||
</p>
|
||||
|
||||
# github.com/gobuffalo/events
|
||||
|
||||
**Note:** This package was first introduced to Buffalo in this [PR](https://github.com/gobuffalo/buffalo/pull/1305). Assuming the PR is merged Buffalo will not start emitting events until `v0.13.0-beta.2` or greater.
|
||||
|
||||
A list of known emitted events can be found at [https://godoc.org/github.com/gobuffalo/events#pkg-constants](https://godoc.org/github.com/gobuffalo/events#pkg-constants)
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
$ go get -u -v github.com/gobuffalo/events
|
||||
```
|
||||
|
||||
## Listening For Events
|
||||
|
||||
To listen for events you need to register an [`events#Listener`](https://godoc.org/github.com/gobuffalo/events#Listener) function first.
|
||||
|
||||
```go
|
||||
func init() {
|
||||
// if you want to give your listener a nice name to identify itself
|
||||
events.NamedListen("my-listener", func(e events.Event) {
|
||||
fmt.Println("### e ->", e)
|
||||
})
|
||||
|
||||
// if you don't care about identifying your listener
|
||||
events.Listen(func(e events.Event) {
|
||||
fmt.Println("### e ->", e)
|
||||
})
|
||||
}
|
||||
```
|
||||
|
||||
## Emitting Events
|
||||
|
||||
```go
|
||||
events.Emit(events.Event{
|
||||
Kind: "my-event",
|
||||
Message: // optional message,
|
||||
Payload: // optional payload,
|
||||
Error: // optional error,
|
||||
})
|
||||
```
|
||||
|
||||
There is only one required field when emitting an event, `Kind`.
|
||||
|
||||
The `Kind` field is key to how people will interpret your messages, and should be constructed as such: `<namespace>:<event-kind>:<err-optional>`.
|
||||
|
||||
In the examples below from [Buffalo](https://gobuffalo.io) you can see it is using the `buffalo:` name space for its events.
|
||||
|
||||
```go
|
||||
// EvtAppStart is emitted when buffalo.App#Serve is called
|
||||
EvtAppStart = "buffalo:app:start"
|
||||
// EvtAppStartErr is emitted when an error occurs calling buffalo.App#Serve
|
||||
EvtAppStartErr = "buffalo:app:start:err"
|
||||
// EvtAppStop is emitted when buffalo.App#Stop is called
|
||||
EvtAppStop = "buffalo:app:stop"
|
||||
// EvtAppStopErr is emitted when an error occurs calling buffalo.App#Stop
|
||||
EvtAppStopErr = "buffalo:app:stop:err"
|
||||
```
|
||||
|
||||
## Implementing a Manager
|
||||
|
||||
By default `events` implements a basic manager for you. Should you want to replace that with your own implementation, perhaps that's backed by a proper message queue, you can implement the [`events#Manager`](https://godoc.org/github.com/gobuffalo/events#Manager) interface.
|
||||
|
||||
```go
|
||||
var _ events.Manager = MyManager{}
|
||||
events.SetManager(MyManager{})
|
||||
```
|
||||
|
||||
## Listening via Buffalo Plugins
|
||||
|
||||
Once Buffalo is actively emitting events, plugins, will be able to listen those events via their CLIs.
|
||||
|
||||
To do so you can set the `BuffaloCommand` to `events` when telling Buffalo which plugin in commands are available. Buffalo will create a new listener that says the JSON version of the event to that command in question.
|
||||
|
||||
```go
|
||||
var availableCmd = &cobra.Command{
|
||||
Use: "available",
|
||||
Short: "a list of available buffalo plugins",
|
||||
RunE: func(cmd *cobra.Command, args []string) error {
|
||||
plugs := plugins.Commands{
|
||||
{Name: "echo", UseCommand: "echo", BuffaloCommand: "events", Description: echoCmd.Short, Aliases: echoCmd.Aliases},
|
||||
}
|
||||
return json.NewEncoder(os.Stdout).Encode(plugs)
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
events.Emit(events.Event{
|
||||
Kind: "my-event",
|
||||
})
|
||||
|
||||
// buffalo-foo echo "{\"kind\": \"my-event\"}"
|
||||
```
|
||||
56
vendor/github.com/gobuffalo/events/event.go
generated
vendored
Normal file
56
vendor/github.com/gobuffalo/events/event.go
generated
vendored
Normal file
@@ -0,0 +1,56 @@
|
||||
package events
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"strings"
|
||||
)
|
||||
|
||||
// Event represents different events
|
||||
// in the lifecycle of a Buffalo app
|
||||
type Event struct {
|
||||
// Kind is the "type" of event "app:start"
|
||||
Kind string `json:"kind"`
|
||||
// Message is optional
|
||||
Message string `json:"message"`
|
||||
// Payload is optional
|
||||
Payload Payload `json:"payload"`
|
||||
// Error is optional
|
||||
Error error `json:"-"`
|
||||
}
|
||||
|
||||
func (e Event) String() string {
|
||||
b, _ := e.MarshalJSON()
|
||||
|
||||
return string(b)
|
||||
}
|
||||
|
||||
// MarshalJSON implements the json marshaler for an event
|
||||
func (e Event) MarshalJSON() ([]byte, error) {
|
||||
m := map[string]interface{}{
|
||||
"kind": e.Kind,
|
||||
}
|
||||
if len(e.Message) != 0 {
|
||||
m["message"] = e.Message
|
||||
}
|
||||
if e.Error != nil {
|
||||
m["error"] = e.Error.Error()
|
||||
}
|
||||
if len(e.Payload) != 0 {
|
||||
m["payload"] = e.Payload
|
||||
}
|
||||
|
||||
return json.Marshal(m)
|
||||
}
|
||||
|
||||
// Validate that an event is ready to be emitted
|
||||
func (e Event) Validate() error {
|
||||
if len(e.Kind) == 0 {
|
||||
return errors.New("kind can not be blank")
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (e Event) IsError() bool {
|
||||
return strings.HasSuffix(e.Kind, ":err")
|
||||
}
|
||||
44
vendor/github.com/gobuffalo/events/events.go
generated
vendored
Normal file
44
vendor/github.com/gobuffalo/events/events.go
generated
vendored
Normal file
@@ -0,0 +1,44 @@
|
||||
package events
|
||||
|
||||
import (
|
||||
"strings"
|
||||
|
||||
"github.com/gobuffalo/mapi"
|
||||
)
|
||||
|
||||
type Payload = mapi.Mapi
|
||||
|
||||
const (
|
||||
// ErrGeneral is emitted for general errors
|
||||
ErrGeneral = "general:err"
|
||||
// ErrPanic is emitted when a panic is recovered
|
||||
ErrPanic = "panic:err"
|
||||
)
|
||||
|
||||
// Emit an event to all listeners
|
||||
func Emit(e Event) error {
|
||||
return boss.Emit(e)
|
||||
}
|
||||
|
||||
func EmitPayload(kind string, payload interface{}) error {
|
||||
return EmitError(kind, nil, payload)
|
||||
}
|
||||
|
||||
func EmitError(kind string, err error, payload interface{}) error {
|
||||
if err != nil && !strings.HasSuffix(kind, ":err") {
|
||||
kind += ":err"
|
||||
}
|
||||
var pl Payload
|
||||
pl, ok := payload.(Payload)
|
||||
if !ok {
|
||||
pl = Payload{
|
||||
"data": payload,
|
||||
}
|
||||
}
|
||||
e := Event{
|
||||
Kind: kind,
|
||||
Payload: pl,
|
||||
Error: err,
|
||||
}
|
||||
return Emit(e)
|
||||
}
|
||||
21
vendor/github.com/gobuffalo/events/filter.go
generated
vendored
Normal file
21
vendor/github.com/gobuffalo/events/filter.go
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
package events
|
||||
|
||||
import (
|
||||
"regexp"
|
||||
|
||||
"github.com/markbates/safe"
|
||||
)
|
||||
|
||||
// Filter compiles the string as a regex and returns
|
||||
// the original listener wrapped in a new listener
|
||||
// that filters incoming events by the Kind
|
||||
func Filter(s string, fn Listener) Listener {
|
||||
rx := regexp.MustCompile(s)
|
||||
return func(e Event) {
|
||||
if rx.MatchString(e.Kind) {
|
||||
safe.Run(func() {
|
||||
fn(e)
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
14
vendor/github.com/gobuffalo/events/go.mod
generated
vendored
Normal file
14
vendor/github.com/gobuffalo/events/go.mod
generated
vendored
Normal file
@@ -0,0 +1,14 @@
|
||||
module github.com/gobuffalo/events
|
||||
|
||||
require (
|
||||
github.com/gobuffalo/buffalo-plugins v1.10.0
|
||||
github.com/gobuffalo/envy v1.6.11
|
||||
github.com/gobuffalo/mapi v1.0.1
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.13
|
||||
github.com/markbates/oncer v0.0.0-20181203154359-bf2de49a0be2
|
||||
github.com/markbates/safe v1.0.1
|
||||
github.com/pkg/errors v0.8.1
|
||||
github.com/stretchr/testify v1.3.0
|
||||
golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4 // indirect
|
||||
golang.org/x/sys v0.0.0-20190102155601-82a175fd1598 // indirect
|
||||
)
|
||||
373
vendor/github.com/gobuffalo/events/go.sum
generated
vendored
Normal file
373
vendor/github.com/gobuffalo/events/go.sum
generated
vendored
Normal file
@@ -0,0 +1,373 @@
|
||||
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
|
||||
github.com/Masterminds/semver v1.4.2/go.mod h1:MB6lktGJrhw8PrUyiEoblNEGEQ+RzHPF078ddwwvV3Y=
|
||||
github.com/ajg/form v0.0.0-20160822230020-523a5da1a92f/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY=
|
||||
github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
|
||||
github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ=
|
||||
github.com/cockroachdb/cockroach-go v0.0.0-20181001143604-e0a95dfd547c/go.mod h1:XGLbWH/ujMcbPbhZq52Nv6UrCghb1yGn//133kEsvDk=
|
||||
github.com/codegangsta/negroni v1.0.0/go.mod h1:v0y3T5G7Y1UlFfyxFn/QLRU4a2EuNau2iZY63YTKWo0=
|
||||
github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
|
||||
github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk=
|
||||
github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
|
||||
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
|
||||
github.com/dustin/go-humanize v0.0.0-20180713052910-9f541cc9db5d/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
|
||||
github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
|
||||
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
|
||||
github.com/fatih/structs v1.0.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M=
|
||||
github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M=
|
||||
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
|
||||
github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w=
|
||||
github.com/gobuffalo/buffalo v0.12.8-0.20181004233540-fac9bb505aa8/go.mod h1:sLyT7/dceRXJUxSsE813JTQtA3Eb1vjxWfo/N//vXIY=
|
||||
github.com/gobuffalo/buffalo v0.13.0/go.mod h1:Mjn1Ba9wpIbpbrD+lIDMy99pQ0H0LiddMIIDGse7qT4=
|
||||
github.com/gobuffalo/buffalo-plugins v1.0.2/go.mod h1:pOp/uF7X3IShFHyobahTkTLZaeUXwb0GrUTb9ngJWTs=
|
||||
github.com/gobuffalo/buffalo-plugins v1.0.4/go.mod h1:pWS1vjtQ6uD17MVFWf7i3zfThrEKWlI5+PYLw/NaDB4=
|
||||
github.com/gobuffalo/buffalo-plugins v1.4.3/go.mod h1:uCzTY0woez4nDMdQjkcOYKanngeUVRO2HZi7ezmAjWY=
|
||||
github.com/gobuffalo/buffalo-plugins v1.5.1/go.mod h1:jbmwSZK5+PiAP9cC09VQOrGMZFCa/P0UMlIS3O12r5w=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.4/go.mod h1:/+N1aophkA2jZ1ifB2O3Y9yGwu6gKOVMtUmJnbg+OZI=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.5/go.mod h1:0HVkbgrVs/MnPZ/FOseDMVanCTm2RNcdM0PuXcL1NNI=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.7/go.mod h1:ZGZRkzz2PiKWHs0z7QsPBOTo2EpcGRArMEym6ghKYgk=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.9/go.mod h1:yYlYTrPdMCz+6/+UaXg5Jm4gN3xhsvsQ2ygVatZV5vw=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.11/go.mod h1:eAA6xJIL8OuynJZ8amXjRmHND6YiusVAaJdHDN1Lu8Q=
|
||||
github.com/gobuffalo/buffalo-plugins v1.8.2/go.mod h1:9te6/VjEQ7pKp7lXlDIMqzxgGpjlKoAcAANdCgoR960=
|
||||
github.com/gobuffalo/buffalo-plugins v1.8.3/go.mod h1:IAWq6vjZJVXebIq2qGTLOdlXzmpyTZ5iJG5b59fza5U=
|
||||
github.com/gobuffalo/buffalo-plugins v1.9.4/go.mod h1:grCV6DGsQlVzQwk6XdgcL3ZPgLm9BVxlBmXPMF8oBHI=
|
||||
github.com/gobuffalo/buffalo-plugins v1.10.0 h1:oF+BJ20zenp31xJnjkFcXAMUqlrMMTicsD/UwQWCW/s=
|
||||
github.com/gobuffalo/buffalo-plugins v1.10.0/go.mod h1:4osg8d9s60txLuGwXnqH+RCjPHj9K466cDFRl3PErHI=
|
||||
github.com/gobuffalo/buffalo-pop v1.0.5/go.mod h1:Fw/LfFDnSmB/vvQXPvcXEjzP98Tc+AudyNWUBWKCwQ8=
|
||||
github.com/gobuffalo/envy v1.6.4/go.mod h1:Abh+Jfw475/NWtYMEt+hnJWRiC8INKWibIMyNt1w2Mc=
|
||||
github.com/gobuffalo/envy v1.6.5/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.6/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.7/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.8/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.9/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.10/go.mod h1:X0CFllQjTV5ogsnUrg+Oks2yTI+PU2dGYBJOEI2D1Uo=
|
||||
github.com/gobuffalo/envy v1.6.11/go.mod h1:Fiq52W7nrHGDggFPhn2ZCcHw4u/rqXkqo+i7FB6EAcg=
|
||||
github.com/gobuffalo/events v1.0.3/go.mod h1:Txo8WmqScapa7zimEQIwgiJBvMECMe9gJjsKNPN3uZw=
|
||||
github.com/gobuffalo/events v1.0.7/go.mod h1:z8txf6H9jWhQ5Scr7YPLWg/cgXBRj8Q4uYI+rsVCCSQ=
|
||||
github.com/gobuffalo/events v1.0.8/go.mod h1:A5KyqT1sA+3GJiBE4QKZibse9mtOcI9nw8gGrDdqYGs=
|
||||
github.com/gobuffalo/events v1.1.3/go.mod h1:9yPGWYv11GENtzrIRApwQRMYSbUgCsZ1w6R503fCfrk=
|
||||
github.com/gobuffalo/events v1.1.4/go.mod h1:09/YRRgZHEOts5Isov+g9X2xajxdvOAcUuAHIX/O//A=
|
||||
github.com/gobuffalo/events v1.1.5/go.mod h1:3YUSzgHfYctSjEjLCWbkXP6djH2M+MLaVRzb4ymbAK0=
|
||||
github.com/gobuffalo/events v1.1.7/go.mod h1:6fGqxH2ing5XMb3EYRq9LEkVlyPGs4oO/eLzh+S8CxY=
|
||||
github.com/gobuffalo/events v1.1.8/go.mod h1:UFy+W6X6VbCWS8k2iT81HYX65dMtiuVycMy04cplt/8=
|
||||
github.com/gobuffalo/fizz v1.0.12/go.mod h1:C0sltPxpYK8Ftvf64kbsQa2yiCZY4RZviurNxXdAKwc=
|
||||
github.com/gobuffalo/flect v0.0.0-20180907193754-dc14d8acaf9f/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181002182613-4571df4b1daf/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181007231023-ae7ed6bfe683/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181018182602-fd24a256709f/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181019110701-3d6f0b585514/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181024204909-8f6be1a8c6c2/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181104133451-1f6e9779237a/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181114183036-47375f6d8328/go.mod h1:0HvNbHdfh+WOvDSIASqJOSxTOWSxCCUF++k/Y53v9rI=
|
||||
github.com/gobuffalo/flect v0.0.0-20181210151238-24a2b68e0316/go.mod h1:en58vff74S9b99Eg42Dr+/9yPu437QjlNsO/hBYPuOk=
|
||||
github.com/gobuffalo/flect v0.0.0-20190104192022-4af577e09bf2 h1:51NF9n6h4nGMooU5ALB+uJCM0UOmcWjAegIZb/ePtoE=
|
||||
github.com/gobuffalo/flect v0.0.0-20190104192022-4af577e09bf2/go.mod h1:en58vff74S9b99Eg42Dr+/9yPu437QjlNsO/hBYPuOk=
|
||||
github.com/gobuffalo/genny v0.0.0-20180924032338-7af3a40f2252/go.mod h1:tUTQOogrr7tAQnhajMSH6rv1BVev34H2sa1xNHMy94g=
|
||||
github.com/gobuffalo/genny v0.0.0-20181003150629-3786a0744c5d/go.mod h1:WAd8HmjMVrnkAZbmfgH5dLBUchsZfqzp/WS5sQz+uTM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181005145118-318a41a134cc/go.mod h1:WAd8HmjMVrnkAZbmfgH5dLBUchsZfqzp/WS5sQz+uTM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181007153042-b8de7d566757/go.mod h1:+oG5Ljrw04czAHbPXREwaFojJbpUvcIy4DiOnbEJFTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181012161047-33e5f43d83a6/go.mod h1:+oG5Ljrw04czAHbPXREwaFojJbpUvcIy4DiOnbEJFTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181017160347-90a774534246/go.mod h1:+oG5Ljrw04czAHbPXREwaFojJbpUvcIy4DiOnbEJFTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181024195656-51392254bf53/go.mod h1:o9GEH5gn5sCKLVB5rHFC4tq40rQ3VRUzmx6WwmaqISE=
|
||||
github.com/gobuffalo/genny v0.0.0-20181025145300-af3f81d526b8/go.mod h1:uZ1fFYvdcP8mu0B/Ynarf6dsGvp7QFIpk/QACUuFUVI=
|
||||
github.com/gobuffalo/genny v0.0.0-20181027191429-94d6cfb5c7fc/go.mod h1:x7SkrQQBx204Y+O9EwRXeszLJDTaWN0GnEasxgLrQTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181027195209-3887b7171c4f/go.mod h1:JbKx8HSWICu5zyqWOa0dVV1pbbXOHusrSzQUprW6g+w=
|
||||
github.com/gobuffalo/genny v0.0.0-20181106193839-7dcb0924caf1/go.mod h1:x61yHxvbDCgQ/7cOAbJCacZQuHgB0KMSzoYcw5debjU=
|
||||
github.com/gobuffalo/genny v0.0.0-20181107223128-f18346459dbe/go.mod h1:utQD3aKKEsdb03oR+Vi/6ztQb1j7pO10N3OBoowRcSU=
|
||||
github.com/gobuffalo/genny v0.0.0-20181114215459-0a4decd77f5d/go.mod h1:kN2KZ8VgXF9VIIOj/GM0Eo7YK+un4Q3tTreKOf0q1ng=
|
||||
github.com/gobuffalo/genny v0.0.0-20181119162812-e8ff4adce8bb/go.mod h1:BA9htSe4bZwBDJLe8CUkoqkypq3hn3+CkoHqVOW718E=
|
||||
github.com/gobuffalo/genny v0.0.0-20181127225641-2d959acc795b/go.mod h1:l54xLXNkteX/PdZ+HlgPk1qtcrgeOr3XUBBPDbH+7CQ=
|
||||
github.com/gobuffalo/genny v0.0.0-20181128191930-77e34f71ba2a/go.mod h1:FW/D9p7cEEOqxYA71/hnrkOWm62JZ5ZNxcNIVJEaWBU=
|
||||
github.com/gobuffalo/genny v0.0.0-20181203165245-fda8bcce96b1/go.mod h1:wpNSANu9UErftfiaAlz1pDZclrYzLtO5lALifODyjuM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181203201232-849d2c9534ea/go.mod h1:wpNSANu9UErftfiaAlz1pDZclrYzLtO5lALifODyjuM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181206121324-d6fb8a0dbe36/go.mod h1:wpNSANu9UErftfiaAlz1pDZclrYzLtO5lALifODyjuM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181207164119-84844398a37d/go.mod h1:y0ysCHGGQf2T3vOhCrGHheYN54Y/REj0ayd0Suf4C/8=
|
||||
github.com/gobuffalo/genny v0.0.0-20181211165820-e26c8466f14d/go.mod h1:sHnK+ZSU4e2feXP3PA29ouij6PUEiN+RCwECjCTB3yM=
|
||||
github.com/gobuffalo/genny v0.0.0-20190104222617-a71664fc38e7 h1:RPiJ0Orw/4i4JWGuvcZFYiW16+Ql1C9TyrYRznbkKjg=
|
||||
github.com/gobuffalo/genny v0.0.0-20190104222617-a71664fc38e7/go.mod h1:QPsQ1FnhEsiU8f+O0qKWXz2RE4TiDqLVChWkBuh1WaY=
|
||||
github.com/gobuffalo/github_flavored_markdown v1.0.4/go.mod h1:uRowCdK+q8d/RF0Kt3/DSalaIXbb0De/dmTqMQdkQ4I=
|
||||
github.com/gobuffalo/github_flavored_markdown v1.0.5/go.mod h1:U0643QShPF+OF2tJvYNiYDLDGDuQmJZXsf/bHOJPsMY=
|
||||
github.com/gobuffalo/github_flavored_markdown v1.0.7/go.mod h1:w93Pd9Lz6LvyQXEG6DktTPHkOtCbr+arAD5mkwMzXLI=
|
||||
github.com/gobuffalo/httptest v1.0.2/go.mod h1:7T1IbSrg60ankme0aDLVnEY0h056g9M1/ZvpVThtB7E=
|
||||
github.com/gobuffalo/licenser v0.0.0-20180924033006-eae28e638a42/go.mod h1:Ubo90Np8gpsSZqNScZZkVXXAo5DGhTb+WYFIjlnog8w=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181025145548-437d89de4f75/go.mod h1:x3lEpYxkRG/XtGCUNkio+6RZ/dlOvLzTI9M1auIwFcw=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181027200154-58051a75da95/go.mod h1:BzhaaxGd1tq1+OLKObzgdCV9kqVhbTulxOpYbvMQWS0=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181109171355-91a2a7aac9a7/go.mod h1:m+Ygox92pi9bdg+gVaycvqE8RVSjZp7mWw75+K5NPHk=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181128165715-cc7305f8abed/go.mod h1:oU9F9UCE+AzI/MueCKZamsezGOOHfSirltllOVeRTAE=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181203160806-fe900bbede07/go.mod h1:ph6VDNvOzt1CdfaWC+9XwcBnlSTBz2j49PBwum6RFaU=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181211173111-f8a311c51159/go.mod h1:ve/Ue99DRuvnTaLq2zKa6F4KtHiYf7W046tDjuGYPfM=
|
||||
github.com/gobuffalo/logger v0.0.0-20181022175615-46cfb361fc27/go.mod h1:8sQkgyhWipz1mIctHF4jTxmJh1Vxhp7mP8IqbljgJZo=
|
||||
github.com/gobuffalo/logger v0.0.0-20181027144941-73d08d2bb969/go.mod h1:7uGg2duHKpWnN4+YmyKBdLXfhopkAdVM6H3nKbyFbz8=
|
||||
github.com/gobuffalo/logger v0.0.0-20181027193913-9cf4dd0efe46/go.mod h1:7uGg2duHKpWnN4+YmyKBdLXfhopkAdVM6H3nKbyFbz8=
|
||||
github.com/gobuffalo/logger v0.0.0-20181109185836-3feeab578c17/go.mod h1:oNErH0xLe+utO+OW8ptXMSA5DkiSEDW1u3zGIt8F9Ew=
|
||||
github.com/gobuffalo/logger v0.0.0-20181117211126-8e9b89b7c264/go.mod h1:5etB91IE0uBlw9k756fVKZJdS+7M7ejVhmpXXiSFj0I=
|
||||
github.com/gobuffalo/logger v0.0.0-20181127160119-5b956e21995c/go.mod h1:+HxKANrR9VGw9yN3aOAppJKvhO05ctDi63w4mDnKv2U=
|
||||
github.com/gobuffalo/makr v1.1.5/go.mod h1:Y+o0btAH1kYAMDJW/TX3+oAXEu0bmSLLoC9mIFxtzOw=
|
||||
github.com/gobuffalo/mapi v1.0.0/go.mod h1:4VAGh89y6rVOvm5A8fKFxYG+wIW6LO1FMTG9hnKStFc=
|
||||
github.com/gobuffalo/mapi v1.0.1/go.mod h1:4VAGh89y6rVOvm5A8fKFxYG+wIW6LO1FMTG9hnKStFc=
|
||||
github.com/gobuffalo/meta v0.0.0-20181018155829-df62557efcd3/go.mod h1:XTTOhwMNryif3x9LkTTBO/Llrveezd71u3quLd0u7CM=
|
||||
github.com/gobuffalo/meta v0.0.0-20181018192820-8c6cef77dab3/go.mod h1:E94EPzx9NERGCY69UWlcj6Hipf2uK/vnfrF4QD0plVE=
|
||||
github.com/gobuffalo/meta v0.0.0-20181025145500-3a985a084b0a/go.mod h1:YDAKBud2FP7NZdruCSlmTmDOZbVSa6bpK7LJ/A/nlKg=
|
||||
github.com/gobuffalo/meta v0.0.0-20181114191255-b130ebedd2f7/go.mod h1:K6cRZ29ozr4Btvsqkjvg5nDFTLOgTqf03KA70Ks0ypE=
|
||||
github.com/gobuffalo/meta v0.0.0-20181127070345-0d7e59dd540b/go.mod h1:RLO7tMvE0IAKAM8wny1aN12pvEKn7EtkBLkUZR00Qf8=
|
||||
github.com/gobuffalo/mw-basicauth v1.0.3/go.mod h1:dg7+ilMZOKnQFHDefUzUHufNyTswVUviCBgF244C1+0=
|
||||
github.com/gobuffalo/mw-contenttype v0.0.0-20180802152300-74f5a47f4d56/go.mod h1:7EvcmzBbeCvFtQm5GqF9ys6QnCxz2UM1x0moiWLq1No=
|
||||
github.com/gobuffalo/mw-csrf v0.0.0-20180802151833-446ff26e108b/go.mod h1:sbGtb8DmDZuDUQoxjr8hG1ZbLtZboD9xsn6p77ppcHo=
|
||||
github.com/gobuffalo/mw-forcessl v0.0.0-20180802152810-73921ae7a130/go.mod h1:JvNHRj7bYNAMUr/5XMkZaDcw3jZhUZpsmzhd//FFWmQ=
|
||||
github.com/gobuffalo/mw-i18n v0.0.0-20180802152014-e3060b7e13d6/go.mod h1:91AQfukc52A6hdfIfkxzyr+kpVYDodgAeT5cjX1UIj4=
|
||||
github.com/gobuffalo/mw-paramlogger v0.0.0-20181005191442-d6ee392ec72e/go.mod h1:6OJr6VwSzgJMqWMj7TYmRUqzNe2LXu/W1rRW4MAz/ME=
|
||||
github.com/gobuffalo/mw-tokenauth v0.0.0-20181001105134-8545f626c189/go.mod h1:UqBF00IfKvd39ni5+yI5MLMjAf4gX7cDKN/26zDOD6c=
|
||||
github.com/gobuffalo/packd v0.0.0-20181027182251-01ad393492c8/go.mod h1:SmdBdhj6uhOsg1Ui4SFAyrhuc7U4VCildosO5IDJ3lc=
|
||||
github.com/gobuffalo/packd v0.0.0-20181027190505-aafc0d02c411/go.mod h1:SmdBdhj6uhOsg1Ui4SFAyrhuc7U4VCildosO5IDJ3lc=
|
||||
github.com/gobuffalo/packd v0.0.0-20181027194105-7ae579e6d213/go.mod h1:SmdBdhj6uhOsg1Ui4SFAyrhuc7U4VCildosO5IDJ3lc=
|
||||
github.com/gobuffalo/packd v0.0.0-20181031195726-c82734870264/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181104210303-d376b15f8e96/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181111195323-b2e760a5f0ff/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181114190715-f25c5d2471d7/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181124090624-311c6248e5fb/go.mod h1:Foenia9ZvITEvG05ab6XpiD5EfBHPL8A6hush8SJ0o8=
|
||||
github.com/gobuffalo/packd v0.0.0-20181207120301-c49825f8f6f4/go.mod h1:LYc0TGKFBBFTRC9dg2pcRcMqGCTMD7T2BIMP7OBuQAA=
|
||||
github.com/gobuffalo/packd v0.0.0-20181212173646-eca3b8fd6687/go.mod h1:LYc0TGKFBBFTRC9dg2pcRcMqGCTMD7T2BIMP7OBuQAA=
|
||||
github.com/gobuffalo/packr v1.13.7/go.mod h1:KkinLIn/n6+3tVXMwg6KkNvWwVsrRAz4ph+jgpk3Z24=
|
||||
github.com/gobuffalo/packr v1.15.0/go.mod h1:t5gXzEhIviQwVlNx/+3SfS07GS+cZ2hn76WLzPp6MGI=
|
||||
github.com/gobuffalo/packr v1.15.1/go.mod h1:IeqicJ7jm8182yrVmNbM6PR4g79SjN9tZLH8KduZZwE=
|
||||
github.com/gobuffalo/packr v1.19.0/go.mod h1:MstrNkfCQhd5o+Ct4IJ0skWlxN8emOq8DsoT1G98VIU=
|
||||
github.com/gobuffalo/packr v1.20.0/go.mod h1:JDytk1t2gP+my1ig7iI4NcVaXr886+N0ecUga6884zw=
|
||||
github.com/gobuffalo/packr v1.21.0/go.mod h1:H00jGfj1qFKxscFJSw8wcL4hpQtPe1PfU2wa6sg/SR0=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.8/go.mod h1:y60QCdzwuMwO2R49fdQhsjCPv7tLQFR0ayzxxla9zes=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.9/go.mod h1:fQqADRfZpEsgkc7c/K7aMew3n4aF1Kji7+lIZeR98Fc=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.10/go.mod h1:4CWWn4I5T3v4c1OsJ55HbHlUEKNWMITG5iIkdr4Px4w=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.11/go.mod h1:JoieH/3h3U4UmatmV93QmqyPUdf4wVM9HELaHEu+3fk=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.12/go.mod h1:FV1zZTsVFi1DSCboO36Xgs4pzCZBjB/tDV9Cz/lSaR8=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.13/go.mod h1:2Mp7GhBFMdJlOK8vGfl7SYtfMP3+5roE39ejlfjw0rA=
|
||||
github.com/gobuffalo/plush v3.7.16+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.20+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.21+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.22+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.23+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.30+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.31+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.32+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20181128164830-d29dcb966cb2/go.mod h1:r9QwptTFnuvSaSRjpSp4S2/4e2D3tJhARYbvEBcKSb4=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20181203163832-9fc4964505c2/go.mod h1:opEdT33AA2HdrIwK1aibqnTJDVVKXC02Bar/GT1YRVs=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20181207152837-eedb135bd51b/go.mod h1:Lcw7HQbEVm09sAQrCLzIxuhFbB3nAgp4c55E+UlynR0=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20190104222512-177cd2b872b3/go.mod h1:tYxCozi8X62bpZyKXYHw1ncx2ZtT2nFvG42kuLwYjoc=
|
||||
github.com/gobuffalo/pop v4.8.2+incompatible/go.mod h1:DwBz3SD5SsHpTZiTubcsFWcVDpJWGsxjVjMPnkiThWg=
|
||||
github.com/gobuffalo/pop v4.8.3+incompatible/go.mod h1:DwBz3SD5SsHpTZiTubcsFWcVDpJWGsxjVjMPnkiThWg=
|
||||
github.com/gobuffalo/pop v4.8.4+incompatible/go.mod h1:DwBz3SD5SsHpTZiTubcsFWcVDpJWGsxjVjMPnkiThWg=
|
||||
github.com/gobuffalo/release v1.0.35/go.mod h1:VtHFAKs61vO3wboCec5xr9JPTjYyWYcvaM3lclkc4x4=
|
||||
github.com/gobuffalo/release v1.0.38/go.mod h1:VtHFAKs61vO3wboCec5xr9JPTjYyWYcvaM3lclkc4x4=
|
||||
github.com/gobuffalo/release v1.0.42/go.mod h1:RPs7EtafH4oylgetOJpGP0yCZZUiO4vqHfTHJjSdpug=
|
||||
github.com/gobuffalo/release v1.0.52/go.mod h1:RPs7EtafH4oylgetOJpGP0yCZZUiO4vqHfTHJjSdpug=
|
||||
github.com/gobuffalo/release v1.0.53/go.mod h1:FdF257nd8rqhNaqtDWFGhxdJ/Ig4J7VcS3KL7n/a+aA=
|
||||
github.com/gobuffalo/release v1.0.54/go.mod h1:Pe5/RxRa/BE8whDpGfRqSI7D1a0evGK1T4JDm339tJc=
|
||||
github.com/gobuffalo/release v1.0.61/go.mod h1:mfIO38ujUNVDlBziIYqXquYfBF+8FDHUjKZgYC1Hj24=
|
||||
github.com/gobuffalo/release v1.0.72/go.mod h1:NP5NXgg/IX3M5XmHmWR99D687/3Dt9qZtTK/Lbwc1hU=
|
||||
github.com/gobuffalo/release v1.1.1/go.mod h1:Sluak1Xd6kcp6snkluR1jeXAogdJZpFFRzTYRs/2uwg=
|
||||
github.com/gobuffalo/release v1.1.3/go.mod h1:CuXc5/m+4zuq8idoDt1l4va0AXAn/OSs08uHOfMVr8E=
|
||||
github.com/gobuffalo/release v1.1.6/go.mod h1:18naWa3kBsqO0cItXZNJuefCKOENpbbUIqRL1g+p6z0=
|
||||
github.com/gobuffalo/shoulders v1.0.1/go.mod h1:V33CcVmaQ4gRUmHKwq1fiTXuf8Gp/qjQBUL5tHPmvbA=
|
||||
github.com/gobuffalo/syncx v0.0.0-20181120191700-98333ab04150/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw=
|
||||
github.com/gobuffalo/syncx v0.0.0-20181120194010-558ac7de985f/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw=
|
||||
github.com/gobuffalo/tags v2.0.11+incompatible/go.mod h1:9XmhOkyaB7UzvuY4UoZO4s67q8/xRMVJEaakauVQYeY=
|
||||
github.com/gobuffalo/tags v2.0.14+incompatible/go.mod h1:9XmhOkyaB7UzvuY4UoZO4s67q8/xRMVJEaakauVQYeY=
|
||||
github.com/gobuffalo/tags v2.0.15+incompatible/go.mod h1:9XmhOkyaB7UzvuY4UoZO4s67q8/xRMVJEaakauVQYeY=
|
||||
github.com/gobuffalo/uuid v2.0.3+incompatible/go.mod h1:ErhIzkRhm0FtRuiE/PeORqcw4cVi1RtSpnwYrxuvkfE=
|
||||
github.com/gobuffalo/uuid v2.0.4+incompatible/go.mod h1:ErhIzkRhm0FtRuiE/PeORqcw4cVi1RtSpnwYrxuvkfE=
|
||||
github.com/gobuffalo/uuid v2.0.5+incompatible/go.mod h1:ErhIzkRhm0FtRuiE/PeORqcw4cVi1RtSpnwYrxuvkfE=
|
||||
github.com/gobuffalo/validate v2.0.3+incompatible/go.mod h1:N+EtDe0J8252BgfzQUChBgfd6L93m9weay53EWFVsMM=
|
||||
github.com/gobuffalo/x v0.0.0-20181003152136-452098b06085/go.mod h1:WevpGD+5YOreDJznWevcn8NTmQEW5STSBgIkpkjzqXc=
|
||||
github.com/gobuffalo/x v0.0.0-20181007152206-913e47c59ca7/go.mod h1:9rDPXaB3kXdKWzMc4odGQQdG2e2DIEmANy5aSJ9yesY=
|
||||
github.com/gofrs/uuid v3.1.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM=
|
||||
github.com/golang/protobuf v1.1.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg=
|
||||
github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
|
||||
github.com/gorilla/pat v0.0.0-20180118222023-199c85a7f6d1/go.mod h1:YeAe0gNeiNT5hoiZRI4yiOky6jVdNvfO2N6Kav/HmxY=
|
||||
github.com/gorilla/securecookie v1.1.1/go.mod h1:ra0sb63/xPlUeL+yeDciTfxMRAA+MP+HVt/4epWDjd4=
|
||||
github.com/gorilla/sessions v1.1.2/go.mod h1:8KCfur6+4Mqcc6S0FEfKuN15Vl5MgXW92AE8ovaJD0w=
|
||||
github.com/gorilla/sessions v1.1.3/go.mod h1:8KCfur6+4Mqcc6S0FEfKuN15Vl5MgXW92AE8ovaJD0w=
|
||||
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
|
||||
github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU=
|
||||
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
|
||||
github.com/jackc/fake v0.0.0-20150926172116-812a484cc733/go.mod h1:WrMFNQdiFJ80sQsxDoMokWK1W5TQtxBFNpzWTD84ibQ=
|
||||
github.com/jackc/pgx v3.2.0+incompatible/go.mod h1:0ZGrqGqkRlliWnWB4zKnWtjbSWbGkVEFm4TeybAXq+I=
|
||||
github.com/jmoiron/sqlx v0.0.0-20180614180643-0dae4fefe7c0/go.mod h1:IiEW3SEiiErVyFdH8NTuWjSifiEQKUoyK3LNqr2kCHU=
|
||||
github.com/joho/godotenv v1.2.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg=
|
||||
github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg=
|
||||
github.com/karrick/godirwalk v1.7.5/go.mod h1:2c9FRhkDxdIbgkOnCEvnSWs71Bhugbl46shStcFDJ34=
|
||||
github.com/karrick/godirwalk v1.7.7/go.mod h1:2c9FRhkDxdIbgkOnCEvnSWs71Bhugbl46shStcFDJ34=
|
||||
github.com/karrick/godirwalk v1.7.8 h1:VfG72pyIxgtC7+3X9CMHI0AOl4LwyRAg98WAgsvffi8=
|
||||
github.com/karrick/godirwalk v1.7.8/go.mod h1:2c9FRhkDxdIbgkOnCEvnSWs71Bhugbl46shStcFDJ34=
|
||||
github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51/go.mod h1:CzGEWj7cYgsdH8dAjBGEr58BoE7ScuLd+fwFZ44+/x8=
|
||||
github.com/konsorten/go-windows-terminal-sequences v0.0.0-20180402223658-b729f2633dfe/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
|
||||
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
|
||||
github.com/kr/pty v1.1.3/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
|
||||
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
|
||||
github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
|
||||
github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
|
||||
github.com/markbates/deplist v1.0.4/go.mod h1:gRRbPbbuA8TmMiRvaOzUlRfzfjeCCBqX2A6arxN01MM=
|
||||
github.com/markbates/deplist v1.0.5/go.mod h1:gRRbPbbuA8TmMiRvaOzUlRfzfjeCCBqX2A6arxN01MM=
|
||||
github.com/markbates/going v1.0.2/go.mod h1:UWCk3zm0UKefHZ7l8BNqi26UyiEMniznk8naLdTcy6c=
|
||||
github.com/markbates/grift v1.0.4/go.mod h1:wbmtW74veyx+cgfwFhlnnMWqhoz55rnHR47oMXzsyVs=
|
||||
github.com/markbates/hmax v1.0.0/go.mod h1:cOkR9dktiESxIMu+65oc/r/bdY4bE8zZw3OLhLx0X2c=
|
||||
github.com/markbates/inflect v1.0.0/go.mod h1:oTeZL2KHA7CUX6X+fovmK9OvIOFuqu0TwdQrZjLTh88=
|
||||
github.com/markbates/inflect v1.0.1/go.mod h1:uv3UVNBe5qBIfCm8O8Q+DW+S1EopeyINj+Ikhc7rnCk=
|
||||
github.com/markbates/inflect v1.0.3/go.mod h1:1fR9+pO2KHEO9ZRtto13gDwwZaAKstQzferVeWqbgNs=
|
||||
github.com/markbates/inflect v1.0.4/go.mod h1:1fR9+pO2KHEO9ZRtto13gDwwZaAKstQzferVeWqbgNs=
|
||||
github.com/markbates/oncer v0.0.0-20180924031910-e862a676800b/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/oncer v0.0.0-20180924034138-723ad0170a46/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/oncer v0.0.0-20181014194634-05fccaae8fc4/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/oncer v0.0.0-20181203154359-bf2de49a0be2/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/refresh v1.4.10/go.mod h1:NDPHvotuZmTmesXxr95C9bjlw1/0frJwtME2dzcVKhc=
|
||||
github.com/markbates/safe v1.0.0/go.mod h1:nAqgmRi7cY2nqMc92/bSEeQA+R4OheNU2T1kNSCBdG0=
|
||||
github.com/markbates/safe v1.0.1/go.mod h1:nAqgmRi7cY2nqMc92/bSEeQA+R4OheNU2T1kNSCBdG0=
|
||||
github.com/markbates/sigtx v1.0.0/go.mod h1:QF1Hv6Ic6Ca6W+T+DL0Y/ypborFKyvUY9HmuCD4VeTc=
|
||||
github.com/markbates/willie v1.0.9/go.mod h1:fsrFVWl91+gXpx/6dv715j7i11fYPfZ9ZGfH0DQzY7w=
|
||||
github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU=
|
||||
github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
|
||||
github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc=
|
||||
github.com/microcosm-cc/bluemonday v1.0.1/go.mod h1:hsXNsILzKxV+sX77C5b8FSuKF00vh2OMYv+xgHpAMF4=
|
||||
github.com/microcosm-cc/bluemonday v1.0.2/go.mod h1:iVP4YcDBq+n/5fb23BhYFvIMq/leAFZyRl6bYmGDlGc=
|
||||
github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
|
||||
github.com/mitchellh/mapstructure v1.0.0/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
|
||||
github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
|
||||
github.com/monoculum/formam v0.0.0-20180901015400-4e68be1d79ba/go.mod h1:RKgILGEJq24YyJ2ban8EO0RUVSJlF1pGsEvoLEACr/Q=
|
||||
github.com/nicksnyder/go-i18n v1.10.0/go.mod h1:HrK7VCrbOvQoUAQ7Vpy7i87N7JZZZ7R2xBGjv0j365Q=
|
||||
github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/gomega v1.4.1/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
|
||||
github.com/onsi/gomega v1.4.2/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
|
||||
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
github.com/pkg/errors v0.8.1 h1:iURUrRGxPUNPdy5/HRSm+Yj6okJ6UtLINN0Q9M4+h3I=
|
||||
github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||
github.com/rogpeppe/go-internal v1.0.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
|
||||
github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0=
|
||||
github.com/serenize/snaker v0.0.0-20171204205717-a683aaf2d516/go.mod h1:Yow6lPLSAXx2ifx470yD/nUe22Dv5vBvxK/UK9UUTVs=
|
||||
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
|
||||
github.com/shopspring/decimal v0.0.0-20180709203117-cd690d0c9e24/go.mod h1:M+9NzErvs504Cn4c5DxATwIqPbtswREoFCre64PpcG4=
|
||||
github.com/shurcooL/go v0.0.0-20180423040247-9e1955d9fb6e/go.mod h1:TDJrrUr11Vxrven61rcy3hJMUqaf/CLWYhHNPmT14Lk=
|
||||
github.com/shurcooL/go-goon v0.0.0-20170922171312-37c2f522c041/go.mod h1:N5mDOmsrJOB+vfqUK+7DmDyjhSLIIBnXo9lvZJj3MWQ=
|
||||
github.com/shurcooL/highlight_diff v0.0.0-20170515013008-09bb4053de1b/go.mod h1:ZpfEhSmds4ytuByIcDnOLkTHGUI6KNqRNPDLHDk+mUU=
|
||||
github.com/shurcooL/highlight_go v0.0.0-20170515013102-78fb10f4a5f8/go.mod h1:UDKB5a1T23gOMUJrI+uSuH0VRDStOiUVSjBTRDVBVag=
|
||||
github.com/shurcooL/octicon v0.0.0-20180602230221-c42b0e3b24d9/go.mod h1:eWdoE5JD4R5UVWDucdOPg1g2fqQRq78IQa9zlOV1vpQ=
|
||||
github.com/shurcooL/sanitized_anchor_name v0.0.0-20170918181015-86672fcb3f95/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
|
||||
github.com/sirupsen/logrus v1.0.6/go.mod h1:pMByvHTf9Beacp5x1UXfOR9xyW/9antXMhjMPG0dEzc=
|
||||
github.com/sirupsen/logrus v1.1.0/go.mod h1:zrgwTnHtNr00buQ1vSptGe8m1f/BbgsPukg8qsT7A+A=
|
||||
github.com/sirupsen/logrus v1.1.1/go.mod h1:zrgwTnHtNr00buQ1vSptGe8m1f/BbgsPukg8qsT7A+A=
|
||||
github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
|
||||
github.com/sirupsen/logrus v1.3.0 h1:hI/7Q+DtNZ2kINb6qt/lS+IyXnHQe9e90POfeewL/ME=
|
||||
github.com/sirupsen/logrus v1.3.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
|
||||
github.com/sourcegraph/annotate v0.0.0-20160123013949-f4cad6c6324d/go.mod h1:UdhH50NIW0fCiwBSr0co2m7BnFLdv4fQTgdqdJTHFeE=
|
||||
github.com/sourcegraph/syntaxhighlight v0.0.0-20170531221838-bd320f5d308e/go.mod h1:HuIsMU8RRBOtsCgI77wP899iHVBQpCmg4ErYMZB+2IA=
|
||||
github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
|
||||
github.com/spf13/afero v1.2.0/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk=
|
||||
github.com/spf13/cast v1.2.0/go.mod h1:r2rcYCSwa1IExKTDiTfzaxqT2FNHs8hODu4LnUfgKEg=
|
||||
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
|
||||
github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
|
||||
github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
|
||||
github.com/spf13/pflag v1.0.2/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
|
||||
github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
|
||||
github.com/spf13/viper v1.2.1/go.mod h1:P4AexN0a+C9tGAnUFNwDMYYZv3pjFuvmeiMyKRaNVlI=
|
||||
github.com/spf13/viper v1.3.1/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s=
|
||||
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
|
||||
github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q=
|
||||
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
|
||||
github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0=
|
||||
github.com/unrolled/secure v0.0.0-20180918153822-f340ee86eb8b/go.mod h1:mnPT77IAdsi/kV7+Es7y+pXALeV3h7G6dQF6mNYjcLA=
|
||||
github.com/unrolled/secure v0.0.0-20181005190816-ff9db2ff917f/go.mod h1:mnPT77IAdsi/kV7+Es7y+pXALeV3h7G6dQF6mNYjcLA=
|
||||
github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q=
|
||||
golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20180910181607-0e37d006457b/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181001203147-e3636079e1a4/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181009213950-7c1a557ab941/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181015023909-0c41d7ab0a0e/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181024171144-74cb1d3d52f4/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181025113841-85e1b3f9139a/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181025213731-e84da0312774/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181106171534-e4dc69e5b2fd/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181112202954-3d3f9f413869/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181127143415-eb0de9b17e85/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20190102171810-8d7daa0c54b3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20190103213133-ff983b9c42bc h1:F5tKCVGp+MUAHhKp5MZtGqAlGX3+oCsiL1Q629FL90M=
|
||||
golang.org/x/crypto v0.0.0-20190103213133-ff983b9c42bc/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180816102801-aaf60122140d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180921000356-2f5d2388922f/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180926154720-4dfa2610cdf3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181005035420-146acd28ed58/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181011144130-49bb7cea24b1/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181017193950-04a2e542c03f/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181102091132-c10e9556a7bc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181106065722-10aee1819953/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181207154023-610586996380/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sys v0.0.0-20180816055513-1c9583448a9c/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180906133057-8cf3aee42992/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180921163948-d47a0f339242/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180927150500-dad3d9fb7b6e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181005133103-4497e2df6f9e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181011152604-fa43e7bc11ba/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181022134430-8a28ead16f52/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181024145615-5cd93ef61a7c/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181025063200-d989b31c8746/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181026064943-731415f00dce/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181106135930-3a76605856fd/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181206074257-70b957f3b65e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190102155601-82a175fd1598 h1:S8GOgffXV1X3fpVG442QRfWOt0iFl79eHJ7OPt725bo=
|
||||
golang.org/x/sys v0.0.0-20190102155601-82a175fd1598/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181003024731-2f84ea8ef872/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181006002542-f60d9635b16a/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181008205924-a2b3f7f249e9/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181013182035-5e66757b835f/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181017214349-06f26fdaaa28/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181024171208-a2dc47679d30/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181026183834-f60e5f99f081/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181105230042-78dc5bac0cac/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181107215632-34b416bd17b3/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181114190951-94339b83286c/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181119130350-139d099f6620/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181127195227-b4e97c0ed882/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181127232545-e782529d0ddd/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181203210056-e5f3ab76ea4b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181205224935-3576414c54a4/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181206194817-bcd4e47d0288/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181207183836-8bc39b988060/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181212172921-837e80568c09/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190102213336-ca9055ed7d04/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190104182027-498d95493402 h1:OWOoOXVO7TiAe7djxWtdLAfVGJsPygFlLYlo+MyngLU=
|
||||
golang.org/x/tools v0.0.0-20190104182027-498d95493402/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
gopkg.in/airbrake/gobrake.v2 v2.0.9/go.mod h1:/h5ZAUhDkGaJfjzjKLSjv6zCL6O0LLBxU4K+aSYdM/U=
|
||||
gopkg.in/alexcesaro/quotedprintable.v3 v3.0.0-20150716171945-2caba252f4dc/go.mod h1:m7x9LTH6d71AHyAX77c9yqWCCa3UKHcVEj9y7hAtKDk=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
|
||||
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
|
||||
gopkg.in/gemnasium/logrus-airbrake-hook.v2 v2.1.2/go.mod h1:Xk6kEKp8OKb+X14hQBKWaSkCsqBpgog8nAV2xsGOxlo=
|
||||
gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df/go.mod h1:LRQQ+SO6ZHR7tOkpBDuZnXENFzX8qRjMDMyPD6BRkCw=
|
||||
gopkg.in/mail.v2 v2.0.0-20180731213649-a0242b2233b4/go.mod h1:htwXN1Qh09vZJ1NVKxQqHPBaCBbzKhp5GzuJEA4VJWw=
|
||||
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw=
|
||||
gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
36
vendor/github.com/gobuffalo/events/listener.go
generated
vendored
Normal file
36
vendor/github.com/gobuffalo/events/listener.go
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
package events
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"runtime"
|
||||
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
// Listener is a function capable of handling events
|
||||
type Listener func(e Event)
|
||||
|
||||
// NamedListen for events. Name is the name of the
|
||||
// listener NOT the events you want to listen for,
|
||||
// so something like "my-listener", "kafka-listener", etc...
|
||||
func NamedListen(name string, l Listener) (DeleteFn, error) {
|
||||
return boss.Listen(name, l)
|
||||
}
|
||||
|
||||
// Listen for events.
|
||||
func Listen(l Listener) (DeleteFn, error) {
|
||||
_, file, line, _ := runtime.Caller(1)
|
||||
return NamedListen(fmt.Sprintf("%s:%d", file, line), l)
|
||||
}
|
||||
|
||||
type listable interface {
|
||||
List() ([]string, error)
|
||||
}
|
||||
|
||||
// List all listeners
|
||||
func List() ([]string, error) {
|
||||
if l, ok := boss.(listable); ok {
|
||||
return l.List()
|
||||
}
|
||||
return []string{}, errors.Errorf("manager %T does not implemented listable", boss)
|
||||
}
|
||||
73
vendor/github.com/gobuffalo/events/listener_map.go
generated
vendored
Normal file
73
vendor/github.com/gobuffalo/events/listener_map.go
generated
vendored
Normal file
@@ -0,0 +1,73 @@
|
||||
//go:generate mapgen -name "listener" -zero "nil" -go-type "Listener" -pkg "" -a "func(e) {}" -b "nil" -c "nil" -bb "nil" -destination "events"
|
||||
// Code generated by github.com/gobuffalo/mapgen. DO NOT EDIT.
|
||||
|
||||
package events
|
||||
|
||||
import (
|
||||
"sort"
|
||||
"sync"
|
||||
)
|
||||
|
||||
// listenerMap wraps sync.Map and uses the following types:
|
||||
// key: string
|
||||
// value: Listener
|
||||
type listenerMap struct {
|
||||
data sync.Map
|
||||
}
|
||||
|
||||
// Delete the key from the map
|
||||
func (m *listenerMap) Delete(key string) {
|
||||
m.data.Delete(key)
|
||||
}
|
||||
|
||||
// Load the key from the map.
|
||||
// Returns Listener or bool.
|
||||
// A false return indicates either the key was not found
|
||||
// or the value is not of type Listener
|
||||
func (m *listenerMap) Load(key string) (Listener, bool) {
|
||||
i, ok := m.data.Load(key)
|
||||
if !ok {
|
||||
return nil, false
|
||||
}
|
||||
s, ok := i.(Listener)
|
||||
return s, ok
|
||||
}
|
||||
|
||||
// LoadOrStore will return an existing key or
|
||||
// store the value if not already in the map
|
||||
func (m *listenerMap) LoadOrStore(key string, value Listener) (Listener, bool) {
|
||||
i, _ := m.data.LoadOrStore(key, value)
|
||||
s, ok := i.(Listener)
|
||||
return s, ok
|
||||
}
|
||||
|
||||
// Range over the Listener values in the map
|
||||
func (m *listenerMap) Range(f func(key string, value Listener) bool) {
|
||||
m.data.Range(func(k, v interface{}) bool {
|
||||
key, ok := k.(string)
|
||||
if !ok {
|
||||
return false
|
||||
}
|
||||
value, ok := v.(Listener)
|
||||
if !ok {
|
||||
return false
|
||||
}
|
||||
return f(key, value)
|
||||
})
|
||||
}
|
||||
|
||||
// Store a Listener in the map
|
||||
func (m *listenerMap) Store(key string, value Listener) {
|
||||
m.data.Store(key, value)
|
||||
}
|
||||
|
||||
// Keys returns a list of keys in the map
|
||||
func (m *listenerMap) Keys() []string {
|
||||
var keys []string
|
||||
m.Range(func(key string, value Listener) bool {
|
||||
keys = append(keys, key)
|
||||
return true
|
||||
})
|
||||
sort.Strings(keys)
|
||||
return keys
|
||||
}
|
||||
86
vendor/github.com/gobuffalo/events/manager.go
generated
vendored
Normal file
86
vendor/github.com/gobuffalo/events/manager.go
generated
vendored
Normal file
@@ -0,0 +1,86 @@
|
||||
package events
|
||||
|
||||
import (
|
||||
"strings"
|
||||
|
||||
"github.com/markbates/safe"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
type DeleteFn func()
|
||||
|
||||
// Manager can be implemented to replace the default
|
||||
// events manager
|
||||
type Manager interface {
|
||||
Listen(string, Listener) (DeleteFn, error)
|
||||
Emit(Event) error
|
||||
}
|
||||
|
||||
// DefaultManager implements a map backed Manager
|
||||
func DefaultManager() Manager {
|
||||
return &manager{
|
||||
listeners: listenerMap{},
|
||||
}
|
||||
}
|
||||
|
||||
// SetManager allows you to replace the default
|
||||
// event manager with a custom one
|
||||
func SetManager(m Manager) {
|
||||
boss = m
|
||||
}
|
||||
|
||||
var boss Manager = DefaultManager()
|
||||
var _ listable = &manager{}
|
||||
|
||||
type manager struct {
|
||||
listeners listenerMap
|
||||
}
|
||||
|
||||
func (m *manager) Listen(name string, l Listener) (DeleteFn, error) {
|
||||
_, ok := m.listeners.Load(name)
|
||||
if ok {
|
||||
return nil, errors.Errorf("listener named %s is already listening", name)
|
||||
}
|
||||
|
||||
m.listeners.Store(name, l)
|
||||
|
||||
df := func() {
|
||||
m.listeners.Delete(name)
|
||||
}
|
||||
|
||||
return df, nil
|
||||
}
|
||||
|
||||
func (m *manager) Emit(e Event) error {
|
||||
if err := e.Validate(); err != nil {
|
||||
return errors.WithStack(err)
|
||||
}
|
||||
e.Kind = strings.ToLower(e.Kind)
|
||||
if e.IsError() && e.Error == nil {
|
||||
e.Error = errors.New(e.Kind)
|
||||
}
|
||||
go func(e Event) {
|
||||
m.listeners.Range(func(key string, l Listener) bool {
|
||||
ex := Event{
|
||||
Kind: e.Kind,
|
||||
Error: e.Error,
|
||||
Message: e.Message,
|
||||
Payload: Payload{},
|
||||
}
|
||||
for k, v := range e.Payload {
|
||||
ex.Payload[k] = v
|
||||
}
|
||||
go func(e Event, l Listener) {
|
||||
safe.Run(func() {
|
||||
l(e)
|
||||
})
|
||||
}(ex, l)
|
||||
return true
|
||||
})
|
||||
}(e)
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *manager) List() ([]string, error) {
|
||||
return m.listeners.Keys(), nil
|
||||
}
|
||||
67
vendor/github.com/gobuffalo/events/plugins.go
generated
vendored
Normal file
67
vendor/github.com/gobuffalo/events/plugins.go
generated
vendored
Normal file
@@ -0,0 +1,67 @@
|
||||
package events
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"os"
|
||||
"os/exec"
|
||||
"strings"
|
||||
|
||||
"github.com/gobuffalo/buffalo-plugins/plugins"
|
||||
"github.com/gobuffalo/envy"
|
||||
"github.com/markbates/oncer"
|
||||
"github.com/markbates/safe"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
// LoadPlugins will add listeners for any plugins that support "events"
|
||||
func LoadPlugins() error {
|
||||
var err error
|
||||
oncer.Do("events.LoadPlugins", func() {
|
||||
// don't send plugins events during testing
|
||||
if envy.Get("GO_ENV", "development") == "test" {
|
||||
return
|
||||
}
|
||||
plugs, err := plugins.Available()
|
||||
if err != nil {
|
||||
err = errors.WithStack(err)
|
||||
return
|
||||
}
|
||||
for _, cmds := range plugs {
|
||||
for _, c := range cmds {
|
||||
if c.BuffaloCommand != "events" {
|
||||
continue
|
||||
}
|
||||
err := func(c plugins.Command) error {
|
||||
return safe.RunE(func() error {
|
||||
n := fmt.Sprintf("[PLUGIN] %s %s", c.Binary, c.Name)
|
||||
_, err := NamedListen(n, func(e Event) {
|
||||
b, err := json.Marshal(e)
|
||||
if err != nil {
|
||||
fmt.Println("error trying to marshal event", e, err)
|
||||
return
|
||||
}
|
||||
cmd := exec.Command(c.Binary, c.UseCommand, string(b))
|
||||
cmd.Stderr = os.Stderr
|
||||
cmd.Stdout = os.Stdout
|
||||
cmd.Stdin = os.Stdin
|
||||
if err := cmd.Run(); err != nil {
|
||||
fmt.Println("error trying to send event", strings.Join(cmd.Args, " "), err)
|
||||
}
|
||||
})
|
||||
if err != nil {
|
||||
return errors.WithStack(err)
|
||||
}
|
||||
return nil
|
||||
})
|
||||
}(c)
|
||||
if err != nil {
|
||||
err = errors.WithStack(err)
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
})
|
||||
return err
|
||||
}
|
||||
50
vendor/github.com/gobuffalo/events/shoulders.md
generated
vendored
Normal file
50
vendor/github.com/gobuffalo/events/shoulders.md
generated
vendored
Normal file
@@ -0,0 +1,50 @@
|
||||
# github.com/gobuffalo/events Stands on the Shoulders of Giants
|
||||
|
||||
github.com/gobuffalo/events does not try to reinvent the wheel! Instead, it uses the already great wheels developed by the Go community and puts them all together in the best way possible. Without these giants this project would not be possible. Please make sure to check them out and thank them for all of their hard work.
|
||||
|
||||
Thank you to the following **GIANTS**:
|
||||
|
||||
|
||||
* [github.com/BurntSushi/toml](https://godoc.org/github.com/BurntSushi/toml)
|
||||
|
||||
* [github.com/gobuffalo/buffalo-plugins/plugins](https://godoc.org/github.com/gobuffalo/buffalo-plugins/plugins)
|
||||
|
||||
* [github.com/gobuffalo/buffalo-plugins/plugins/plugdeps](https://godoc.org/github.com/gobuffalo/buffalo-plugins/plugins/plugdeps)
|
||||
|
||||
* [github.com/gobuffalo/envy](https://godoc.org/github.com/gobuffalo/envy)
|
||||
|
||||
* [github.com/gobuffalo/events](https://godoc.org/github.com/gobuffalo/events)
|
||||
|
||||
* [github.com/gobuffalo/flect](https://godoc.org/github.com/gobuffalo/flect)
|
||||
|
||||
* [github.com/gobuffalo/flect/name](https://godoc.org/github.com/gobuffalo/flect/name)
|
||||
|
||||
* [github.com/gobuffalo/mapi](https://godoc.org/github.com/gobuffalo/mapi)
|
||||
|
||||
* [github.com/gobuffalo/meta](https://godoc.org/github.com/gobuffalo/meta)
|
||||
|
||||
* [github.com/joho/godotenv](https://godoc.org/github.com/joho/godotenv)
|
||||
|
||||
* [github.com/karrick/godirwalk](https://godoc.org/github.com/karrick/godirwalk)
|
||||
|
||||
* [github.com/markbates/oncer](https://godoc.org/github.com/markbates/oncer)
|
||||
|
||||
* [github.com/markbates/safe](https://godoc.org/github.com/markbates/safe)
|
||||
|
||||
* [github.com/pkg/errors](https://godoc.org/github.com/pkg/errors)
|
||||
|
||||
* [github.com/rogpeppe/go-internal/modfile](https://godoc.org/github.com/rogpeppe/go-internal/modfile)
|
||||
|
||||
* [github.com/rogpeppe/go-internal/module](https://godoc.org/github.com/rogpeppe/go-internal/module)
|
||||
|
||||
* [github.com/rogpeppe/go-internal/semver](https://godoc.org/github.com/rogpeppe/go-internal/semver)
|
||||
|
||||
* [github.com/sirupsen/logrus](https://godoc.org/github.com/sirupsen/logrus)
|
||||
|
||||
* [github.com/spf13/cobra](https://godoc.org/github.com/spf13/cobra)
|
||||
|
||||
* [github.com/spf13/pflag](https://godoc.org/github.com/spf13/pflag)
|
||||
|
||||
* [golang.org/x/crypto/ssh/terminal](https://godoc.org/golang.org/x/crypto/ssh/terminal)
|
||||
|
||||
* [golang.org/x/sys/unix](https://godoc.org/golang.org/x/sys/unix)
|
||||
3
vendor/github.com/gobuffalo/events/version.go
generated
vendored
Normal file
3
vendor/github.com/gobuffalo/events/version.go
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
package events
|
||||
|
||||
const Version = "v1.1.9"
|
||||
29
vendor/github.com/gobuffalo/flect/.gitignore
generated
vendored
Normal file
29
vendor/github.com/gobuffalo/flect/.gitignore
generated
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
*.log
|
||||
.DS_Store
|
||||
doc
|
||||
tmp
|
||||
pkg
|
||||
*.gem
|
||||
*.pid
|
||||
coverage
|
||||
coverage.data
|
||||
build/*
|
||||
*.pbxuser
|
||||
*.mode1v3
|
||||
.svn
|
||||
profile
|
||||
.console_history
|
||||
.sass-cache/*
|
||||
.rake_tasks~
|
||||
*.log.lck
|
||||
solr/
|
||||
.jhw-cache/
|
||||
jhw.*
|
||||
*.sublime*
|
||||
node_modules/
|
||||
dist/
|
||||
generated/
|
||||
.vendor/
|
||||
bin/*
|
||||
gin-bin
|
||||
.idea/
|
||||
3
vendor/github.com/gobuffalo/flect/.gometalinter.json
generated
vendored
Normal file
3
vendor/github.com/gobuffalo/flect/.gometalinter.json
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"Enable": ["vet", "golint", "goimports", "deadcode", "gotype", "ineffassign", "misspell", "nakedret", "unconvert", "megacheck", "varcheck"]
|
||||
}
|
||||
36
vendor/github.com/gobuffalo/flect/.travis.yml
generated
vendored
Normal file
36
vendor/github.com/gobuffalo/flect/.travis.yml
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
language: go
|
||||
|
||||
sudo: false
|
||||
|
||||
matrix:
|
||||
include:
|
||||
- os: linux
|
||||
go: "1.9.x"
|
||||
- os: windows
|
||||
go: "1.9.x"
|
||||
- os: linux
|
||||
go: "1.10.x"
|
||||
- os: windows
|
||||
go: "1.10.x"
|
||||
- os: linux
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=off
|
||||
- os: windows
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=off
|
||||
- os: linux
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=on
|
||||
- os: windows
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=on
|
||||
|
||||
install: false
|
||||
|
||||
script:
|
||||
- go get -v -t ./...
|
||||
- go test -v -timeout=5s -race ./...
|
||||
8
vendor/github.com/gobuffalo/flect/LICENSE.txt
generated
vendored
Normal file
8
vendor/github.com/gobuffalo/flect/LICENSE.txt
generated
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
The MIT License (MIT)
|
||||
Copyright (c) 2018 Mark Bates
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
46
vendor/github.com/gobuffalo/flect/Makefile
generated
vendored
Normal file
46
vendor/github.com/gobuffalo/flect/Makefile
generated
vendored
Normal file
@@ -0,0 +1,46 @@
|
||||
TAGS ?= "sqlite"
|
||||
GO_BIN ?= go
|
||||
|
||||
install:
|
||||
packr
|
||||
$(GO_BIN) install -v .
|
||||
|
||||
deps:
|
||||
$(GO_BIN) get github.com/gobuffalo/release
|
||||
$(GO_BIN) get github.com/gobuffalo/packr/packr
|
||||
$(GO_BIN) get -tags ${TAGS} -t ./...
|
||||
ifeq ($(GO111MODULE),on)
|
||||
$(GO_BIN) mod tidy
|
||||
endif
|
||||
|
||||
build:
|
||||
packr
|
||||
$(GO_BIN) build -v .
|
||||
|
||||
test:
|
||||
packr
|
||||
$(GO_BIN) test -tags ${TAGS} ./...
|
||||
|
||||
ci-test:
|
||||
$(GO_BIN) test -tags ${TAGS} -race ./...
|
||||
|
||||
lint:
|
||||
gometalinter --vendor ./... --deadline=1m --skip=internal
|
||||
|
||||
update:
|
||||
$(GO_BIN) get -u -tags ${TAGS}
|
||||
ifeq ($(GO111MODULE),on)
|
||||
$(GO_BIN) mod tidy
|
||||
endif
|
||||
packr
|
||||
make test
|
||||
make install
|
||||
ifeq ($(GO111MODULE),on)
|
||||
$(GO_BIN) mod tidy
|
||||
endif
|
||||
|
||||
release-test:
|
||||
$(GO_BIN) test -tags ${TAGS} -race ./...
|
||||
|
||||
release:
|
||||
release -y -f version.go
|
||||
36
vendor/github.com/gobuffalo/flect/README.md
generated
vendored
Normal file
36
vendor/github.com/gobuffalo/flect/README.md
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
# Flect
|
||||
|
||||
<p align="center">
|
||||
<a href="https://godoc.org/github.com/gobuffalo/flect"><img src="https://godoc.org/github.com/gobuffalo/flect?status.svg" alt="GoDoc" /></a>
|
||||
<a href="https://travis-ci.org/gobuffalo/flect"><img src="https://travis-ci.org/gobuffalo/flect.svg?branch=master" alt="Build Status" /></a>
|
||||
<a href="https://goreportcard.com/report/github.com/gobuffalo/flect"><img src="https://goreportcard.com/badge/github.com/gobuffalo/flect" alt="Go Report Card" /></a>
|
||||
</p>
|
||||
|
||||
This is a new inflection engine to replace [https://github.com/markbates/inflect](https://github.com/markbates/inflect) designed to be more modular, more readable, and easier to fix issues on than the original.
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
$ go get -u -v github.com/gobuffalo/flect
|
||||
```
|
||||
|
||||
## `github.com/gobuffalo/flect`
|
||||
<a href="https://godoc.org/github.com/gobuffalo/flect"><img src="https://godoc.org/github.com/gobuffalo/flect?status.svg" alt="GoDoc" /></a>
|
||||
|
||||
The `github.com/gobuffalo/flect` package contains "basic" inflection tools, like pluralization, singularization, etc...
|
||||
|
||||
### The `Ident` Type
|
||||
|
||||
In addition to helpful methods that take in a `string` and return a `string`, there is an `Ident` type that can be used to create new, custom, inflection rules.
|
||||
|
||||
The `Ident` type contains two fields.
|
||||
|
||||
* `Original` - This is the original `string` that was used to create the `Ident`
|
||||
* `Parts` - This is a `[]string` that represents all of the "parts" of the string, that have been split apart, making the segments easier to work with
|
||||
|
||||
Examples of creating new inflection rules using `Ident` can be found in the `github.com/gobuffalo/flect/name` package.
|
||||
|
||||
## `github.com/gobuffalo/flect/name`
|
||||
<a href="https://godoc.org/github.com/gobuffalo/flect/name"><img src="https://godoc.org/github.com/gobuffalo/flect/name?status.svg" alt="GoDoc" /></a>
|
||||
|
||||
The `github.com/gobuffalo/flect/name` package contains more "business" inflection rules like creating proper names, table names, etc...
|
||||
152
vendor/github.com/gobuffalo/flect/acronyms.go
generated
vendored
Normal file
152
vendor/github.com/gobuffalo/flect/acronyms.go
generated
vendored
Normal file
@@ -0,0 +1,152 @@
|
||||
package flect
|
||||
|
||||
import "sync"
|
||||
|
||||
var acronymsMoot = &sync.RWMutex{}
|
||||
|
||||
var baseAcronyms = map[string]bool{
|
||||
"OK": true,
|
||||
"UTF8": true,
|
||||
"HTML": true,
|
||||
"JSON": true,
|
||||
"JWT": true,
|
||||
"ID": true,
|
||||
"UUID": true,
|
||||
"SQL": true,
|
||||
"ACK": true,
|
||||
"ACL": true,
|
||||
"ADSL": true,
|
||||
"AES": true,
|
||||
"ANSI": true,
|
||||
"API": true,
|
||||
"ARP": true,
|
||||
"ATM": true,
|
||||
"BGP": true,
|
||||
"BSS": true,
|
||||
"CCITT": true,
|
||||
"CHAP": true,
|
||||
"CIDR": true,
|
||||
"CIR": true,
|
||||
"CLI": true,
|
||||
"CPE": true,
|
||||
"CPU": true,
|
||||
"CRC": true,
|
||||
"CRT": true,
|
||||
"CSMA": true,
|
||||
"CMOS": true,
|
||||
"DCE": true,
|
||||
"DEC": true,
|
||||
"DES": true,
|
||||
"DHCP": true,
|
||||
"DNS": true,
|
||||
"DRAM": true,
|
||||
"DSL": true,
|
||||
"DSLAM": true,
|
||||
"DTE": true,
|
||||
"DMI": true,
|
||||
"EHA": true,
|
||||
"EIA": true,
|
||||
"EIGRP": true,
|
||||
"EOF": true,
|
||||
"ESS": true,
|
||||
"FCC": true,
|
||||
"FCS": true,
|
||||
"FDDI": true,
|
||||
"FTP": true,
|
||||
"GBIC": true,
|
||||
"gbps": true,
|
||||
"GEPOF": true,
|
||||
"HDLC": true,
|
||||
"HTTP": true,
|
||||
"HTTPS": true,
|
||||
"IANA": true,
|
||||
"ICMP": true,
|
||||
"IDF": true,
|
||||
"IDS": true,
|
||||
"IEEE": true,
|
||||
"IETF": true,
|
||||
"IMAP": true,
|
||||
"IP": true,
|
||||
"IPS": true,
|
||||
"ISDN": true,
|
||||
"ISP": true,
|
||||
"kbps": true,
|
||||
"LACP": true,
|
||||
"LAN": true,
|
||||
"LAPB": true,
|
||||
"LAPF": true,
|
||||
"LLC": true,
|
||||
"MAC": true,
|
||||
"Mbps": true,
|
||||
"MC": true,
|
||||
"MDF": true,
|
||||
"MIB": true,
|
||||
"MoCA": true,
|
||||
"MPLS": true,
|
||||
"MTU": true,
|
||||
"NAC": true,
|
||||
"NAT": true,
|
||||
"NBMA": true,
|
||||
"NIC": true,
|
||||
"NRZ": true,
|
||||
"NRZI": true,
|
||||
"NVRAM": true,
|
||||
"OSI": true,
|
||||
"OSPF": true,
|
||||
"OUI": true,
|
||||
"PAP": true,
|
||||
"PAT": true,
|
||||
"PC": true,
|
||||
"PIM": true,
|
||||
"PCM": true,
|
||||
"PDU": true,
|
||||
"POP3": true,
|
||||
"POTS": true,
|
||||
"PPP": true,
|
||||
"PPTP": true,
|
||||
"PTT": true,
|
||||
"PVST": true,
|
||||
"RAM": true,
|
||||
"RARP": true,
|
||||
"RFC": true,
|
||||
"RIP": true,
|
||||
"RLL": true,
|
||||
"ROM": true,
|
||||
"RSTP": true,
|
||||
"RTP": true,
|
||||
"RCP": true,
|
||||
"SDLC": true,
|
||||
"SFD": true,
|
||||
"SFP": true,
|
||||
"SLARP": true,
|
||||
"SLIP": true,
|
||||
"SMTP": true,
|
||||
"SNA": true,
|
||||
"SNAP": true,
|
||||
"SNMP": true,
|
||||
"SOF": true,
|
||||
"SRAM": true,
|
||||
"SSH": true,
|
||||
"SSID": true,
|
||||
"STP": true,
|
||||
"SYN": true,
|
||||
"TDM": true,
|
||||
"TFTP": true,
|
||||
"TIA": true,
|
||||
"TOFU": true,
|
||||
"UDP": true,
|
||||
"URL": true,
|
||||
"URI": true,
|
||||
"USB": true,
|
||||
"UTP": true,
|
||||
"VC": true,
|
||||
"VLAN": true,
|
||||
"VLSM": true,
|
||||
"VPN": true,
|
||||
"W3C": true,
|
||||
"WAN": true,
|
||||
"WEP": true,
|
||||
"WiFi": true,
|
||||
"WPA": true,
|
||||
"WWW": true,
|
||||
}
|
||||
48
vendor/github.com/gobuffalo/flect/camelize.go
generated
vendored
Normal file
48
vendor/github.com/gobuffalo/flect/camelize.go
generated
vendored
Normal file
@@ -0,0 +1,48 @@
|
||||
package flect
|
||||
|
||||
import (
|
||||
"strings"
|
||||
"unicode"
|
||||
)
|
||||
|
||||
// Camelize returns a camelize version of a string
|
||||
// bob dylan = bobDylan
|
||||
// widget_id = widgetID
|
||||
// WidgetID = widgetID
|
||||
func Camelize(s string) string {
|
||||
return New(s).Camelize().String()
|
||||
}
|
||||
|
||||
// Camelize returns a camelize version of a string
|
||||
// bob dylan = bobDylan
|
||||
// widget_id = widgetID
|
||||
// WidgetID = widgetID
|
||||
func (i Ident) Camelize() Ident {
|
||||
var out []string
|
||||
for i, part := range i.Parts {
|
||||
var x string
|
||||
var capped bool
|
||||
if strings.ToLower(part) == "id" {
|
||||
out = append(out, "ID")
|
||||
continue
|
||||
}
|
||||
for _, c := range part {
|
||||
if unicode.IsLetter(c) || unicode.IsDigit(c) {
|
||||
if i == 0 {
|
||||
x += string(unicode.ToLower(c))
|
||||
continue
|
||||
}
|
||||
if !capped {
|
||||
capped = true
|
||||
x += string(unicode.ToUpper(c))
|
||||
continue
|
||||
}
|
||||
x += string(c)
|
||||
}
|
||||
}
|
||||
if x != "" {
|
||||
out = append(out, x)
|
||||
}
|
||||
}
|
||||
return New(strings.Join(out, ""))
|
||||
}
|
||||
27
vendor/github.com/gobuffalo/flect/capitalize.go
generated
vendored
Normal file
27
vendor/github.com/gobuffalo/flect/capitalize.go
generated
vendored
Normal file
@@ -0,0 +1,27 @@
|
||||
package flect
|
||||
|
||||
import "unicode"
|
||||
|
||||
// Capitalize will cap the first letter of string
|
||||
// user = User
|
||||
// bob dylan = Bob dylan
|
||||
// widget_id = Widget_id
|
||||
func Capitalize(s string) string {
|
||||
return New(s).Capitalize().String()
|
||||
}
|
||||
|
||||
// Capitalize will cap the first letter of string
|
||||
// user = User
|
||||
// bob dylan = Bob dylan
|
||||
// widget_id = Widget_id
|
||||
func (i Ident) Capitalize() Ident {
|
||||
var x string
|
||||
if len(i.Parts) == 0 {
|
||||
return New("")
|
||||
}
|
||||
x = string(unicode.ToTitle(rune(i.Original[0])))
|
||||
if len(i.Original) > 1 {
|
||||
x += i.Original[1:]
|
||||
}
|
||||
return New(x)
|
||||
}
|
||||
82
vendor/github.com/gobuffalo/flect/custom_data.go
generated
vendored
Normal file
82
vendor/github.com/gobuffalo/flect/custom_data.go
generated
vendored
Normal file
@@ -0,0 +1,82 @@
|
||||
package flect
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/gobuffalo/envy"
|
||||
)
|
||||
|
||||
func init() {
|
||||
loadCustomData("inflections.json", "INFLECT_PATH", "could not read inflection file", LoadInflections)
|
||||
loadCustomData("acronyms.json", "ACRONYMS_PATH", "could not read acronyms file", LoadAcronyms)
|
||||
}
|
||||
|
||||
//CustomDataParser are functions that parse data like acronyms or
|
||||
//plurals in the shape of a io.Reader it receives.
|
||||
type CustomDataParser func(io.Reader) error
|
||||
|
||||
func loadCustomData(defaultFile, env, readErrorMessage string, parser CustomDataParser) {
|
||||
pwd, _ := os.Getwd()
|
||||
path := envy.Get(env, filepath.Join(pwd, defaultFile))
|
||||
|
||||
if _, err := os.Stat(path); err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
b, err := ioutil.ReadFile(path)
|
||||
if err != nil {
|
||||
fmt.Printf("%s %s (%s)\n", readErrorMessage, path, err)
|
||||
return
|
||||
}
|
||||
|
||||
if err = parser(bytes.NewReader(b)); err != nil {
|
||||
fmt.Println(err)
|
||||
}
|
||||
}
|
||||
|
||||
//LoadAcronyms loads rules from io.Reader param
|
||||
func LoadAcronyms(r io.Reader) error {
|
||||
m := []string{}
|
||||
err := json.NewDecoder(r).Decode(&m)
|
||||
|
||||
if err != nil {
|
||||
return fmt.Errorf("could not decode acronyms JSON from reader: %s", err)
|
||||
}
|
||||
|
||||
acronymsMoot.Lock()
|
||||
defer acronymsMoot.Unlock()
|
||||
|
||||
for _, acronym := range m {
|
||||
baseAcronyms[acronym] = true
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
//LoadInflections loads rules from io.Reader param
|
||||
func LoadInflections(r io.Reader) error {
|
||||
m := map[string]string{}
|
||||
|
||||
err := json.NewDecoder(r).Decode(&m)
|
||||
if err != nil {
|
||||
return fmt.Errorf("could not decode inflection JSON from reader: %s", err)
|
||||
}
|
||||
|
||||
pluralMoot.Lock()
|
||||
defer pluralMoot.Unlock()
|
||||
singularMoot.Lock()
|
||||
defer singularMoot.Unlock()
|
||||
|
||||
for s, p := range m {
|
||||
singleToPlural[s] = p
|
||||
pluralToSingle[p] = s
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
34
vendor/github.com/gobuffalo/flect/dasherize.go
generated
vendored
Normal file
34
vendor/github.com/gobuffalo/flect/dasherize.go
generated
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
package flect
|
||||
|
||||
import (
|
||||
"strings"
|
||||
"unicode"
|
||||
)
|
||||
|
||||
// Dasherize returns an alphanumeric, lowercased, dashed string
|
||||
// Donald E. Knuth = donald-e-knuth
|
||||
// Test with + sign = test-with-sign
|
||||
// admin/WidgetID = admin-widget-id
|
||||
func Dasherize(s string) string {
|
||||
return New(s).Dasherize().String()
|
||||
}
|
||||
|
||||
// Dasherize returns an alphanumeric, lowercased, dashed string
|
||||
// Donald E. Knuth = donald-e-knuth
|
||||
// Test with + sign = test-with-sign
|
||||
// admin/WidgetID = admin-widget-id
|
||||
func (i Ident) Dasherize() Ident {
|
||||
var parts []string
|
||||
|
||||
for _, part := range i.Parts {
|
||||
var x string
|
||||
for _, c := range part {
|
||||
if unicode.IsLetter(c) || unicode.IsDigit(c) {
|
||||
x += string(c)
|
||||
}
|
||||
}
|
||||
parts = xappend(parts, x)
|
||||
}
|
||||
|
||||
return New(strings.ToLower(strings.Join(parts, "-")))
|
||||
}
|
||||
43
vendor/github.com/gobuffalo/flect/flect.go
generated
vendored
Normal file
43
vendor/github.com/gobuffalo/flect/flect.go
generated
vendored
Normal file
@@ -0,0 +1,43 @@
|
||||
/*
|
||||
Package flect is a new inflection engine to replace [https://github.com/markbates/inflect](https://github.com/markbates/inflect) designed to be more modular, more readable, and easier to fix issues on than the original.
|
||||
*/
|
||||
package flect
|
||||
|
||||
import (
|
||||
"strings"
|
||||
"unicode"
|
||||
)
|
||||
|
||||
var spaces = []rune{'_', ' ', ':', '-', '/'}
|
||||
|
||||
func isSpace(c rune) bool {
|
||||
for _, r := range spaces {
|
||||
if r == c {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return unicode.IsSpace(c)
|
||||
}
|
||||
|
||||
func xappend(a []string, ss ...string) []string {
|
||||
for _, s := range ss {
|
||||
s = strings.TrimSpace(s)
|
||||
for _, x := range spaces {
|
||||
s = strings.Trim(s, string(x))
|
||||
}
|
||||
if _, ok := baseAcronyms[strings.ToUpper(s)]; ok {
|
||||
s = strings.ToUpper(s)
|
||||
}
|
||||
if s != "" {
|
||||
a = append(a, s)
|
||||
}
|
||||
}
|
||||
return a
|
||||
}
|
||||
|
||||
func abs(x int) int {
|
||||
if x < 0 {
|
||||
return -x
|
||||
}
|
||||
return x
|
||||
}
|
||||
6
vendor/github.com/gobuffalo/flect/go.mod
generated
vendored
Normal file
6
vendor/github.com/gobuffalo/flect/go.mod
generated
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
module github.com/gobuffalo/flect
|
||||
|
||||
require (
|
||||
github.com/gobuffalo/envy v1.6.11
|
||||
github.com/stretchr/testify v1.3.0
|
||||
)
|
||||
324
vendor/github.com/gobuffalo/flect/go.sum
generated
vendored
Normal file
324
vendor/github.com/gobuffalo/flect/go.sum
generated
vendored
Normal file
@@ -0,0 +1,324 @@
|
||||
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
|
||||
github.com/Masterminds/semver v1.4.2/go.mod h1:MB6lktGJrhw8PrUyiEoblNEGEQ+RzHPF078ddwwvV3Y=
|
||||
github.com/ajg/form v0.0.0-20160822230020-523a5da1a92f/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY=
|
||||
github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ=
|
||||
github.com/cockroachdb/cockroach-go v0.0.0-20181001143604-e0a95dfd547c/go.mod h1:XGLbWH/ujMcbPbhZq52Nv6UrCghb1yGn//133kEsvDk=
|
||||
github.com/codegangsta/negroni v1.0.0/go.mod h1:v0y3T5G7Y1UlFfyxFn/QLRU4a2EuNau2iZY63YTKWo0=
|
||||
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
|
||||
github.com/dustin/go-humanize v0.0.0-20180713052910-9f541cc9db5d/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
|
||||
github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
|
||||
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
|
||||
github.com/fatih/structs v1.0.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M=
|
||||
github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M=
|
||||
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
|
||||
github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w=
|
||||
github.com/gobuffalo/buffalo v0.12.8-0.20181004233540-fac9bb505aa8/go.mod h1:sLyT7/dceRXJUxSsE813JTQtA3Eb1vjxWfo/N//vXIY=
|
||||
github.com/gobuffalo/buffalo v0.13.0/go.mod h1:Mjn1Ba9wpIbpbrD+lIDMy99pQ0H0LiddMIIDGse7qT4=
|
||||
github.com/gobuffalo/buffalo-plugins v1.0.2/go.mod h1:pOp/uF7X3IShFHyobahTkTLZaeUXwb0GrUTb9ngJWTs=
|
||||
github.com/gobuffalo/buffalo-plugins v1.0.4/go.mod h1:pWS1vjtQ6uD17MVFWf7i3zfThrEKWlI5+PYLw/NaDB4=
|
||||
github.com/gobuffalo/buffalo-plugins v1.4.3/go.mod h1:uCzTY0woez4nDMdQjkcOYKanngeUVRO2HZi7ezmAjWY=
|
||||
github.com/gobuffalo/buffalo-plugins v1.5.1/go.mod h1:jbmwSZK5+PiAP9cC09VQOrGMZFCa/P0UMlIS3O12r5w=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.4/go.mod h1:/+N1aophkA2jZ1ifB2O3Y9yGwu6gKOVMtUmJnbg+OZI=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.5/go.mod h1:0HVkbgrVs/MnPZ/FOseDMVanCTm2RNcdM0PuXcL1NNI=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.7/go.mod h1:ZGZRkzz2PiKWHs0z7QsPBOTo2EpcGRArMEym6ghKYgk=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.9/go.mod h1:yYlYTrPdMCz+6/+UaXg5Jm4gN3xhsvsQ2ygVatZV5vw=
|
||||
github.com/gobuffalo/buffalo-plugins v1.6.11/go.mod h1:eAA6xJIL8OuynJZ8amXjRmHND6YiusVAaJdHDN1Lu8Q=
|
||||
github.com/gobuffalo/buffalo-plugins v1.8.2/go.mod h1:9te6/VjEQ7pKp7lXlDIMqzxgGpjlKoAcAANdCgoR960=
|
||||
github.com/gobuffalo/buffalo-pop v1.0.5/go.mod h1:Fw/LfFDnSmB/vvQXPvcXEjzP98Tc+AudyNWUBWKCwQ8=
|
||||
github.com/gobuffalo/envy v1.6.4/go.mod h1:Abh+Jfw475/NWtYMEt+hnJWRiC8INKWibIMyNt1w2Mc=
|
||||
github.com/gobuffalo/envy v1.6.5/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.6/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.7/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.8/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.9/go.mod h1:N+GkhhZ/93bGZc6ZKhJLP6+m+tCNPKwgSpH9kaifseQ=
|
||||
github.com/gobuffalo/envy v1.6.10/go.mod h1:X0CFllQjTV5ogsnUrg+Oks2yTI+PU2dGYBJOEI2D1Uo=
|
||||
github.com/gobuffalo/envy v1.6.11/go.mod h1:Fiq52W7nrHGDggFPhn2ZCcHw4u/rqXkqo+i7FB6EAcg=
|
||||
github.com/gobuffalo/events v1.0.3/go.mod h1:Txo8WmqScapa7zimEQIwgiJBvMECMe9gJjsKNPN3uZw=
|
||||
github.com/gobuffalo/events v1.0.7/go.mod h1:z8txf6H9jWhQ5Scr7YPLWg/cgXBRj8Q4uYI+rsVCCSQ=
|
||||
github.com/gobuffalo/events v1.0.8/go.mod h1:A5KyqT1sA+3GJiBE4QKZibse9mtOcI9nw8gGrDdqYGs=
|
||||
github.com/gobuffalo/events v1.1.3/go.mod h1:9yPGWYv11GENtzrIRApwQRMYSbUgCsZ1w6R503fCfrk=
|
||||
github.com/gobuffalo/events v1.1.4/go.mod h1:09/YRRgZHEOts5Isov+g9X2xajxdvOAcUuAHIX/O//A=
|
||||
github.com/gobuffalo/events v1.1.5/go.mod h1:3YUSzgHfYctSjEjLCWbkXP6djH2M+MLaVRzb4ymbAK0=
|
||||
github.com/gobuffalo/events v1.1.7/go.mod h1:6fGqxH2ing5XMb3EYRq9LEkVlyPGs4oO/eLzh+S8CxY=
|
||||
github.com/gobuffalo/events v1.1.8/go.mod h1:UFy+W6X6VbCWS8k2iT81HYX65dMtiuVycMy04cplt/8=
|
||||
github.com/gobuffalo/fizz v1.0.12/go.mod h1:C0sltPxpYK8Ftvf64kbsQa2yiCZY4RZviurNxXdAKwc=
|
||||
github.com/gobuffalo/flect v0.0.0-20180907193754-dc14d8acaf9f/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181002182613-4571df4b1daf/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181007231023-ae7ed6bfe683/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181018182602-fd24a256709f/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181019110701-3d6f0b585514/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181024204909-8f6be1a8c6c2/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181104133451-1f6e9779237a/go.mod h1:rCiQgmAE4axgBNl3jZWzS5rETRYTGOsrixTRaCPzNdA=
|
||||
github.com/gobuffalo/flect v0.0.0-20181114183036-47375f6d8328/go.mod h1:0HvNbHdfh+WOvDSIASqJOSxTOWSxCCUF++k/Y53v9rI=
|
||||
github.com/gobuffalo/genny v0.0.0-20180924032338-7af3a40f2252/go.mod h1:tUTQOogrr7tAQnhajMSH6rv1BVev34H2sa1xNHMy94g=
|
||||
github.com/gobuffalo/genny v0.0.0-20181003150629-3786a0744c5d/go.mod h1:WAd8HmjMVrnkAZbmfgH5dLBUchsZfqzp/WS5sQz+uTM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181005145118-318a41a134cc/go.mod h1:WAd8HmjMVrnkAZbmfgH5dLBUchsZfqzp/WS5sQz+uTM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181007153042-b8de7d566757/go.mod h1:+oG5Ljrw04czAHbPXREwaFojJbpUvcIy4DiOnbEJFTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181012161047-33e5f43d83a6/go.mod h1:+oG5Ljrw04czAHbPXREwaFojJbpUvcIy4DiOnbEJFTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181017160347-90a774534246/go.mod h1:+oG5Ljrw04czAHbPXREwaFojJbpUvcIy4DiOnbEJFTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181024195656-51392254bf53/go.mod h1:o9GEH5gn5sCKLVB5rHFC4tq40rQ3VRUzmx6WwmaqISE=
|
||||
github.com/gobuffalo/genny v0.0.0-20181025145300-af3f81d526b8/go.mod h1:uZ1fFYvdcP8mu0B/Ynarf6dsGvp7QFIpk/QACUuFUVI=
|
||||
github.com/gobuffalo/genny v0.0.0-20181027191429-94d6cfb5c7fc/go.mod h1:x7SkrQQBx204Y+O9EwRXeszLJDTaWN0GnEasxgLrQTA=
|
||||
github.com/gobuffalo/genny v0.0.0-20181027195209-3887b7171c4f/go.mod h1:JbKx8HSWICu5zyqWOa0dVV1pbbXOHusrSzQUprW6g+w=
|
||||
github.com/gobuffalo/genny v0.0.0-20181106193839-7dcb0924caf1/go.mod h1:x61yHxvbDCgQ/7cOAbJCacZQuHgB0KMSzoYcw5debjU=
|
||||
github.com/gobuffalo/genny v0.0.0-20181107223128-f18346459dbe/go.mod h1:utQD3aKKEsdb03oR+Vi/6ztQb1j7pO10N3OBoowRcSU=
|
||||
github.com/gobuffalo/genny v0.0.0-20181114215459-0a4decd77f5d/go.mod h1:kN2KZ8VgXF9VIIOj/GM0Eo7YK+un4Q3tTreKOf0q1ng=
|
||||
github.com/gobuffalo/genny v0.0.0-20181119162812-e8ff4adce8bb/go.mod h1:BA9htSe4bZwBDJLe8CUkoqkypq3hn3+CkoHqVOW718E=
|
||||
github.com/gobuffalo/genny v0.0.0-20181127225641-2d959acc795b/go.mod h1:l54xLXNkteX/PdZ+HlgPk1qtcrgeOr3XUBBPDbH+7CQ=
|
||||
github.com/gobuffalo/genny v0.0.0-20181128191930-77e34f71ba2a/go.mod h1:FW/D9p7cEEOqxYA71/hnrkOWm62JZ5ZNxcNIVJEaWBU=
|
||||
github.com/gobuffalo/genny v0.0.0-20181203165245-fda8bcce96b1/go.mod h1:wpNSANu9UErftfiaAlz1pDZclrYzLtO5lALifODyjuM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181203201232-849d2c9534ea/go.mod h1:wpNSANu9UErftfiaAlz1pDZclrYzLtO5lALifODyjuM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181206121324-d6fb8a0dbe36/go.mod h1:wpNSANu9UErftfiaAlz1pDZclrYzLtO5lALifODyjuM=
|
||||
github.com/gobuffalo/genny v0.0.0-20181207164119-84844398a37d/go.mod h1:y0ysCHGGQf2T3vOhCrGHheYN54Y/REj0ayd0Suf4C/8=
|
||||
github.com/gobuffalo/github_flavored_markdown v1.0.4/go.mod h1:uRowCdK+q8d/RF0Kt3/DSalaIXbb0De/dmTqMQdkQ4I=
|
||||
github.com/gobuffalo/github_flavored_markdown v1.0.5/go.mod h1:U0643QShPF+OF2tJvYNiYDLDGDuQmJZXsf/bHOJPsMY=
|
||||
github.com/gobuffalo/github_flavored_markdown v1.0.7/go.mod h1:w93Pd9Lz6LvyQXEG6DktTPHkOtCbr+arAD5mkwMzXLI=
|
||||
github.com/gobuffalo/httptest v1.0.2/go.mod h1:7T1IbSrg60ankme0aDLVnEY0h056g9M1/ZvpVThtB7E=
|
||||
github.com/gobuffalo/licenser v0.0.0-20180924033006-eae28e638a42/go.mod h1:Ubo90Np8gpsSZqNScZZkVXXAo5DGhTb+WYFIjlnog8w=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181025145548-437d89de4f75/go.mod h1:x3lEpYxkRG/XtGCUNkio+6RZ/dlOvLzTI9M1auIwFcw=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181027200154-58051a75da95/go.mod h1:BzhaaxGd1tq1+OLKObzgdCV9kqVhbTulxOpYbvMQWS0=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181109171355-91a2a7aac9a7/go.mod h1:m+Ygox92pi9bdg+gVaycvqE8RVSjZp7mWw75+K5NPHk=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181128165715-cc7305f8abed/go.mod h1:oU9F9UCE+AzI/MueCKZamsezGOOHfSirltllOVeRTAE=
|
||||
github.com/gobuffalo/licenser v0.0.0-20181203160806-fe900bbede07/go.mod h1:ph6VDNvOzt1CdfaWC+9XwcBnlSTBz2j49PBwum6RFaU=
|
||||
github.com/gobuffalo/logger v0.0.0-20181022175615-46cfb361fc27/go.mod h1:8sQkgyhWipz1mIctHF4jTxmJh1Vxhp7mP8IqbljgJZo=
|
||||
github.com/gobuffalo/logger v0.0.0-20181027144941-73d08d2bb969/go.mod h1:7uGg2duHKpWnN4+YmyKBdLXfhopkAdVM6H3nKbyFbz8=
|
||||
github.com/gobuffalo/logger v0.0.0-20181027193913-9cf4dd0efe46/go.mod h1:7uGg2duHKpWnN4+YmyKBdLXfhopkAdVM6H3nKbyFbz8=
|
||||
github.com/gobuffalo/logger v0.0.0-20181109185836-3feeab578c17/go.mod h1:oNErH0xLe+utO+OW8ptXMSA5DkiSEDW1u3zGIt8F9Ew=
|
||||
github.com/gobuffalo/logger v0.0.0-20181117211126-8e9b89b7c264/go.mod h1:5etB91IE0uBlw9k756fVKZJdS+7M7ejVhmpXXiSFj0I=
|
||||
github.com/gobuffalo/logger v0.0.0-20181127160119-5b956e21995c/go.mod h1:+HxKANrR9VGw9yN3aOAppJKvhO05ctDi63w4mDnKv2U=
|
||||
github.com/gobuffalo/makr v1.1.5/go.mod h1:Y+o0btAH1kYAMDJW/TX3+oAXEu0bmSLLoC9mIFxtzOw=
|
||||
github.com/gobuffalo/mapi v1.0.0/go.mod h1:4VAGh89y6rVOvm5A8fKFxYG+wIW6LO1FMTG9hnKStFc=
|
||||
github.com/gobuffalo/mapi v1.0.1/go.mod h1:4VAGh89y6rVOvm5A8fKFxYG+wIW6LO1FMTG9hnKStFc=
|
||||
github.com/gobuffalo/meta v0.0.0-20181018155829-df62557efcd3/go.mod h1:XTTOhwMNryif3x9LkTTBO/Llrveezd71u3quLd0u7CM=
|
||||
github.com/gobuffalo/meta v0.0.0-20181018192820-8c6cef77dab3/go.mod h1:E94EPzx9NERGCY69UWlcj6Hipf2uK/vnfrF4QD0plVE=
|
||||
github.com/gobuffalo/meta v0.0.0-20181025145500-3a985a084b0a/go.mod h1:YDAKBud2FP7NZdruCSlmTmDOZbVSa6bpK7LJ/A/nlKg=
|
||||
github.com/gobuffalo/meta v0.0.0-20181114191255-b130ebedd2f7/go.mod h1:K6cRZ29ozr4Btvsqkjvg5nDFTLOgTqf03KA70Ks0ypE=
|
||||
github.com/gobuffalo/meta v0.0.0-20181127070345-0d7e59dd540b/go.mod h1:RLO7tMvE0IAKAM8wny1aN12pvEKn7EtkBLkUZR00Qf8=
|
||||
github.com/gobuffalo/mw-basicauth v1.0.3/go.mod h1:dg7+ilMZOKnQFHDefUzUHufNyTswVUviCBgF244C1+0=
|
||||
github.com/gobuffalo/mw-contenttype v0.0.0-20180802152300-74f5a47f4d56/go.mod h1:7EvcmzBbeCvFtQm5GqF9ys6QnCxz2UM1x0moiWLq1No=
|
||||
github.com/gobuffalo/mw-csrf v0.0.0-20180802151833-446ff26e108b/go.mod h1:sbGtb8DmDZuDUQoxjr8hG1ZbLtZboD9xsn6p77ppcHo=
|
||||
github.com/gobuffalo/mw-forcessl v0.0.0-20180802152810-73921ae7a130/go.mod h1:JvNHRj7bYNAMUr/5XMkZaDcw3jZhUZpsmzhd//FFWmQ=
|
||||
github.com/gobuffalo/mw-i18n v0.0.0-20180802152014-e3060b7e13d6/go.mod h1:91AQfukc52A6hdfIfkxzyr+kpVYDodgAeT5cjX1UIj4=
|
||||
github.com/gobuffalo/mw-paramlogger v0.0.0-20181005191442-d6ee392ec72e/go.mod h1:6OJr6VwSzgJMqWMj7TYmRUqzNe2LXu/W1rRW4MAz/ME=
|
||||
github.com/gobuffalo/mw-tokenauth v0.0.0-20181001105134-8545f626c189/go.mod h1:UqBF00IfKvd39ni5+yI5MLMjAf4gX7cDKN/26zDOD6c=
|
||||
github.com/gobuffalo/packd v0.0.0-20181027182251-01ad393492c8/go.mod h1:SmdBdhj6uhOsg1Ui4SFAyrhuc7U4VCildosO5IDJ3lc=
|
||||
github.com/gobuffalo/packd v0.0.0-20181027190505-aafc0d02c411/go.mod h1:SmdBdhj6uhOsg1Ui4SFAyrhuc7U4VCildosO5IDJ3lc=
|
||||
github.com/gobuffalo/packd v0.0.0-20181027194105-7ae579e6d213/go.mod h1:SmdBdhj6uhOsg1Ui4SFAyrhuc7U4VCildosO5IDJ3lc=
|
||||
github.com/gobuffalo/packd v0.0.0-20181031195726-c82734870264/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181104210303-d376b15f8e96/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181111195323-b2e760a5f0ff/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181114190715-f25c5d2471d7/go.mod h1:Yf2toFaISlyQrr5TfO3h6DB9pl9mZRmyvBGQb/aQ/pI=
|
||||
github.com/gobuffalo/packd v0.0.0-20181124090624-311c6248e5fb/go.mod h1:Foenia9ZvITEvG05ab6XpiD5EfBHPL8A6hush8SJ0o8=
|
||||
github.com/gobuffalo/packd v0.0.0-20181207120301-c49825f8f6f4/go.mod h1:LYc0TGKFBBFTRC9dg2pcRcMqGCTMD7T2BIMP7OBuQAA=
|
||||
github.com/gobuffalo/packr v1.13.7/go.mod h1:KkinLIn/n6+3tVXMwg6KkNvWwVsrRAz4ph+jgpk3Z24=
|
||||
github.com/gobuffalo/packr v1.15.0/go.mod h1:t5gXzEhIviQwVlNx/+3SfS07GS+cZ2hn76WLzPp6MGI=
|
||||
github.com/gobuffalo/packr v1.15.1/go.mod h1:IeqicJ7jm8182yrVmNbM6PR4g79SjN9tZLH8KduZZwE=
|
||||
github.com/gobuffalo/packr v1.19.0/go.mod h1:MstrNkfCQhd5o+Ct4IJ0skWlxN8emOq8DsoT1G98VIU=
|
||||
github.com/gobuffalo/packr v1.20.0/go.mod h1:JDytk1t2gP+my1ig7iI4NcVaXr886+N0ecUga6884zw=
|
||||
github.com/gobuffalo/packr v1.21.0/go.mod h1:H00jGfj1qFKxscFJSw8wcL4hpQtPe1PfU2wa6sg/SR0=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.8/go.mod h1:y60QCdzwuMwO2R49fdQhsjCPv7tLQFR0ayzxxla9zes=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.10/go.mod h1:4CWWn4I5T3v4c1OsJ55HbHlUEKNWMITG5iIkdr4Px4w=
|
||||
github.com/gobuffalo/packr/v2 v2.0.0-rc.11/go.mod h1:JoieH/3h3U4UmatmV93QmqyPUdf4wVM9HELaHEu+3fk=
|
||||
github.com/gobuffalo/plush v3.7.16+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.20+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.21+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.22+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.23+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.30+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plush v3.7.32+incompatible/go.mod h1:rQ4zdtUUyZNqULlc6bqd5scsPfLKfT0+TGMChgduDvI=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20181128164830-d29dcb966cb2/go.mod h1:r9QwptTFnuvSaSRjpSp4S2/4e2D3tJhARYbvEBcKSb4=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20181203163832-9fc4964505c2/go.mod h1:opEdT33AA2HdrIwK1aibqnTJDVVKXC02Bar/GT1YRVs=
|
||||
github.com/gobuffalo/plushgen v0.0.0-20181207152837-eedb135bd51b/go.mod h1:Lcw7HQbEVm09sAQrCLzIxuhFbB3nAgp4c55E+UlynR0=
|
||||
github.com/gobuffalo/pop v4.8.2+incompatible/go.mod h1:DwBz3SD5SsHpTZiTubcsFWcVDpJWGsxjVjMPnkiThWg=
|
||||
github.com/gobuffalo/pop v4.8.3+incompatible/go.mod h1:DwBz3SD5SsHpTZiTubcsFWcVDpJWGsxjVjMPnkiThWg=
|
||||
github.com/gobuffalo/pop v4.8.4+incompatible/go.mod h1:DwBz3SD5SsHpTZiTubcsFWcVDpJWGsxjVjMPnkiThWg=
|
||||
github.com/gobuffalo/release v1.0.35/go.mod h1:VtHFAKs61vO3wboCec5xr9JPTjYyWYcvaM3lclkc4x4=
|
||||
github.com/gobuffalo/release v1.0.38/go.mod h1:VtHFAKs61vO3wboCec5xr9JPTjYyWYcvaM3lclkc4x4=
|
||||
github.com/gobuffalo/release v1.0.42/go.mod h1:RPs7EtafH4oylgetOJpGP0yCZZUiO4vqHfTHJjSdpug=
|
||||
github.com/gobuffalo/release v1.0.52/go.mod h1:RPs7EtafH4oylgetOJpGP0yCZZUiO4vqHfTHJjSdpug=
|
||||
github.com/gobuffalo/release v1.0.53/go.mod h1:FdF257nd8rqhNaqtDWFGhxdJ/Ig4J7VcS3KL7n/a+aA=
|
||||
github.com/gobuffalo/release v1.0.54/go.mod h1:Pe5/RxRa/BE8whDpGfRqSI7D1a0evGK1T4JDm339tJc=
|
||||
github.com/gobuffalo/release v1.0.61/go.mod h1:mfIO38ujUNVDlBziIYqXquYfBF+8FDHUjKZgYC1Hj24=
|
||||
github.com/gobuffalo/release v1.0.72/go.mod h1:NP5NXgg/IX3M5XmHmWR99D687/3Dt9qZtTK/Lbwc1hU=
|
||||
github.com/gobuffalo/release v1.1.1/go.mod h1:Sluak1Xd6kcp6snkluR1jeXAogdJZpFFRzTYRs/2uwg=
|
||||
github.com/gobuffalo/shoulders v1.0.1/go.mod h1:V33CcVmaQ4gRUmHKwq1fiTXuf8Gp/qjQBUL5tHPmvbA=
|
||||
github.com/gobuffalo/syncx v0.0.0-20181120191700-98333ab04150/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw=
|
||||
github.com/gobuffalo/syncx v0.0.0-20181120194010-558ac7de985f/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw=
|
||||
github.com/gobuffalo/tags v2.0.11+incompatible/go.mod h1:9XmhOkyaB7UzvuY4UoZO4s67q8/xRMVJEaakauVQYeY=
|
||||
github.com/gobuffalo/tags v2.0.14+incompatible/go.mod h1:9XmhOkyaB7UzvuY4UoZO4s67q8/xRMVJEaakauVQYeY=
|
||||
github.com/gobuffalo/uuid v2.0.3+incompatible/go.mod h1:ErhIzkRhm0FtRuiE/PeORqcw4cVi1RtSpnwYrxuvkfE=
|
||||
github.com/gobuffalo/uuid v2.0.4+incompatible/go.mod h1:ErhIzkRhm0FtRuiE/PeORqcw4cVi1RtSpnwYrxuvkfE=
|
||||
github.com/gobuffalo/uuid v2.0.5+incompatible/go.mod h1:ErhIzkRhm0FtRuiE/PeORqcw4cVi1RtSpnwYrxuvkfE=
|
||||
github.com/gobuffalo/validate v2.0.3+incompatible/go.mod h1:N+EtDe0J8252BgfzQUChBgfd6L93m9weay53EWFVsMM=
|
||||
github.com/gobuffalo/x v0.0.0-20181003152136-452098b06085/go.mod h1:WevpGD+5YOreDJznWevcn8NTmQEW5STSBgIkpkjzqXc=
|
||||
github.com/gobuffalo/x v0.0.0-20181007152206-913e47c59ca7/go.mod h1:9rDPXaB3kXdKWzMc4odGQQdG2e2DIEmANy5aSJ9yesY=
|
||||
github.com/gofrs/uuid v3.1.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM=
|
||||
github.com/golang/protobuf v1.1.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg=
|
||||
github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
|
||||
github.com/gorilla/pat v0.0.0-20180118222023-199c85a7f6d1/go.mod h1:YeAe0gNeiNT5hoiZRI4yiOky6jVdNvfO2N6Kav/HmxY=
|
||||
github.com/gorilla/securecookie v1.1.1/go.mod h1:ra0sb63/xPlUeL+yeDciTfxMRAA+MP+HVt/4epWDjd4=
|
||||
github.com/gorilla/sessions v1.1.2/go.mod h1:8KCfur6+4Mqcc6S0FEfKuN15Vl5MgXW92AE8ovaJD0w=
|
||||
github.com/gorilla/sessions v1.1.3/go.mod h1:8KCfur6+4Mqcc6S0FEfKuN15Vl5MgXW92AE8ovaJD0w=
|
||||
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
|
||||
github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU=
|
||||
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
|
||||
github.com/jackc/fake v0.0.0-20150926172116-812a484cc733/go.mod h1:WrMFNQdiFJ80sQsxDoMokWK1W5TQtxBFNpzWTD84ibQ=
|
||||
github.com/jackc/pgx v3.2.0+incompatible/go.mod h1:0ZGrqGqkRlliWnWB4zKnWtjbSWbGkVEFm4TeybAXq+I=
|
||||
github.com/jmoiron/sqlx v0.0.0-20180614180643-0dae4fefe7c0/go.mod h1:IiEW3SEiiErVyFdH8NTuWjSifiEQKUoyK3LNqr2kCHU=
|
||||
github.com/joho/godotenv v1.2.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg=
|
||||
github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg=
|
||||
github.com/karrick/godirwalk v1.7.5/go.mod h1:2c9FRhkDxdIbgkOnCEvnSWs71Bhugbl46shStcFDJ34=
|
||||
github.com/karrick/godirwalk v1.7.7/go.mod h1:2c9FRhkDxdIbgkOnCEvnSWs71Bhugbl46shStcFDJ34=
|
||||
github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51/go.mod h1:CzGEWj7cYgsdH8dAjBGEr58BoE7ScuLd+fwFZ44+/x8=
|
||||
github.com/konsorten/go-windows-terminal-sequences v0.0.0-20180402223658-b729f2633dfe/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
|
||||
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
|
||||
github.com/kr/pty v1.1.3/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
|
||||
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
|
||||
github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
|
||||
github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
|
||||
github.com/markbates/deplist v1.0.4/go.mod h1:gRRbPbbuA8TmMiRvaOzUlRfzfjeCCBqX2A6arxN01MM=
|
||||
github.com/markbates/deplist v1.0.5/go.mod h1:gRRbPbbuA8TmMiRvaOzUlRfzfjeCCBqX2A6arxN01MM=
|
||||
github.com/markbates/going v1.0.2/go.mod h1:UWCk3zm0UKefHZ7l8BNqi26UyiEMniznk8naLdTcy6c=
|
||||
github.com/markbates/grift v1.0.4/go.mod h1:wbmtW74veyx+cgfwFhlnnMWqhoz55rnHR47oMXzsyVs=
|
||||
github.com/markbates/hmax v1.0.0/go.mod h1:cOkR9dktiESxIMu+65oc/r/bdY4bE8zZw3OLhLx0X2c=
|
||||
github.com/markbates/inflect v1.0.0/go.mod h1:oTeZL2KHA7CUX6X+fovmK9OvIOFuqu0TwdQrZjLTh88=
|
||||
github.com/markbates/inflect v1.0.1/go.mod h1:uv3UVNBe5qBIfCm8O8Q+DW+S1EopeyINj+Ikhc7rnCk=
|
||||
github.com/markbates/inflect v1.0.3/go.mod h1:1fR9+pO2KHEO9ZRtto13gDwwZaAKstQzferVeWqbgNs=
|
||||
github.com/markbates/inflect v1.0.4/go.mod h1:1fR9+pO2KHEO9ZRtto13gDwwZaAKstQzferVeWqbgNs=
|
||||
github.com/markbates/oncer v0.0.0-20180924031910-e862a676800b/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/oncer v0.0.0-20180924034138-723ad0170a46/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/oncer v0.0.0-20181014194634-05fccaae8fc4/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/oncer v0.0.0-20181203154359-bf2de49a0be2/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
github.com/markbates/refresh v1.4.10/go.mod h1:NDPHvotuZmTmesXxr95C9bjlw1/0frJwtME2dzcVKhc=
|
||||
github.com/markbates/safe v1.0.0/go.mod h1:nAqgmRi7cY2nqMc92/bSEeQA+R4OheNU2T1kNSCBdG0=
|
||||
github.com/markbates/safe v1.0.1/go.mod h1:nAqgmRi7cY2nqMc92/bSEeQA+R4OheNU2T1kNSCBdG0=
|
||||
github.com/markbates/sigtx v1.0.0/go.mod h1:QF1Hv6Ic6Ca6W+T+DL0Y/ypborFKyvUY9HmuCD4VeTc=
|
||||
github.com/markbates/willie v1.0.9/go.mod h1:fsrFVWl91+gXpx/6dv715j7i11fYPfZ9ZGfH0DQzY7w=
|
||||
github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU=
|
||||
github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
|
||||
github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc=
|
||||
github.com/microcosm-cc/bluemonday v1.0.1/go.mod h1:hsXNsILzKxV+sX77C5b8FSuKF00vh2OMYv+xgHpAMF4=
|
||||
github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
|
||||
github.com/mitchellh/mapstructure v1.0.0/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
|
||||
github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
|
||||
github.com/monoculum/formam v0.0.0-20180901015400-4e68be1d79ba/go.mod h1:RKgILGEJq24YyJ2ban8EO0RUVSJlF1pGsEvoLEACr/Q=
|
||||
github.com/nicksnyder/go-i18n v1.10.0/go.mod h1:HrK7VCrbOvQoUAQ7Vpy7i87N7JZZZ7R2xBGjv0j365Q=
|
||||
github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/gomega v1.4.1/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
|
||||
github.com/onsi/gomega v1.4.2/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
|
||||
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||
github.com/rogpeppe/go-internal v1.0.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
|
||||
github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0=
|
||||
github.com/serenize/snaker v0.0.0-20171204205717-a683aaf2d516/go.mod h1:Yow6lPLSAXx2ifx470yD/nUe22Dv5vBvxK/UK9UUTVs=
|
||||
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
|
||||
github.com/shopspring/decimal v0.0.0-20180709203117-cd690d0c9e24/go.mod h1:M+9NzErvs504Cn4c5DxATwIqPbtswREoFCre64PpcG4=
|
||||
github.com/shurcooL/go v0.0.0-20180423040247-9e1955d9fb6e/go.mod h1:TDJrrUr11Vxrven61rcy3hJMUqaf/CLWYhHNPmT14Lk=
|
||||
github.com/shurcooL/go-goon v0.0.0-20170922171312-37c2f522c041/go.mod h1:N5mDOmsrJOB+vfqUK+7DmDyjhSLIIBnXo9lvZJj3MWQ=
|
||||
github.com/shurcooL/highlight_diff v0.0.0-20170515013008-09bb4053de1b/go.mod h1:ZpfEhSmds4ytuByIcDnOLkTHGUI6KNqRNPDLHDk+mUU=
|
||||
github.com/shurcooL/highlight_go v0.0.0-20170515013102-78fb10f4a5f8/go.mod h1:UDKB5a1T23gOMUJrI+uSuH0VRDStOiUVSjBTRDVBVag=
|
||||
github.com/shurcooL/octicon v0.0.0-20180602230221-c42b0e3b24d9/go.mod h1:eWdoE5JD4R5UVWDucdOPg1g2fqQRq78IQa9zlOV1vpQ=
|
||||
github.com/shurcooL/sanitized_anchor_name v0.0.0-20170918181015-86672fcb3f95/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
|
||||
github.com/sirupsen/logrus v1.0.6/go.mod h1:pMByvHTf9Beacp5x1UXfOR9xyW/9antXMhjMPG0dEzc=
|
||||
github.com/sirupsen/logrus v1.1.0/go.mod h1:zrgwTnHtNr00buQ1vSptGe8m1f/BbgsPukg8qsT7A+A=
|
||||
github.com/sirupsen/logrus v1.1.1/go.mod h1:zrgwTnHtNr00buQ1vSptGe8m1f/BbgsPukg8qsT7A+A=
|
||||
github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
|
||||
github.com/sourcegraph/annotate v0.0.0-20160123013949-f4cad6c6324d/go.mod h1:UdhH50NIW0fCiwBSr0co2m7BnFLdv4fQTgdqdJTHFeE=
|
||||
github.com/sourcegraph/syntaxhighlight v0.0.0-20170531221838-bd320f5d308e/go.mod h1:HuIsMU8RRBOtsCgI77wP899iHVBQpCmg4ErYMZB+2IA=
|
||||
github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
|
||||
github.com/spf13/cast v1.2.0/go.mod h1:r2rcYCSwa1IExKTDiTfzaxqT2FNHs8hODu4LnUfgKEg=
|
||||
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
|
||||
github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
|
||||
github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
|
||||
github.com/spf13/pflag v1.0.2/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
|
||||
github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
|
||||
github.com/spf13/viper v1.2.1/go.mod h1:P4AexN0a+C9tGAnUFNwDMYYZv3pjFuvmeiMyKRaNVlI=
|
||||
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
|
||||
github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q=
|
||||
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
|
||||
github.com/unrolled/secure v0.0.0-20180918153822-f340ee86eb8b/go.mod h1:mnPT77IAdsi/kV7+Es7y+pXALeV3h7G6dQF6mNYjcLA=
|
||||
github.com/unrolled/secure v0.0.0-20181005190816-ff9db2ff917f/go.mod h1:mnPT77IAdsi/kV7+Es7y+pXALeV3h7G6dQF6mNYjcLA=
|
||||
golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20180910181607-0e37d006457b/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181001203147-e3636079e1a4/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181009213950-7c1a557ab941/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181015023909-0c41d7ab0a0e/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181024171144-74cb1d3d52f4/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181025113841-85e1b3f9139a/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181025213731-e84da0312774/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181106171534-e4dc69e5b2fd/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181112202954-3d3f9f413869/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181127143415-eb0de9b17e85/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180816102801-aaf60122140d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180921000356-2f5d2388922f/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180926154720-4dfa2610cdf3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181005035420-146acd28ed58/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181011144130-49bb7cea24b1/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181017193950-04a2e542c03f/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181102091132-c10e9556a7bc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181106065722-10aee1819953/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181207154023-610586996380/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sys v0.0.0-20180816055513-1c9583448a9c/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180906133057-8cf3aee42992/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180921163948-d47a0f339242/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180927150500-dad3d9fb7b6e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181005133103-4497e2df6f9e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181011152604-fa43e7bc11ba/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181022134430-8a28ead16f52/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181024145615-5cd93ef61a7c/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181025063200-d989b31c8746/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181026064943-731415f00dce/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181106135930-3a76605856fd/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181206074257-70b957f3b65e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181003024731-2f84ea8ef872/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181006002542-f60d9635b16a/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181008205924-a2b3f7f249e9/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181013182035-5e66757b835f/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181017214349-06f26fdaaa28/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181024171208-a2dc47679d30/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181026183834-f60e5f99f081/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181105230042-78dc5bac0cac/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181107215632-34b416bd17b3/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181114190951-94339b83286c/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181119130350-139d099f6620/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181127195227-b4e97c0ed882/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181127232545-e782529d0ddd/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181205224935-3576414c54a4/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181206194817-bcd4e47d0288/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
gopkg.in/airbrake/gobrake.v2 v2.0.9/go.mod h1:/h5ZAUhDkGaJfjzjKLSjv6zCL6O0LLBxU4K+aSYdM/U=
|
||||
gopkg.in/alexcesaro/quotedprintable.v3 v3.0.0-20150716171945-2caba252f4dc/go.mod h1:m7x9LTH6d71AHyAX77c9yqWCCa3UKHcVEj9y7hAtKDk=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
|
||||
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
|
||||
gopkg.in/gemnasium/logrus-airbrake-hook.v2 v2.1.2/go.mod h1:Xk6kEKp8OKb+X14hQBKWaSkCsqBpgog8nAV2xsGOxlo=
|
||||
gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df/go.mod h1:LRQQ+SO6ZHR7tOkpBDuZnXENFzX8qRjMDMyPD6BRkCw=
|
||||
gopkg.in/mail.v2 v2.0.0-20180731213649-a0242b2233b4/go.mod h1:htwXN1Qh09vZJ1NVKxQqHPBaCBbzKhp5GzuJEA4VJWw=
|
||||
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw=
|
||||
gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
109
vendor/github.com/gobuffalo/flect/ident.go
generated
vendored
Normal file
109
vendor/github.com/gobuffalo/flect/ident.go
generated
vendored
Normal file
@@ -0,0 +1,109 @@
|
||||
package flect
|
||||
|
||||
import (
|
||||
"encoding"
|
||||
"regexp"
|
||||
"strings"
|
||||
"unicode"
|
||||
"unicode/utf8"
|
||||
)
|
||||
|
||||
// Ident represents the string and it's parts
|
||||
type Ident struct {
|
||||
Original string
|
||||
Parts []string
|
||||
}
|
||||
|
||||
// String implements fmt.Stringer and returns the original string
|
||||
func (i Ident) String() string {
|
||||
return i.Original
|
||||
}
|
||||
|
||||
// New creates a new Ident from the string
|
||||
func New(s string) Ident {
|
||||
i := Ident{
|
||||
Original: s,
|
||||
Parts: toParts(s),
|
||||
}
|
||||
|
||||
return i
|
||||
}
|
||||
|
||||
var splitRx = regexp.MustCompile("[^\\p{L}]")
|
||||
|
||||
func toParts(s string) []string {
|
||||
parts := []string{}
|
||||
s = strings.TrimSpace(s)
|
||||
if len(s) == 0 {
|
||||
return parts
|
||||
}
|
||||
if _, ok := baseAcronyms[strings.ToUpper(s)]; ok {
|
||||
return []string{strings.ToUpper(s)}
|
||||
}
|
||||
var prev rune
|
||||
var x string
|
||||
for _, c := range s {
|
||||
cs := string(c)
|
||||
// fmt.Println("### cs ->", cs)
|
||||
// fmt.Println("### unicode.IsControl(c) ->", unicode.IsControl(c))
|
||||
// fmt.Println("### unicode.IsDigit(c) ->", unicode.IsDigit(c))
|
||||
// fmt.Println("### unicode.IsGraphic(c) ->", unicode.IsGraphic(c))
|
||||
// fmt.Println("### unicode.IsLetter(c) ->", unicode.IsLetter(c))
|
||||
// fmt.Println("### unicode.IsLower(c) ->", unicode.IsLower(c))
|
||||
// fmt.Println("### unicode.IsMark(c) ->", unicode.IsMark(c))
|
||||
// fmt.Println("### unicode.IsPrint(c) ->", unicode.IsPrint(c))
|
||||
// fmt.Println("### unicode.IsPunct(c) ->", unicode.IsPunct(c))
|
||||
// fmt.Println("### unicode.IsSpace(c) ->", unicode.IsSpace(c))
|
||||
// fmt.Println("### unicode.IsTitle(c) ->", unicode.IsTitle(c))
|
||||
// fmt.Println("### unicode.IsUpper(c) ->", unicode.IsUpper(c))
|
||||
if !utf8.ValidRune(c) {
|
||||
continue
|
||||
}
|
||||
|
||||
if isSpace(c) {
|
||||
parts = xappend(parts, x)
|
||||
x = cs
|
||||
prev = c
|
||||
continue
|
||||
}
|
||||
|
||||
if unicode.IsUpper(c) && !unicode.IsUpper(prev) {
|
||||
parts = xappend(parts, x)
|
||||
x = cs
|
||||
prev = c
|
||||
continue
|
||||
}
|
||||
if unicode.IsUpper(c) && baseAcronyms[strings.ToUpper(x)] {
|
||||
parts = xappend(parts, x)
|
||||
x = cs
|
||||
prev = c
|
||||
continue
|
||||
}
|
||||
if unicode.IsLetter(c) || unicode.IsDigit(c) || unicode.IsPunct(c) || c == '`' {
|
||||
prev = c
|
||||
x += cs
|
||||
continue
|
||||
}
|
||||
|
||||
parts = xappend(parts, x)
|
||||
x = ""
|
||||
prev = c
|
||||
}
|
||||
parts = xappend(parts, x)
|
||||
|
||||
return parts
|
||||
}
|
||||
|
||||
var _ encoding.TextUnmarshaler = &Ident{}
|
||||
var _ encoding.TextMarshaler = &Ident{}
|
||||
|
||||
//UnmarshalText unmarshalls byte array into the Ident
|
||||
func (i *Ident) UnmarshalText(data []byte) error {
|
||||
(*i) = New(string(data))
|
||||
return nil
|
||||
}
|
||||
|
||||
//MarshalText marshals Ident into byte array
|
||||
func (i Ident) MarshalText() ([]byte, error) {
|
||||
return []byte(i.Original), nil
|
||||
}
|
||||
13
vendor/github.com/gobuffalo/flect/lower_upper.go
generated
vendored
Normal file
13
vendor/github.com/gobuffalo/flect/lower_upper.go
generated
vendored
Normal file
@@ -0,0 +1,13 @@
|
||||
package flect
|
||||
|
||||
import "strings"
|
||||
|
||||
// ToUpper is a convience wrapper for strings.ToUpper
|
||||
func (i Ident) ToUpper() Ident {
|
||||
return New(strings.ToUpper(i.Original))
|
||||
}
|
||||
|
||||
// ToLower is a convience wrapper for strings.ToLower
|
||||
func (i Ident) ToLower() Ident {
|
||||
return New(strings.ToLower(i.Original))
|
||||
}
|
||||
24
vendor/github.com/gobuffalo/flect/name/char.go
generated
vendored
Normal file
24
vendor/github.com/gobuffalo/flect/name/char.go
generated
vendored
Normal file
@@ -0,0 +1,24 @@
|
||||
package name
|
||||
|
||||
import "unicode"
|
||||
|
||||
// Char returns the first letter, lowered
|
||||
// "" = "x"
|
||||
// "foo" = "f"
|
||||
// "123d456" = "d"
|
||||
func Char(s string) string {
|
||||
return New(s).Char().String()
|
||||
}
|
||||
|
||||
// Char returns the first letter, lowered
|
||||
// "" = "x"
|
||||
// "foo" = "f"
|
||||
// "123d456" = "d"
|
||||
func (i Ident) Char() Ident {
|
||||
for _, c := range i.Original {
|
||||
if unicode.IsLetter(c) {
|
||||
return New(string(unicode.ToLower(c)))
|
||||
}
|
||||
}
|
||||
return New("x")
|
||||
}
|
||||
28
vendor/github.com/gobuffalo/flect/name/file.go
generated
vendored
Normal file
28
vendor/github.com/gobuffalo/flect/name/file.go
generated
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
package name
|
||||
|
||||
import (
|
||||
"strings"
|
||||
|
||||
"github.com/gobuffalo/flect"
|
||||
)
|
||||
|
||||
// File creates a suitable file name
|
||||
// admin/widget = admin/widget
|
||||
// foo_bar = foo_bar
|
||||
// U$ser = u_ser
|
||||
func File(s string, exts ...string) string {
|
||||
return New(s).File(exts...).String()
|
||||
}
|
||||
|
||||
// File creates a suitable file name
|
||||
// admin/widget = admin/widget
|
||||
// foo_bar = foo_bar
|
||||
// U$ser = u_ser
|
||||
func (i Ident) File(exts ...string) Ident {
|
||||
var parts []string
|
||||
|
||||
for _, part := range strings.Split(i.Original, "/") {
|
||||
parts = append(parts, flect.Underscore(part))
|
||||
}
|
||||
return New(strings.Join(parts, "/") + strings.Join(exts, ""))
|
||||
}
|
||||
36
vendor/github.com/gobuffalo/flect/name/folder.go
generated
vendored
Normal file
36
vendor/github.com/gobuffalo/flect/name/folder.go
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
package name
|
||||
|
||||
import (
|
||||
"regexp"
|
||||
"strings"
|
||||
)
|
||||
|
||||
var alphanum = regexp.MustCompile("[^a-zA-Z0-9_\\-\\/]+")
|
||||
|
||||
// Folder creates a suitable folder name
|
||||
// admin/widget = admin/widget
|
||||
// foo_bar = foo_bar
|
||||
// U$ser = u_ser
|
||||
func Folder(s string, exts ...string) string {
|
||||
return New(s).Folder(exts...).String()
|
||||
}
|
||||
|
||||
// Folder creates a suitable folder name
|
||||
// admin/widget = admin/widget
|
||||
// foo_bar = foo/bar
|
||||
// U$ser = u/ser
|
||||
func (i Ident) Folder(exts ...string) Ident {
|
||||
var parts []string
|
||||
|
||||
s := i.Original
|
||||
if i.Pascalize().String() == s {
|
||||
s = i.Underscore().String()
|
||||
s = strings.Replace(s, "_", "/", -1)
|
||||
}
|
||||
for _, part := range strings.Split(s, "/") {
|
||||
part = strings.ToLower(part)
|
||||
part = alphanum.ReplaceAllString(part, "")
|
||||
parts = append(parts, part)
|
||||
}
|
||||
return New(strings.Join(parts, "/") + strings.Join(exts, ""))
|
||||
}
|
||||
13
vendor/github.com/gobuffalo/flect/name/ident.go
generated
vendored
Normal file
13
vendor/github.com/gobuffalo/flect/name/ident.go
generated
vendored
Normal file
@@ -0,0 +1,13 @@
|
||||
package name
|
||||
|
||||
import "github.com/gobuffalo/flect"
|
||||
|
||||
// Ident represents the string and it's parts
|
||||
type Ident struct {
|
||||
flect.Ident
|
||||
}
|
||||
|
||||
// New creates a new Ident from the string
|
||||
func New(s string) Ident {
|
||||
return Ident{flect.New(s)}
|
||||
}
|
||||
20
vendor/github.com/gobuffalo/flect/name/join.go
generated
vendored
Normal file
20
vendor/github.com/gobuffalo/flect/name/join.go
generated
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
package name
|
||||
|
||||
import "path/filepath"
|
||||
|
||||
func FilePathJoin(names ...string) string {
|
||||
var ni = make([]Ident, len(names))
|
||||
for i, n := range names {
|
||||
ni[i] = New(n)
|
||||
}
|
||||
base := New("")
|
||||
return base.FilePathJoin(ni...).String()
|
||||
}
|
||||
|
||||
func (i Ident) FilePathJoin(ni ...Ident) Ident {
|
||||
var s = make([]string, len(ni))
|
||||
for i, n := range ni {
|
||||
s[i] = n.OsPath().String()
|
||||
}
|
||||
return New(filepath.Join(s...))
|
||||
}
|
||||
14
vendor/github.com/gobuffalo/flect/name/key.go
generated
vendored
Normal file
14
vendor/github.com/gobuffalo/flect/name/key.go
generated
vendored
Normal file
@@ -0,0 +1,14 @@
|
||||
package name
|
||||
|
||||
import (
|
||||
"strings"
|
||||
)
|
||||
|
||||
func Key(s string) string {
|
||||
return New(s).Key().String()
|
||||
}
|
||||
|
||||
func (i Ident) Key() Ident {
|
||||
s := strings.Replace(i.String(), "\\", "/", -1)
|
||||
return New(strings.ToLower(s))
|
||||
}
|
||||
62
vendor/github.com/gobuffalo/flect/name/name.go
generated
vendored
Normal file
62
vendor/github.com/gobuffalo/flect/name/name.go
generated
vendored
Normal file
@@ -0,0 +1,62 @@
|
||||
package name
|
||||
|
||||
import (
|
||||
"encoding"
|
||||
"strings"
|
||||
|
||||
"github.com/gobuffalo/flect"
|
||||
)
|
||||
|
||||
// Proper pascalizes and singularizes the string
|
||||
// person = Person
|
||||
// foo_bar = FooBar
|
||||
// admin/widgets = AdminWidget
|
||||
func Proper(s string) string {
|
||||
return New(s).Proper().String()
|
||||
}
|
||||
|
||||
// Proper pascalizes and singularizes the string
|
||||
// person = Person
|
||||
// foo_bar = FooBar
|
||||
// admin/widgets = AdminWidget
|
||||
func (i Ident) Proper() Ident {
|
||||
return Ident{i.Singularize().Pascalize()}
|
||||
}
|
||||
|
||||
// Group pascalizes and pluralizes the string
|
||||
// person = People
|
||||
// foo_bar = FooBars
|
||||
// admin/widget = AdminWidgets
|
||||
func Group(s string) string {
|
||||
return New(s).Group().String()
|
||||
}
|
||||
|
||||
// Group pascalizes and pluralizes the string
|
||||
// person = People
|
||||
// foo_bar = FooBars
|
||||
// admin/widget = AdminWidgets
|
||||
func (i Ident) Group() Ident {
|
||||
var parts []string
|
||||
if len(i.Original) == 0 {
|
||||
return i
|
||||
}
|
||||
last := i.Parts[len(i.Parts)-1]
|
||||
for _, part := range i.Parts[:len(i.Parts)-1] {
|
||||
parts = append(parts, flect.Pascalize(part))
|
||||
}
|
||||
last = New(last).Pluralize().Pascalize().String()
|
||||
parts = append(parts, last)
|
||||
return New(strings.Join(parts, ""))
|
||||
}
|
||||
|
||||
var _ encoding.TextUnmarshaler = &Ident{}
|
||||
var _ encoding.TextMarshaler = &Ident{}
|
||||
|
||||
func (i *Ident) UnmarshalText(data []byte) error {
|
||||
(*i) = New(string(data))
|
||||
return nil
|
||||
}
|
||||
|
||||
func (i Ident) MarshalText() ([]byte, error) {
|
||||
return []byte(i.Original), nil
|
||||
}
|
||||
21
vendor/github.com/gobuffalo/flect/name/os_path.go
generated
vendored
Normal file
21
vendor/github.com/gobuffalo/flect/name/os_path.go
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
package name
|
||||
|
||||
import (
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
"strings"
|
||||
)
|
||||
|
||||
func OsPath(s string) string {
|
||||
return New(s).OsPath().String()
|
||||
}
|
||||
|
||||
func (i Ident) OsPath() Ident {
|
||||
s := i.String()
|
||||
if runtime.GOOS == "windows" {
|
||||
s = strings.Replace(s, "/", string(filepath.Separator), -1)
|
||||
} else {
|
||||
s = strings.Replace(s, "\\", string(filepath.Separator), -1)
|
||||
}
|
||||
return New(s)
|
||||
}
|
||||
35
vendor/github.com/gobuffalo/flect/name/package.go
generated
vendored
Normal file
35
vendor/github.com/gobuffalo/flect/name/package.go
generated
vendored
Normal file
@@ -0,0 +1,35 @@
|
||||
package name
|
||||
|
||||
import (
|
||||
"go/build"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
)
|
||||
|
||||
// Package will attempt to return a package version of the name
|
||||
// $GOPATH/src/foo/bar = foo/bar
|
||||
// $GOPATH\src\foo\bar = foo/bar
|
||||
// foo/bar = foo/bar
|
||||
func Package(s string) string {
|
||||
return New(s).Package().String()
|
||||
}
|
||||
|
||||
// Package will attempt to return a package version of the name
|
||||
// $GOPATH/src/foo/bar = foo/bar
|
||||
// $GOPATH\src\foo\bar = foo/bar
|
||||
// foo/bar = foo/bar
|
||||
func (i Ident) Package() Ident {
|
||||
c := build.Default
|
||||
|
||||
s := i.Original
|
||||
|
||||
for _, src := range c.SrcDirs() {
|
||||
s = strings.TrimPrefix(s, src)
|
||||
s = strings.TrimPrefix(s, filepath.Dir(src)) // encase there's no /src prefix
|
||||
}
|
||||
|
||||
s = strings.TrimPrefix(s, string(filepath.Separator))
|
||||
s = strings.Replace(s, "\\", "/", -1)
|
||||
s = strings.Replace(s, "_", "", -1)
|
||||
return Ident{New(s).ToLower()}
|
||||
}
|
||||
24
vendor/github.com/gobuffalo/flect/name/param_id.go
generated
vendored
Normal file
24
vendor/github.com/gobuffalo/flect/name/param_id.go
generated
vendored
Normal file
@@ -0,0 +1,24 @@
|
||||
package name
|
||||
|
||||
import "strings"
|
||||
|
||||
// ParamID returns the string as parameter with _id added
|
||||
// user = user_id
|
||||
// UserID = user_id
|
||||
// admin/widgets = admin_widgets_id
|
||||
func ParamID(s string) string {
|
||||
return New(s).ParamID().String()
|
||||
}
|
||||
|
||||
// ParamID returns the string as parameter with _id added
|
||||
// user = user_id
|
||||
// UserID = user_id
|
||||
// admin/widgets = admin_widget_id
|
||||
func (i Ident) ParamID() Ident {
|
||||
s := i.Singularize().Underscore().String()
|
||||
s = strings.ToLower(s)
|
||||
if strings.HasSuffix(s, "_id") {
|
||||
return New(s)
|
||||
}
|
||||
return New(s + "_id")
|
||||
}
|
||||
24
vendor/github.com/gobuffalo/flect/name/resource.go
generated
vendored
Normal file
24
vendor/github.com/gobuffalo/flect/name/resource.go
generated
vendored
Normal file
@@ -0,0 +1,24 @@
|
||||
package name
|
||||
|
||||
import (
|
||||
"strings"
|
||||
)
|
||||
|
||||
// Resource version of a name
|
||||
func (n Ident) Resource() Ident {
|
||||
name := n.Underscore().String()
|
||||
x := strings.FieldsFunc(name, func(r rune) bool {
|
||||
return r == '_' || r == '/'
|
||||
})
|
||||
|
||||
for i, w := range x {
|
||||
if i == len(x)-1 {
|
||||
x[i] = New(w).Pluralize().Pascalize().String()
|
||||
continue
|
||||
}
|
||||
|
||||
x[i] = New(w).Pascalize().String()
|
||||
}
|
||||
|
||||
return New(strings.Join(x, ""))
|
||||
}
|
||||
17
vendor/github.com/gobuffalo/flect/name/tablize.go
generated
vendored
Normal file
17
vendor/github.com/gobuffalo/flect/name/tablize.go
generated
vendored
Normal file
@@ -0,0 +1,17 @@
|
||||
package name
|
||||
|
||||
// Tableize returns an underscore, pluralized string
|
||||
// User = users
|
||||
// Person = persons
|
||||
// Admin/Widget = admin_widgets
|
||||
func Tableize(s string) string {
|
||||
return New(s).Tableize().String()
|
||||
}
|
||||
|
||||
// Tableize returns an underscore, pluralized string
|
||||
// User = users
|
||||
// Person = persons
|
||||
// Admin/Widget = admin_widgets
|
||||
func (i Ident) Tableize() Ident {
|
||||
return Ident{i.Pluralize().Underscore()}
|
||||
}
|
||||
5
vendor/github.com/gobuffalo/flect/name/url.go
generated
vendored
Normal file
5
vendor/github.com/gobuffalo/flect/name/url.go
generated
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
package name
|
||||
|
||||
func (n Ident) URL() Ident {
|
||||
return Ident{n.File().Pluralize()}
|
||||
}
|
||||
33
vendor/github.com/gobuffalo/flect/name/var_case.go
generated
vendored
Normal file
33
vendor/github.com/gobuffalo/flect/name/var_case.go
generated
vendored
Normal file
@@ -0,0 +1,33 @@
|
||||
package name
|
||||
|
||||
// VarCaseSingle version of a name.
|
||||
// foo_bar = fooBar
|
||||
// admin/widget = adminWidget
|
||||
// User = users
|
||||
func VarCaseSingle(s string) string {
|
||||
return New(s).VarCaseSingle().String()
|
||||
}
|
||||
|
||||
// VarCaseSingle version of a name.
|
||||
// foo_bar = fooBar
|
||||
// admin/widget = adminWidget
|
||||
// User = users
|
||||
func (i Ident) VarCaseSingle() Ident {
|
||||
return Ident{i.Group().Singularize().Camelize()}
|
||||
}
|
||||
|
||||
// VarCasePlural version of a name.
|
||||
// foo_bar = fooBars
|
||||
// admin/widget = adminWidgets
|
||||
// User = users
|
||||
func VarCasePlural(s string) string {
|
||||
return New(s).VarCasePlural().String()
|
||||
}
|
||||
|
||||
// VarCasePlural version of a name.
|
||||
// foo_bar = fooBars
|
||||
// admin/widget = adminWidgets
|
||||
// User = users
|
||||
func (i Ident) VarCasePlural() Ident {
|
||||
return Ident{i.Group().Pluralize().Camelize()}
|
||||
}
|
||||
43
vendor/github.com/gobuffalo/flect/ordinalize.go
generated
vendored
Normal file
43
vendor/github.com/gobuffalo/flect/ordinalize.go
generated
vendored
Normal file
@@ -0,0 +1,43 @@
|
||||
package flect
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"strconv"
|
||||
)
|
||||
|
||||
// Ordinalize converts a number to an ordinal version
|
||||
// 42 = 42nd
|
||||
// 45 = 45th
|
||||
// 1 = 1st
|
||||
func Ordinalize(s string) string {
|
||||
return New(s).Ordinalize().String()
|
||||
}
|
||||
|
||||
// Ordinalize converts a number to an ordinal version
|
||||
// 42 = 42nd
|
||||
// 45 = 45th
|
||||
// 1 = 1st
|
||||
func (i Ident) Ordinalize() Ident {
|
||||
number, err := strconv.Atoi(i.Original)
|
||||
if err != nil {
|
||||
return i
|
||||
}
|
||||
var s string
|
||||
switch abs(number) % 100 {
|
||||
case 11, 12, 13:
|
||||
s = fmt.Sprintf("%dth", number)
|
||||
default:
|
||||
switch abs(number) % 10 {
|
||||
case 1:
|
||||
s = fmt.Sprintf("%dst", number)
|
||||
case 2:
|
||||
s = fmt.Sprintf("%dnd", number)
|
||||
case 3:
|
||||
s = fmt.Sprintf("%drd", number)
|
||||
}
|
||||
}
|
||||
if s != "" {
|
||||
return New(s)
|
||||
}
|
||||
return New(fmt.Sprintf("%dth", number))
|
||||
}
|
||||
25
vendor/github.com/gobuffalo/flect/pascalize.go
generated
vendored
Normal file
25
vendor/github.com/gobuffalo/flect/pascalize.go
generated
vendored
Normal file
@@ -0,0 +1,25 @@
|
||||
package flect
|
||||
|
||||
import (
|
||||
"unicode"
|
||||
)
|
||||
|
||||
// Pascalize returns a string with each segment capitalized
|
||||
// user = User
|
||||
// bob dylan = BobDylan
|
||||
// widget_id = WidgetID
|
||||
func Pascalize(s string) string {
|
||||
return New(s).Pascalize().String()
|
||||
}
|
||||
|
||||
// Pascalize returns a string with each segment capitalized
|
||||
// user = User
|
||||
// bob dylan = BobDylan
|
||||
// widget_id = WidgetID
|
||||
func (i Ident) Pascalize() Ident {
|
||||
c := i.Camelize()
|
||||
if len(c.String()) == 0 {
|
||||
return c
|
||||
}
|
||||
return New(string(unicode.ToUpper(rune(c.Original[0]))) + c.Original[1:])
|
||||
}
|
||||
240
vendor/github.com/gobuffalo/flect/plural_rules.go
generated
vendored
Normal file
240
vendor/github.com/gobuffalo/flect/plural_rules.go
generated
vendored
Normal file
@@ -0,0 +1,240 @@
|
||||
package flect
|
||||
|
||||
var pluralRules = []rule{}
|
||||
|
||||
// AddPlural adds a rule that will replace the given suffix with the replacement suffix.
|
||||
func AddPlural(suffix string, repl string) {
|
||||
pluralMoot.Lock()
|
||||
defer pluralMoot.Unlock()
|
||||
pluralRules = append(pluralRules, rule{
|
||||
suffix: suffix,
|
||||
fn: func(s string) string {
|
||||
s = s[:len(s)-len(suffix)]
|
||||
return s + repl
|
||||
},
|
||||
})
|
||||
|
||||
pluralRules = append(pluralRules, rule{
|
||||
suffix: repl,
|
||||
fn: noop,
|
||||
})
|
||||
}
|
||||
|
||||
var singleToPlural = map[string]string{
|
||||
"human": "humans",
|
||||
"matrix": "matrices",
|
||||
"vertix": "vertices",
|
||||
"index": "indices",
|
||||
"mouse": "mice",
|
||||
"louse": "lice",
|
||||
"ress": "resses",
|
||||
"ox": "oxen",
|
||||
"quiz": "quizzes",
|
||||
"series": "series",
|
||||
"octopus": "octopi",
|
||||
"equipment": "equipment",
|
||||
"information": "information",
|
||||
"rice": "rice",
|
||||
"money": "money",
|
||||
"species": "species",
|
||||
"fish": "fish",
|
||||
"sheep": "sheep",
|
||||
"jeans": "jeans",
|
||||
"police": "police",
|
||||
"dear": "dear",
|
||||
"goose": "geese",
|
||||
"tooth": "teeth",
|
||||
"foot": "feet",
|
||||
"bus": "buses",
|
||||
"fez": "fezzes",
|
||||
"piano": "pianos",
|
||||
"halo": "halos",
|
||||
"photo": "photos",
|
||||
"aircraft": "aircraft",
|
||||
"alumna": "alumnae",
|
||||
"alumnus": "alumni",
|
||||
"analysis": "analyses",
|
||||
"antenna": "antennas",
|
||||
"antithesis": "antitheses",
|
||||
"apex": "apexes",
|
||||
"appendix": "appendices",
|
||||
"axis": "axes",
|
||||
"bacillus": "bacilli",
|
||||
"bacterium": "bacteria",
|
||||
"basis": "bases",
|
||||
"beau": "beaus",
|
||||
"bison": "bison",
|
||||
"bureau": "bureaus",
|
||||
"campus": "campuses",
|
||||
"château": "châteaux",
|
||||
"codex": "codices",
|
||||
"concerto": "concertos",
|
||||
"corpus": "corpora",
|
||||
"crisis": "crises",
|
||||
"curriculum": "curriculums",
|
||||
"deer": "deer",
|
||||
"diagnosis": "diagnoses",
|
||||
"die": "dice",
|
||||
"dwarf": "dwarves",
|
||||
"ellipsis": "ellipses",
|
||||
"erratum": "errata",
|
||||
"faux pas": "faux pas",
|
||||
"focus": "foci",
|
||||
"formula": "formulas",
|
||||
"fungus": "fungi",
|
||||
"genus": "genera",
|
||||
"graffito": "graffiti",
|
||||
"grouse": "grouse",
|
||||
"half": "halves",
|
||||
"hoof": "hooves",
|
||||
"hypothesis": "hypotheses",
|
||||
"larva": "larvae",
|
||||
"libretto": "librettos",
|
||||
"loaf": "loaves",
|
||||
"locus": "loci",
|
||||
"minutia": "minutiae",
|
||||
"moose": "moose",
|
||||
"nebula": "nebulae",
|
||||
"nucleus": "nuclei",
|
||||
"oasis": "oases",
|
||||
"offspring": "offspring",
|
||||
"opus": "opera",
|
||||
"parenthesis": "parentheses",
|
||||
"phenomenon": "phenomena",
|
||||
"phylum": "phyla",
|
||||
"prognosis": "prognoses",
|
||||
"radius": "radiuses",
|
||||
"referendum": "referendums",
|
||||
"salmon": "salmon",
|
||||
"shrimp": "shrimp",
|
||||
"stimulus": "stimuli",
|
||||
"stratum": "strata",
|
||||
"swine": "swine",
|
||||
"syllabus": "syllabi",
|
||||
"symposium": "symposiums",
|
||||
"synopsis": "synopses",
|
||||
"tableau": "tableaus",
|
||||
"thesis": "theses",
|
||||
"thief": "thieves",
|
||||
"trout": "trout",
|
||||
"tuna": "tuna",
|
||||
"vertebra": "vertebrae",
|
||||
"vita": "vitae",
|
||||
"vortex": "vortices",
|
||||
"wharf": "wharves",
|
||||
"wife": "wives",
|
||||
"wolf": "wolves",
|
||||
"datum": "data",
|
||||
"testis": "testes",
|
||||
"alias": "aliases",
|
||||
"house": "houses",
|
||||
"shoe": "shoes",
|
||||
"news": "news",
|
||||
"ovum": "ova",
|
||||
"foo": "foos",
|
||||
}
|
||||
|
||||
var pluralToSingle = map[string]string{}
|
||||
|
||||
func init() {
|
||||
for k, v := range singleToPlural {
|
||||
pluralToSingle[v] = k
|
||||
}
|
||||
}
|
||||
func init() {
|
||||
AddPlural("campus", "campuses")
|
||||
AddPlural("man", "men")
|
||||
AddPlural("tz", "tzes")
|
||||
AddPlural("alias", "aliases")
|
||||
AddPlural("oasis", "oasis")
|
||||
AddPlural("wife", "wives")
|
||||
AddPlural("basis", "basis")
|
||||
AddPlural("atum", "ata")
|
||||
AddPlural("adium", "adia")
|
||||
AddPlural("actus", "acti")
|
||||
AddPlural("irus", "iri")
|
||||
AddPlural("iterion", "iteria")
|
||||
AddPlural("dium", "diums")
|
||||
AddPlural("ovum", "ova")
|
||||
AddPlural("ize", "izes")
|
||||
AddPlural("dge", "dges")
|
||||
AddPlural("focus", "foci")
|
||||
AddPlural("child", "children")
|
||||
AddPlural("oaf", "oaves")
|
||||
AddPlural("randum", "randa")
|
||||
AddPlural("base", "bases")
|
||||
AddPlural("atus", "atuses")
|
||||
AddPlural("ode", "odes")
|
||||
AddPlural("person", "people")
|
||||
AddPlural("va", "vae")
|
||||
AddPlural("leus", "li")
|
||||
AddPlural("oot", "eet")
|
||||
AddPlural("oose", "eese")
|
||||
AddPlural("box", "boxes")
|
||||
AddPlural("ium", "ia")
|
||||
AddPlural("sis", "ses")
|
||||
AddPlural("nna", "nnas")
|
||||
AddPlural("eses", "esis")
|
||||
AddPlural("stis", "stes")
|
||||
AddPlural("ex", "ices")
|
||||
AddPlural("ula", "ulae")
|
||||
AddPlural("isis", "ises")
|
||||
AddPlural("ouses", "ouse")
|
||||
AddPlural("olves", "olf")
|
||||
AddPlural("lf", "lves")
|
||||
AddPlural("rf", "rves")
|
||||
AddPlural("afe", "aves")
|
||||
AddPlural("bfe", "bves")
|
||||
AddPlural("cfe", "cves")
|
||||
AddPlural("dfe", "dves")
|
||||
AddPlural("efe", "eves")
|
||||
AddPlural("gfe", "gves")
|
||||
AddPlural("hfe", "hves")
|
||||
AddPlural("ife", "ives")
|
||||
AddPlural("jfe", "jves")
|
||||
AddPlural("kfe", "kves")
|
||||
AddPlural("lfe", "lves")
|
||||
AddPlural("mfe", "mves")
|
||||
AddPlural("nfe", "nves")
|
||||
AddPlural("ofe", "oves")
|
||||
AddPlural("pfe", "pves")
|
||||
AddPlural("qfe", "qves")
|
||||
AddPlural("rfe", "rves")
|
||||
AddPlural("sfe", "sves")
|
||||
AddPlural("tfe", "tves")
|
||||
AddPlural("ufe", "uves")
|
||||
AddPlural("vfe", "vves")
|
||||
AddPlural("wfe", "wves")
|
||||
AddPlural("xfe", "xves")
|
||||
AddPlural("yfe", "yves")
|
||||
AddPlural("zfe", "zves")
|
||||
AddPlural("hive", "hives")
|
||||
AddPlural("quy", "quies")
|
||||
AddPlural("by", "bies")
|
||||
AddPlural("cy", "cies")
|
||||
AddPlural("dy", "dies")
|
||||
AddPlural("fy", "fies")
|
||||
AddPlural("gy", "gies")
|
||||
AddPlural("hy", "hies")
|
||||
AddPlural("jy", "jies")
|
||||
AddPlural("ky", "kies")
|
||||
AddPlural("ly", "lies")
|
||||
AddPlural("my", "mies")
|
||||
AddPlural("ny", "nies")
|
||||
AddPlural("py", "pies")
|
||||
AddPlural("qy", "qies")
|
||||
AddPlural("ry", "ries")
|
||||
AddPlural("sy", "sies")
|
||||
AddPlural("ty", "ties")
|
||||
AddPlural("vy", "vies")
|
||||
AddPlural("wy", "wies")
|
||||
AddPlural("xy", "xies")
|
||||
AddPlural("zy", "zies")
|
||||
AddPlural("x", "xes")
|
||||
AddPlural("ch", "ches")
|
||||
AddPlural("ss", "sses")
|
||||
AddPlural("sh", "shes")
|
||||
AddPlural("oe", "oes")
|
||||
AddPlural("io", "ios")
|
||||
AddPlural("o", "oes")
|
||||
}
|
||||
49
vendor/github.com/gobuffalo/flect/pluralize.go
generated
vendored
Normal file
49
vendor/github.com/gobuffalo/flect/pluralize.go
generated
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
package flect
|
||||
|
||||
import (
|
||||
"strings"
|
||||
"sync"
|
||||
)
|
||||
|
||||
var pluralMoot = &sync.RWMutex{}
|
||||
|
||||
// Pluralize returns a plural version of the string
|
||||
// user = users
|
||||
// person = people
|
||||
// datum = data
|
||||
func Pluralize(s string) string {
|
||||
return New(s).Pluralize().String()
|
||||
}
|
||||
|
||||
// Pluralize returns a plural version of the string
|
||||
// user = users
|
||||
// person = people
|
||||
// datum = data
|
||||
func (i Ident) Pluralize() Ident {
|
||||
s := i.Original
|
||||
if len(s) == 0 {
|
||||
return New("")
|
||||
}
|
||||
|
||||
pluralMoot.RLock()
|
||||
defer pluralMoot.RUnlock()
|
||||
|
||||
ls := strings.ToLower(s)
|
||||
if _, ok := pluralToSingle[ls]; ok {
|
||||
return i
|
||||
}
|
||||
if p, ok := singleToPlural[ls]; ok {
|
||||
return New(p)
|
||||
}
|
||||
for _, r := range pluralRules {
|
||||
if strings.HasSuffix(ls, r.suffix) {
|
||||
return New(r.fn(s))
|
||||
}
|
||||
}
|
||||
|
||||
if strings.HasSuffix(ls, "s") {
|
||||
return i
|
||||
}
|
||||
|
||||
return New(i.String() + "s")
|
||||
}
|
||||
10
vendor/github.com/gobuffalo/flect/rule.go
generated
vendored
Normal file
10
vendor/github.com/gobuffalo/flect/rule.go
generated
vendored
Normal file
@@ -0,0 +1,10 @@
|
||||
package flect
|
||||
|
||||
type ruleFn func(string) string
|
||||
|
||||
type rule struct {
|
||||
suffix string
|
||||
fn ruleFn
|
||||
}
|
||||
|
||||
func noop(s string) string { return s }
|
||||
122
vendor/github.com/gobuffalo/flect/singular_rules.go
generated
vendored
Normal file
122
vendor/github.com/gobuffalo/flect/singular_rules.go
generated
vendored
Normal file
@@ -0,0 +1,122 @@
|
||||
package flect
|
||||
|
||||
var singularRules = []rule{}
|
||||
|
||||
// AddSingular adds a rule that will replace the given suffix with the replacement suffix.
|
||||
func AddSingular(ext string, repl string) {
|
||||
singularMoot.Lock()
|
||||
defer singularMoot.Unlock()
|
||||
singularRules = append(singularRules, rule{
|
||||
suffix: ext,
|
||||
fn: func(s string) string {
|
||||
s = s[:len(s)-len(ext)]
|
||||
return s + repl
|
||||
},
|
||||
})
|
||||
|
||||
singularRules = append(singularRules, rule{
|
||||
suffix: repl,
|
||||
fn: func(s string) string {
|
||||
return s
|
||||
},
|
||||
})
|
||||
}
|
||||
|
||||
func init() {
|
||||
AddSingular("ria", "rion")
|
||||
AddSingular("news", "news")
|
||||
AddSingular("halves", "half")
|
||||
AddSingular("appendix", "appendix")
|
||||
AddSingular("zzes", "zz")
|
||||
AddSingular("ulas", "ula")
|
||||
AddSingular("psis", "pse")
|
||||
AddSingular("genus", "genera")
|
||||
AddSingular("phyla", "phylum")
|
||||
AddSingular("odice", "odex")
|
||||
AddSingular("oxen", "ox")
|
||||
AddSingular("ianos", "iano")
|
||||
AddSingular("ulus", "uli")
|
||||
AddSingular("mice", "mouse")
|
||||
AddSingular("ouses", "ouse")
|
||||
AddSingular("mni", "mnus")
|
||||
AddSingular("ocus", "oci")
|
||||
AddSingular("shoes", "shoe")
|
||||
AddSingular("oasis", "oasis")
|
||||
AddSingular("lice", "louse")
|
||||
AddSingular("men", "man")
|
||||
AddSingular("ta", "tum")
|
||||
AddSingular("ia", "ium")
|
||||
AddSingular("tives", "tive")
|
||||
AddSingular("ldren", "ld")
|
||||
AddSingular("people", "person")
|
||||
AddSingular("aves", "afe")
|
||||
AddSingular("uses", "us")
|
||||
AddSingular("bves", "bfe")
|
||||
AddSingular("cves", "cfe")
|
||||
AddSingular("dves", "dfe")
|
||||
AddSingular("eves", "efe")
|
||||
AddSingular("gves", "gfe")
|
||||
AddSingular("hves", "hfe")
|
||||
AddSingular("chives", "chive")
|
||||
AddSingular("ives", "ife")
|
||||
AddSingular("movies", "movie")
|
||||
AddSingular("jeans", "jeans")
|
||||
AddSingular("cesses", "cess")
|
||||
AddSingular("cess", "cess")
|
||||
AddSingular("acti", "actus")
|
||||
AddSingular("itzes", "itz")
|
||||
AddSingular("usses", "uss")
|
||||
AddSingular("uss", "uss")
|
||||
AddSingular("jves", "jfe")
|
||||
AddSingular("kves", "kfe")
|
||||
AddSingular("mves", "mfe")
|
||||
AddSingular("nves", "nfe")
|
||||
AddSingular("moves", "move")
|
||||
AddSingular("oves", "ofe")
|
||||
AddSingular("pves", "pfe")
|
||||
AddSingular("qves", "qfe")
|
||||
AddSingular("sves", "sfe")
|
||||
AddSingular("tves", "tfe")
|
||||
AddSingular("uves", "ufe")
|
||||
AddSingular("vves", "vfe")
|
||||
AddSingular("wves", "wfe")
|
||||
AddSingular("xves", "xfe")
|
||||
AddSingular("yves", "yfe")
|
||||
AddSingular("zves", "zfe")
|
||||
AddSingular("hives", "hive")
|
||||
AddSingular("lves", "lf")
|
||||
AddSingular("rves", "rf")
|
||||
AddSingular("quies", "quy")
|
||||
AddSingular("bies", "by")
|
||||
AddSingular("cies", "cy")
|
||||
AddSingular("dies", "dy")
|
||||
AddSingular("fies", "fy")
|
||||
AddSingular("gies", "gy")
|
||||
AddSingular("hies", "hy")
|
||||
AddSingular("jies", "jy")
|
||||
AddSingular("kies", "ky")
|
||||
AddSingular("lies", "ly")
|
||||
AddSingular("mies", "my")
|
||||
AddSingular("nies", "ny")
|
||||
AddSingular("pies", "py")
|
||||
AddSingular("qies", "qy")
|
||||
AddSingular("ries", "ry")
|
||||
AddSingular("sies", "sy")
|
||||
AddSingular("ties", "ty")
|
||||
AddSingular("vies", "vy")
|
||||
AddSingular("wies", "wy")
|
||||
AddSingular("xies", "xy")
|
||||
AddSingular("zies", "zy")
|
||||
AddSingular("xes", "x")
|
||||
AddSingular("ches", "ch")
|
||||
AddSingular("sses", "ss")
|
||||
AddSingular("shes", "sh")
|
||||
AddSingular("oes", "o")
|
||||
AddSingular("ress", "ress")
|
||||
AddSingular("iri", "irus")
|
||||
AddSingular("irus", "irus")
|
||||
AddSingular("tuses", "tus")
|
||||
AddSingular("tus", "tus")
|
||||
AddSingular("s", "")
|
||||
AddSingular("ss", "ss")
|
||||
}
|
||||
44
vendor/github.com/gobuffalo/flect/singularize.go
generated
vendored
Normal file
44
vendor/github.com/gobuffalo/flect/singularize.go
generated
vendored
Normal file
@@ -0,0 +1,44 @@
|
||||
package flect
|
||||
|
||||
import (
|
||||
"strings"
|
||||
"sync"
|
||||
)
|
||||
|
||||
var singularMoot = &sync.RWMutex{}
|
||||
|
||||
// Singularize returns a singular version of the string
|
||||
// users = user
|
||||
// data = datum
|
||||
// people = person
|
||||
func Singularize(s string) string {
|
||||
return New(s).Singularize().String()
|
||||
}
|
||||
|
||||
// Singularize returns a singular version of the string
|
||||
// users = user
|
||||
// data = datum
|
||||
// people = person
|
||||
func (i Ident) Singularize() Ident {
|
||||
s := i.Original
|
||||
if len(s) == 0 {
|
||||
return i
|
||||
}
|
||||
|
||||
singularMoot.RLock()
|
||||
defer singularMoot.RUnlock()
|
||||
ls := strings.ToLower(s)
|
||||
if p, ok := pluralToSingle[ls]; ok {
|
||||
return New(p)
|
||||
}
|
||||
if _, ok := singleToPlural[ls]; ok {
|
||||
return i
|
||||
}
|
||||
for _, r := range singularRules {
|
||||
if strings.HasSuffix(ls, r.suffix) {
|
||||
return New(r.fn(s))
|
||||
}
|
||||
}
|
||||
|
||||
return i
|
||||
}
|
||||
31
vendor/github.com/gobuffalo/flect/titleize.go
generated
vendored
Normal file
31
vendor/github.com/gobuffalo/flect/titleize.go
generated
vendored
Normal file
@@ -0,0 +1,31 @@
|
||||
package flect
|
||||
|
||||
import (
|
||||
"strings"
|
||||
"unicode"
|
||||
)
|
||||
|
||||
// Titleize will capitalize the start of each part
|
||||
// "Nice to see you!" = "Nice To See You!"
|
||||
// "i've read a book! have you?" = "I've Read A Book! Have You?"
|
||||
// "This is `code` ok" = "This Is `code` OK"
|
||||
func Titleize(s string) string {
|
||||
return New(s).Titleize().String()
|
||||
}
|
||||
|
||||
// Titleize will capitalize the start of each part
|
||||
// "Nice to see you!" = "Nice To See You!"
|
||||
// "i've read a book! have you?" = "I've Read A Book! Have You?"
|
||||
// "This is `code` ok" = "This Is `code` OK"
|
||||
func (i Ident) Titleize() Ident {
|
||||
var parts []string
|
||||
for _, part := range i.Parts {
|
||||
var x string
|
||||
x = string(unicode.ToTitle(rune(part[0])))
|
||||
if len(part) > 1 {
|
||||
x += part[1:]
|
||||
}
|
||||
parts = append(parts, x)
|
||||
}
|
||||
return New(strings.Join(parts, " "))
|
||||
}
|
||||
34
vendor/github.com/gobuffalo/flect/underscore.go
generated
vendored
Normal file
34
vendor/github.com/gobuffalo/flect/underscore.go
generated
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
package flect
|
||||
|
||||
import (
|
||||
"strings"
|
||||
"unicode"
|
||||
)
|
||||
|
||||
// Underscore a string
|
||||
// bob dylan = bob_dylan
|
||||
// Nice to see you! = nice_to_see_you
|
||||
// widgetID = widget_id
|
||||
func Underscore(s string) string {
|
||||
return New(s).Underscore().String()
|
||||
}
|
||||
|
||||
// Underscore a string
|
||||
// bob dylan = bob_dylan
|
||||
// Nice to see you! = nice_to_see_you
|
||||
// widgetID = widget_id
|
||||
func (i Ident) Underscore() Ident {
|
||||
var out []string
|
||||
for _, part := range i.Parts {
|
||||
var x string
|
||||
for _, c := range part {
|
||||
if unicode.IsLetter(c) || unicode.IsDigit(c) {
|
||||
x += string(c)
|
||||
}
|
||||
}
|
||||
if x != "" {
|
||||
out = append(out, x)
|
||||
}
|
||||
}
|
||||
return New(strings.ToLower(strings.Join(out, "_")))
|
||||
}
|
||||
4
vendor/github.com/gobuffalo/flect/version.go
generated
vendored
Normal file
4
vendor/github.com/gobuffalo/flect/version.go
generated
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
package flect
|
||||
|
||||
//Version holds Flect version number
|
||||
const Version = "v0.0.1"
|
||||
14
vendor/github.com/gobuffalo/genny/.codeclimate.yml
generated
vendored
Normal file
14
vendor/github.com/gobuffalo/genny/.codeclimate.yml
generated
vendored
Normal file
@@ -0,0 +1,14 @@
|
||||
---
|
||||
version: "2"
|
||||
plugins:
|
||||
golint:
|
||||
enabled: true
|
||||
checks:
|
||||
GoLint/Naming/MixedCaps:
|
||||
enabled: false
|
||||
govet:
|
||||
enabled: true
|
||||
gofmt:
|
||||
enabled: true
|
||||
fixme:
|
||||
enabled: true
|
||||
29
vendor/github.com/gobuffalo/genny/.gitignore
generated
vendored
Normal file
29
vendor/github.com/gobuffalo/genny/.gitignore
generated
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
*.log
|
||||
.DS_Store
|
||||
doc
|
||||
tmp
|
||||
pkg
|
||||
*.gem
|
||||
*.pid
|
||||
coverage
|
||||
coverage.data
|
||||
build/*
|
||||
*.pbxuser
|
||||
*.mode1v3
|
||||
.svn
|
||||
profile
|
||||
.console_history
|
||||
.sass-cache/*
|
||||
.rake_tasks~
|
||||
*.log.lck
|
||||
solr/
|
||||
.jhw-cache/
|
||||
jhw.*
|
||||
*.sublime*
|
||||
node_modules/
|
||||
dist/
|
||||
generated/
|
||||
.vendor/
|
||||
bin/*
|
||||
gin-bin
|
||||
.idea/
|
||||
3
vendor/github.com/gobuffalo/genny/.gometalinter.json
generated
vendored
Normal file
3
vendor/github.com/gobuffalo/genny/.gometalinter.json
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"Enable": ["vet", "golint", "goimports", "deadcode", "gotype", "ineffassign", "misspell", "nakedret", "unconvert", "megacheck", "varcheck"]
|
||||
}
|
||||
28
vendor/github.com/gobuffalo/genny/.goreleaser.yml
generated
vendored
Normal file
28
vendor/github.com/gobuffalo/genny/.goreleaser.yml
generated
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
builds:
|
||||
-
|
||||
goos:
|
||||
- darwin
|
||||
- linux
|
||||
- windows
|
||||
env:
|
||||
- CGO_ENABLED=0
|
||||
# main: ./genny/main.go
|
||||
# binary: {{.Binary}}
|
||||
# hooks:
|
||||
# pre: packr
|
||||
# post: packr clean
|
||||
|
||||
checksum:
|
||||
name_template: 'checksums.txt'
|
||||
snapshot:
|
||||
name_template: "{{ .Tag }}-next"
|
||||
changelog:
|
||||
sort: asc
|
||||
filters:
|
||||
exclude:
|
||||
- '^docs:'
|
||||
- '^test:'
|
||||
brew:
|
||||
github:
|
||||
owner: markbates
|
||||
name: homebrew-tap
|
||||
36
vendor/github.com/gobuffalo/genny/.travis.yml
generated
vendored
Normal file
36
vendor/github.com/gobuffalo/genny/.travis.yml
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
language: go
|
||||
|
||||
sudo: false
|
||||
|
||||
matrix:
|
||||
include:
|
||||
- os: linux
|
||||
go: "1.9.x"
|
||||
- os: windows
|
||||
go: "1.9.x"
|
||||
- os: linux
|
||||
go: "1.10.x"
|
||||
- os: windows
|
||||
go: "1.10.x"
|
||||
- os: linux
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=off
|
||||
- os: windows
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=off
|
||||
- os: linux
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=on
|
||||
- os: windows
|
||||
go: "1.11.x"
|
||||
env:
|
||||
- GO111MODULE=on
|
||||
|
||||
install: false
|
||||
|
||||
script:
|
||||
- go get -v -t ./...
|
||||
- go test -v -timeout=5s -race ./...
|
||||
8
vendor/github.com/gobuffalo/genny/LICENSE.txt
generated
vendored
Normal file
8
vendor/github.com/gobuffalo/genny/LICENSE.txt
generated
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
The MIT License (MIT)
|
||||
Copyright (c) 2018 Mark Bates
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
53
vendor/github.com/gobuffalo/genny/Makefile
generated
vendored
Normal file
53
vendor/github.com/gobuffalo/genny/Makefile
generated
vendored
Normal file
@@ -0,0 +1,53 @@
|
||||
TAGS ?= "sqlite"
|
||||
GO_BIN ?= go
|
||||
|
||||
install:
|
||||
packr2
|
||||
$(GO_BIN) install -v ./genny
|
||||
|
||||
tidy:
|
||||
ifeq ($(GO111MODULE),on)
|
||||
$(GO_BIN) mod tidy
|
||||
else
|
||||
echo skipping go mod tidy
|
||||
endif
|
||||
|
||||
deps:
|
||||
$(GO_BIN) get github.com/gobuffalo/release
|
||||
$(GO_BIN) get github.com/gobuffalo/packr/v2/packr2
|
||||
$(GO_BIN) get -tags ${TAGS} -t ./...
|
||||
make tidy
|
||||
|
||||
build:
|
||||
packr2
|
||||
$(GO_BIN) build -v .
|
||||
make tidy
|
||||
|
||||
test:
|
||||
packr2
|
||||
$(GO_BIN) test -tags ${TAGS} ./...
|
||||
make tidy
|
||||
|
||||
ci-test:
|
||||
$(GO_BIN) test -tags ${TAGS} -race ./...
|
||||
make tidy
|
||||
|
||||
lint:
|
||||
gometalinter --vendor ./... --deadline=1m --skip=internal
|
||||
|
||||
update:
|
||||
packr2 clean
|
||||
$(GO_BIN) get -u -tags ${TAGS}
|
||||
make tidy
|
||||
packr2
|
||||
make test
|
||||
make install
|
||||
make tidy
|
||||
|
||||
release-test:
|
||||
$(GO_BIN) test -tags ${TAGS} -race ./...
|
||||
|
||||
release:
|
||||
make tidy
|
||||
release -y -f version.go
|
||||
make tidy
|
||||
495
vendor/github.com/gobuffalo/genny/README.md
generated
vendored
Normal file
495
vendor/github.com/gobuffalo/genny/README.md
generated
vendored
Normal file
@@ -0,0 +1,495 @@
|
||||
<p align="center"><img src="https://github.com/gobuffalo/buffalo/blob/master/logo.svg" width="360"></p>
|
||||
|
||||
<p align="center">
|
||||
<a href="https://godoc.org/github.com/gobuffalo/genny"><img src="https://godoc.org/github.com/gobuffalo/genny?status.svg" alt="GoDoc" /></a>
|
||||
<a href="https://travis-ci.org/gobuffalo/genny"><img src="https://travis-ci.org/gobuffalo/genny.svg?branch=master" alt="Build Status" /></a>
|
||||
<a href="https://goreportcard.com/report/github.com/gobuffalo/genny"><img src="https://goreportcard.com/badge/github.com/gobuffalo/genny" alt="Go Report Card" /></a>
|
||||
</p>
|
||||
|
||||
# Genny
|
||||
|
||||
## What Is Genny?
|
||||
|
||||
Genny is a _framework_ for writing modular generators, it however, doesn't actually generate anything. It just makes it easier for you to. :)
|
||||
|
||||
## Core Concepts
|
||||
|
||||
### Generators
|
||||
|
||||
A [`github.com/gobuffalo/genny#Generator`](https://godoc.org/github.com/gobuffalo/genny#Generator) is used to build a blue print of what you want to generate.
|
||||
|
||||
A few of things that can be added to a `Generator` are:
|
||||
|
||||
* [`github.com/gobuffalo/genny#File`](https://godoc.org/github.com/gobuffalo/genny#File)
|
||||
* [`os/exec#Cmd`](https://godoc.org/os/exec#Cmd)
|
||||
* [`github.com/gobuffalo/packd#Box`](https://godoc.org/github.com/gobuffalo/packd#Box)
|
||||
* [`net/http#Request`](https://godoc.org/net/http#Request)
|
||||
* and more
|
||||
|
||||
A [`github.com/gobuffalo/genny#Generator`](https://godoc.org/github.com/gobuffalo/genny#Generator) does *not* actually generate anything; a [`github.com/gobuffalo/genny#Runner`](https://godoc.org/github.com/gobuffalo/genny#Runner) is needed to run the generator.
|
||||
|
||||
```go
|
||||
g := genny.New()
|
||||
|
||||
// add a file
|
||||
g.File(genny.NewFileS("index.html", "Hello\n"))
|
||||
|
||||
// execute a command
|
||||
g.Command(exec.Command("go", "env"))
|
||||
|
||||
// run a function at run time
|
||||
g.RunFn(func(r *genny.Runner) error {
|
||||
// look for the `genny` executable
|
||||
if _, err := r.LookPath("genny"); err != nil {
|
||||
// it wasn't found, so install it
|
||||
if err := gotools.Get("github.com/gobuffalo/genny/genny")(r); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
// call the `genny` executable with the `-h` flag.
|
||||
return r.Exec(exec.Command("genny", "-h"))
|
||||
})
|
||||
```
|
||||
|
||||
When a [`github.com/gobuffalo/genny#Generator`](https://godoc.org/github.com/gobuffalo/genny#Generator) is run each item that was added to it will be run in FIFO order. In the above example this means the following will happen:
|
||||
|
||||
1. Create a new file `r.Root/index.html`
|
||||
1. Run the command `go env`
|
||||
1. Run a function that installs `genny`
|
||||
|
||||
#### Runtime Checks
|
||||
|
||||
Genny has two different components; the "generator" (or blueprint) and the "runner" which executes the generator. Often it is necessary to only run certain code when the generator is run, not built. For example, checking the existing of an executable and installing it if missing.
|
||||
|
||||
In these situations you will want to use a [`github.com/gobuffalo/genny#RunFn`](https://godoc.org/github.com/gobuffalo/genny#RunFn) function.
|
||||
|
||||
In this example at runtime the `RunFn` will be called given the `*Runner` that is calling it. When called the function will ask the [`github.com/gobuffalo/genny#Runner.LookPath`](https://godoc.org/github.com/gobuffalo/genny#Runner.LookPath) function to ask the location of the `genny` executable.
|
||||
|
||||
In [`github.com/gobuffalo/genny#DryRunner`](https://godoc.org/github.com/gobuffalo/genny#DryRunner) this will simply echo back the name of the executable that has been asked for, in this case `return "genny", nil`.
|
||||
|
||||
In [`github.com/gobuffalo/genny#WetRunner`](https://godoc.org/github.com/gobuffalo/genny#WetRunner) this will call the [`os/exec#LookPath`](https://godoc.org/os/exec#LookPath) and return its results.
|
||||
|
||||
If the `genny` binary is not found, it will attempt to install it. Should that succeed the method returns the execution of a call to `genny -h`.
|
||||
|
||||
```go
|
||||
g.RunFn(func(r *genny.Runner) error {
|
||||
// look for the `genny` executable
|
||||
if _, err := r.LookPath("genny"); err != nil {
|
||||
// it wasn't found, so install it
|
||||
if err := gotools.Get("github.com/gobuffalo/genny/genny")(r); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
// call the `genny` executable with the `-h` flag.
|
||||
return r.Exec(exec.Command("genny", "-h"))
|
||||
})
|
||||
```
|
||||
|
||||
The flexibility of the `*Fn` functions, combined with [`github.com/gobuffalo/genny#RunFn`](https://godoc.org/github.com/gobuffalo/genny#RunFn) make for a powerful testing combination.
|
||||
|
||||
### Runners
|
||||
|
||||
A [`github.com/gobuffalo/genny#Runner`](https://godoc.org/github.com/gobuffalo/genny#Runner) is used to run generators and control the environment in which those generators are run.
|
||||
|
||||
Genny ships with three implementations of `Runner` that cover _most_ situations. They can also provide good starting points for customized implementations of `Runner`.
|
||||
|
||||
* [`github.com/gobuffalo/genny#DryRunner`](https://godoc.org/github.com/gobuffalo/genny#DryRunner)
|
||||
* [`github.com/gobuffalo/genny#WetRunner`](https://godoc.org/github.com/gobuffalo/genny#WetRunner)
|
||||
* [`github.com/gobuffalo/genny/gentest#NewRunner`](https://godoc.org/github.com/gobuffalo/genny/gentest#NewRunner)
|
||||
|
||||
#### Adding Generators
|
||||
|
||||
To add a [`github.com/gobuffalo/genny#Generator`](https://godoc.org/github.com/gobuffalo/genny#Generator) to a [`github.com/gobuffalo/genny#Runner`](https://godoc.org/github.com/gobuffalo/genny#Runner) the [`github.com/gobuffalo/genny#Runner.With`](https://godoc.org/github.com/gobuffalo/genny#Runner.With) function can be used.
|
||||
|
||||
```go
|
||||
run := genny.DryRunner(context.Background())
|
||||
|
||||
// add a generator from the `simple` package
|
||||
g := simple.New()
|
||||
run.With(g)
|
||||
|
||||
// add a generator from the `notsimple` package
|
||||
g := notsimple.New()
|
||||
run.With(g)
|
||||
```
|
||||
|
||||
Each [`github.com/gobuffalo/genny#Generator`](https://godoc.org/github.com/gobuffalo/genny#Generator) is run in FIFO order in which it was added to the [`github.com/gobuffalo/genny#Runner`](https://godoc.org/github.com/gobuffalo/genny#Runner).
|
||||
|
||||
It is common to have a function that builds a new [`github.com/gobuffalo/genny#Generator`](https://godoc.org/github.com/gobuffalo/genny#Generator) or returns an `error` if there was a problem.
|
||||
|
||||
```go
|
||||
func New() (*genny.Generator, error) {
|
||||
g := simple.New()
|
||||
// do work which might error
|
||||
return g, nil
|
||||
}
|
||||
```
|
||||
|
||||
The [`github.com/gobuffalo/genny#Runner.WithNew`](https://godoc.org/github.com/gobuffalo/genny#Runner.WithNew) function was designed to make adding a [`github.com/gobuffalo/genny#Generator`](https://godoc.org/github.com/gobuffalo/genny#Generator) with this return argument signature easier.
|
||||
|
||||
```go
|
||||
if err := run.WithNew(New()); err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
```
|
||||
|
||||
#### Dry Running (**NON-DESTRUCTIVE**)
|
||||
|
||||
The idea of "dry" running means that no commands are executed, no files are written to disk, no HTTP requests are made, etc... Instead these steps are run "dry", which in the case of [`github.com/gobuffalo/genny#DryRunner`](https://godoc.org/github.com/gobuffalo/genny#DryRunner) is the case.
|
||||
|
||||
```go
|
||||
func main() {
|
||||
run := genny.DryRunner(context.Background())
|
||||
|
||||
g := simple.New()
|
||||
run.With(g)
|
||||
|
||||
if err := run.Run(); err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
```plain
|
||||
// output
|
||||
DEBU[2018-12-06T15:13:47-05:00] Step: 4eac628c
|
||||
DEBU[2018-12-06T15:13:47-05:00] Chdir: /go/src/github.com/gobuffalo/genny/internal/_examples/dry
|
||||
DEBU[2018-12-06T15:13:47-05:00] File: /go/src/github.com/gobuffalo/genny/internal/_examples/dry/index.html
|
||||
DEBU[2018-12-06T15:13:47-05:00] Exec: go env
|
||||
DEBU[2018-12-06T15:13:47-05:00] LookPath: genny
|
||||
DEBU[2018-12-06T15:13:47-05:00] Exec: genny -h
|
||||
```
|
||||
|
||||
```bash
|
||||
// file list
|
||||
.
|
||||
└── main.go
|
||||
|
||||
0 directories, 1 file
|
||||
```
|
||||
|
||||
Using a "dry" runner can make testing easier when you don't have to worry about commands running, files being written, etc... It can also make it easy to provide a "dry-run" flag to your generators to let people see what will be generated when the generator is run for real.
|
||||
|
||||
#### Wet Running (**DESTRUCTIVE**)
|
||||
|
||||
While "dry" means to not execute commands or write files, "wet" running means the exact opposite; it will write files and execute commands.
|
||||
|
||||
Use the [`github.com/gobuffalo/genny#WetRunner`](https://godoc.org/github.com/gobuffalo/genny#WetRunner) when "wet" running is the desired outcome.
|
||||
|
||||
```go
|
||||
func main() {
|
||||
run := genny.WetRunner(context.Background())
|
||||
|
||||
g := simple.New()
|
||||
run.With(g)
|
||||
|
||||
if err := run.Run(); err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
```plain
|
||||
GOARCH="amd64"
|
||||
GOBIN=""
|
||||
// ...
|
||||
A brief description of your application
|
||||
|
||||
Usage:
|
||||
genny [command]
|
||||
|
||||
Available Commands:
|
||||
help Help about any command
|
||||
new generates a new genny stub
|
||||
|
||||
Flags:
|
||||
-h, --help help for genny
|
||||
|
||||
Use "genny [command] --help" for more information about a command.
|
||||
```
|
||||
|
||||
```bash
|
||||
// file list
|
||||
.
|
||||
├── index.html
|
||||
└── main.go
|
||||
|
||||
0 directories, 2 files
|
||||
```
|
||||
|
||||
```bash
|
||||
$ cat index.html
|
||||
|
||||
Hello
|
||||
```
|
||||
|
||||
#### Changing Runner Behavior
|
||||
|
||||
The change the way [`github.com/gobuffalo/genny#DryRunner`](https://godoc.org/github.com/gobuffalo/genny#DryRunner) or [`github.com/gobuffalo/genny#WetRunner`](https://godoc.org/github.com/gobuffalo/genny#WetRunner) work, or to build your own [`github.com/gobuffalo/genny#Runner`](https://godoc.org/github.com/gobuffalo/genny#Runner) you need to implement the `*Fn` attributes on the [`github.com/gobuffalo/genny#Runner`](https://godoc.org/github.com/gobuffalo/genny#Runner).
|
||||
|
||||
```go
|
||||
type Runner struct {
|
||||
// ...
|
||||
ExecFn func(*exec.Cmd) error // function to use when executing files
|
||||
FileFn func(File) (File, error) // function to use when writing files
|
||||
ChdirFn func(string, func() error) error // function to use when changing directories
|
||||
DeleteFn func(string) error // function used to delete files/folders
|
||||
RequestFn func(*http.Request, *http.Client) (*http.Response, error) // function used to make http requests
|
||||
LookPathFn func(string) (string, error) // function used to make exec.LookPath lookups
|
||||
// ...
|
||||
}
|
||||
```
|
||||
|
||||
These `*Fn` functions represent the **FINAL** end-point for the that is trying to be run.
|
||||
|
||||
Here are two implementations of the [`github.com/gobuffalo/genny#Runner.FileFn`](https://godoc.org/github.com/gobuffalo/genny#Runner.FileFn) function.
|
||||
|
||||
The first will result in the file being printed to the screen. The second implementation writes the file to disk.
|
||||
|
||||
```go
|
||||
run.FileFn = func(f packd.SimpleFile) (packd.SimpleFile, error) {
|
||||
io.Copy(os.Stdout, f)
|
||||
return f, nil
|
||||
}
|
||||
|
||||
run.FileFn = func(f genny.File) (genny.File, error) {
|
||||
if d, ok := f.(genny.Dir); ok {
|
||||
if err := os.MkdirAll(d.Name(), d.Perm); err != nil {
|
||||
return f, err
|
||||
}
|
||||
return d, nil
|
||||
}
|
||||
|
||||
name := f.Name()
|
||||
if !filepath.IsAbs(name) {
|
||||
name = filepath.Join(run.Root, name)
|
||||
}
|
||||
dir := filepath.Dir(name)
|
||||
if err := os.MkdirAll(dir, 0755); err != nil {
|
||||
return f, err
|
||||
}
|
||||
ff, err := os.Create(name)
|
||||
if err != nil {
|
||||
return f, err
|
||||
}
|
||||
defer ff.Close()
|
||||
if _, err := io.Copy(ff, f); err != nil {
|
||||
return f, err
|
||||
}
|
||||
return f, nil
|
||||
}
|
||||
```
|
||||
|
||||
### Files
|
||||
|
||||
Working with files, both creating new ones as well as, existing ones, is a core component of writing a generator. Genny understands this and offers several ways of working with files that is flexible and helps to make writing and testing your generators easier.
|
||||
|
||||
The [`github.com/gobuffalo/genny#File`](https://godoc.org/github.com/gobuffalo/genny#File) interface is the heart of working with files in Genny.
|
||||
|
||||
Genny ships with several convenience method for creating a [`github.com/gobuffalo/genny#File`](https://godoc.org/github.com/gobuffalo/genny#File).
|
||||
|
||||
* [`github.com/gobuffalo/genny#NewFile`](https://godoc.org/github.com/gobuffalo/genny#NewFile)
|
||||
* [`github.com/gobuffalo/genny#NewFileS`](https://godoc.org/github.com/gobuffalo/genny#NewFileS)
|
||||
* [`github.com/gobuffalo/genny#NewFileB`](https://godoc.org/github.com/gobuffalo/genny#NewFileB)
|
||||
* [`github.com/gobuffalo/genny#NewDir`](https://godoc.org/github.com/gobuffalo/genny#NewDir)
|
||||
|
||||
#### Writing Files
|
||||
|
||||
To write a file you can add a [`github.com/gobuffalo/genny#File`](https://godoc.org/github.com/gobuffalo/genny#File) to your [`github.com/gobuffalo/genny#Generator.File`](https://godoc.org/github.com/gobuffalo/genny#Generator.File) and your file will then be handled by your `*Runner` when your generator is run.
|
||||
|
||||
```go
|
||||
g.File(genny.NewFile("index.html", strings.NewReader("Hello\n")))
|
||||
g.File(genny.NewFileS("strings/string.html", "Hello\n"))
|
||||
g.File(genny.NewFileB("bytes/byte.html", []byte("Hello\n")))
|
||||
```
|
||||
|
||||
In the case of [`github.com/gobuffalo/genny#WetRunner`](https://godoc.org/github.com/gobuffalo/genny#WetRunner) will attemp to create any directories your files require.
|
||||
|
||||
#### Reading Files
|
||||
|
||||
When writing generators you may need to read an existing file, perhaps to modify it, or perhaps read it's contents. This presents a problem in generators.
|
||||
|
||||
The first problem is that anytime we have to read files from disk, we make testing more difficult.
|
||||
|
||||
The bigger problems, however, present themselves more with "dry" runners (for example testing), than they do with "wet" runners.
|
||||
|
||||
If generator `A` creates a new file and generator `B` wants to modify that file in testing and "dry" runners this is a problem as the file may not present on disk for generator `B` to access.
|
||||
|
||||
To work around this issue Genny has the concept of a [`github.com/gobuffalo/genny#Disk`](https://godoc.org/github.com/gobuffalo/genny#Disk).
|
||||
|
||||
Now, instead of asking for the file directly from the file system, we can ask for it from the [`github.com/gobuffalo/genny#Runner.Disk`](https://godoc.org/github.com/gobuffalo/genny#Runner.Disk) instead.
|
||||
|
||||
```go
|
||||
g.RunFn(func(r *genny.Runner) error {
|
||||
// try to find main.go either in the virtual "disk"
|
||||
// or the physical one
|
||||
f, err := r.Disk.Find("main.go")
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
// print the contents of the file
|
||||
fmt.Println(f.String())
|
||||
return nil
|
||||
})
|
||||
```
|
||||
|
||||
When asking for files from [`github.com/gobuffalo/genny#Runner.Disk`](https://godoc.org/github.com/gobuffalo/genny#Runner.Disk) it will first check its internal cache for the file, returning it if found. If the file is not in the cache, then it try to read it from disk at `filepath.Join(r.Root, name)`.
|
||||
|
||||
#### Transforming Files
|
||||
|
||||
There are times that you may need to transform either certain files, or all files. This could be as simple as replacing a variable in a template's name to match some user input, or something more complex, such as running any templates with a given extension through a certain template engine.
|
||||
|
||||
The [`github.com/gobuffalo/genny#Transformer`](https://godoc.org/github.com/gobuffalo/genny#Transformer) type can be used to implement these types of file transformations.
|
||||
|
||||
To create a new [`github.com/gobuffalo/genny#Transformer`](https://godoc.org/github.com/gobuffalo/genny#Transformer) you can use the [`github.com/gobuffalo/genny#NewTransformer`](https://godoc.org/github.com/gobuffalo/genny#NewTransformer) function.
|
||||
|
||||
The example below is taken from the [`github.com/gobuffalo/plushgen`](https://godoc.org/github.com/gobuffalo/plushgen) package.
|
||||
|
||||
```go
|
||||
// Transformer will plushify any file that has a ".plush" extension
|
||||
func Transformer(ctx *plush.Context) genny.Transformer {
|
||||
t := genny.NewTransformer(".plush", func(f genny.File) (genny.File, error) {
|
||||
s, err := plush.RenderR(f, ctx)
|
||||
if err != nil {
|
||||
return f, errors.Wrap(err, f.Name())
|
||||
}
|
||||
return genny.NewFileS(f.Name(), s), nil
|
||||
})
|
||||
t.StripExt = true
|
||||
return t
|
||||
}
|
||||
```
|
||||
|
||||
The [`github.com/gobuffalo/genny#Transformer`](https://godoc.org/github.com/gobuffalo/genny#Transformer) that is returned in the example will only be run on files that have a `.plush` extension in their name.
|
||||
|
||||
Should a file have a `.plush` extension, it will be sent to [`github.com/gobuffalo/plush`](https://godoc.org/github.com/gobuffalo/plush) to be rendered. The result of that rendering is returned as a new [`github.com/gobuffalo/genny#File`](https://godoc.org/github.com/gobuffalo/genny#File). Finally, the extension `.plush` will be stripped from the file name.
|
||||
|
||||
```go
|
||||
g := genny.New()
|
||||
|
||||
// add a file
|
||||
g.File(genny.NewFileS("index.html.plush", "Hello <%= name %>\n"))
|
||||
|
||||
// add the plush transformer
|
||||
ctx := plush.NewContext()
|
||||
ctx.Set("name", "World")
|
||||
g.Transformer(plushgen.Transformer(ctx))
|
||||
```
|
||||
|
||||
```plain
|
||||
// output
|
||||
DEBU[2018-12-07T10:35:56-05:00] Step: 09c9663e
|
||||
DEBU[2018-12-07T10:35:56-05:00] Chdir: /go/src/github.com/gobuffalo/genny/internal/_examples/dry
|
||||
DEBU[2018-12-07T10:35:56-05:00] File: /go/src/github.com/gobuffalo/genny/internal/_examples/dry/index.html
|
||||
Hello World
|
||||
```
|
||||
|
||||
### Testing
|
||||
|
||||
Testing a generator can be difficult because creating, deleting, and modifying files can be painful to handle during testing. The same can be said of running functions and HTTP requests.
|
||||
|
||||
The `*Fn` attributes on [`github.com/gobuffalo/genny#Runner`](https://godoc.org/github.com/gobuffalo/genny#Runner) make it simplier to mock out different test cases.
|
||||
|
||||
Most of the time the out of the box defaults are "good enough" for testing. The [`github.com/gobuffalo/genny/gentest`](https://godoc.org/github.com/gobuffalo/genny/gentest) package offers several helpers to simplify testing further.
|
||||
|
||||
In this example we test the "happy" path of a [`github.com/gobuffalo/genny#Generator`](https://godoc.org/github.com/gobuffalo/genny#Generator).
|
||||
|
||||
```go
|
||||
func Test_Happy(t *testing.T) {
|
||||
r := require.New(t)
|
||||
|
||||
run := gentest.NewRunner()
|
||||
run.Disk.Add(genny.NewFileS("main.go", "my main.go file"))
|
||||
|
||||
g := New()
|
||||
run.With(g)
|
||||
|
||||
r.NoError(run.Run())
|
||||
res := run.Results()
|
||||
|
||||
cmds := []string{"go env", "genny -h"}
|
||||
r.NoError(gentest.CompareCommands(cmds, res.Commands))
|
||||
|
||||
files := []string{"index.html", "main.go"}
|
||||
r.NoError(gentest.CompareFiles(files, res.Files))
|
||||
}
|
||||
```
|
||||
|
||||
Notice how in the above example we had to add `main.go` to the [`github.com/gobuffalo/genny#Runner.Disk`](https://godoc.org/github.com/gobuffalo/genny#Runner.Disk). That is because the file doesn't exist in our testing directory.
|
||||
|
||||
In the following example we test what happens when the `genny` executable can not be found when running the [`github.com/gobuffalo/genny#Generator`](https://godoc.org/github.com/gobuffalo/genny#Generator).
|
||||
|
||||
We can simulate this experience by using the [`github.com/gobuffalo/genny#Runner.LookPathFn`](https://godoc.org/github.com/gobuffalo/genny#Runner.LookPathFn) to return an error if it is asked about that particular executable.
|
||||
|
||||
```go
|
||||
func Test_Missing_Genny(t *testing.T) {
|
||||
r := require.New(t)
|
||||
|
||||
run := gentest.NewRunner()
|
||||
run.Disk.Add(genny.NewFileS("main.go", "my main.go file"))
|
||||
|
||||
g := New()
|
||||
run.With(g)
|
||||
|
||||
// pretend we can't find genny
|
||||
run.LookPathFn = func(s string) (string, error) {
|
||||
if s == "genny" {
|
||||
return "", errors.New("can't find genny")
|
||||
}
|
||||
return s, nil
|
||||
}
|
||||
|
||||
r.NoError(run.Run())
|
||||
res := run.Results()
|
||||
|
||||
cmds := []string{"go env", "go get github.com/gobuffalo/genny/genny", "genny -h"}
|
||||
r.NoError(gentest.CompareCommands(cmds, res.Commands))
|
||||
|
||||
files := []string{"index.html", "main.go"}
|
||||
r.NoError(gentest.CompareFiles(files, res.Files))
|
||||
}
|
||||
```
|
||||
|
||||
## The `genny` Executable
|
||||
|
||||
Genny ships with an executable that helps to generate new generators.
|
||||
|
||||
### Installation
|
||||
|
||||
```bash
|
||||
$ go get -u github.com/gobuffalo/genny/genny
|
||||
```
|
||||
|
||||
### Usage
|
||||
|
||||
```bash
|
||||
$ genny -h
|
||||
|
||||
tools for working with genny
|
||||
|
||||
Usage:
|
||||
genny [command]
|
||||
|
||||
Available Commands:
|
||||
help Help about any command
|
||||
new generates a new genny stub
|
||||
|
||||
Flags:
|
||||
-h, --help help for genny
|
||||
|
||||
Use "genny [command] --help" for more information about a command.
|
||||
```
|
||||
|
||||
### Generating a New Generator
|
||||
|
||||
```bash
|
||||
$ genny new coke -h
|
||||
|
||||
DEBU[2018-12-07T11:07:01-05:00] Step: a1d8eb2f
|
||||
DEBU[2018-12-07T11:07:01-05:00] Chdir: /go/src/github.com/gobuffalo
|
||||
DEBU[2018-12-07T11:07:01-05:00] File: /go/src/github.com/gobuffalo/coke/coke.go
|
||||
DEBU[2018-12-07T11:07:01-05:00] File: /go/src/github.com/gobuffalo/coke/coke_test.go
|
||||
DEBU[2018-12-07T11:07:01-05:00] File: /go/src/github.com/gobuffalo/coke/options.go
|
||||
DEBU[2018-12-07T11:07:01-05:00] File: /go/src/github.com/gobuffalo/coke/options_test.go
|
||||
DEBU[2018-12-07T11:07:01-05:00] File: /go/src/github.com/gobuffalo/coke/templates/example.txt
|
||||
```
|
||||
108
vendor/github.com/gobuffalo/genny/SHOULDERS.md
generated
vendored
Normal file
108
vendor/github.com/gobuffalo/genny/SHOULDERS.md
generated
vendored
Normal file
@@ -0,0 +1,108 @@
|
||||
# `github.com/gobuffalo/genny` Stands on the Shoulders of Giants
|
||||
|
||||
`github.com/gobuffalo/genny` does not try to reinvent the wheel! Instead, it uses the already great wheels developed by the Go community and puts them altogether in the best way possible. Without these giants this project would not be possible. Please make sure to check them out and thank them for all of their hard work.
|
||||
|
||||
Thank you to the following **GIANTS**:
|
||||
|
||||
|
||||
* [github.com/fatih/structs](https://godoc.org/github.com/fatih/structs)
|
||||
|
||||
* [github.com/gobuffalo/envy](https://godoc.org/github.com/gobuffalo/envy)
|
||||
|
||||
* [github.com/gobuffalo/flect](https://godoc.org/github.com/gobuffalo/flect)
|
||||
|
||||
* [github.com/gobuffalo/flect/name](https://godoc.org/github.com/gobuffalo/flect/name)
|
||||
|
||||
* [github.com/gobuffalo/github_flavored_markdown](https://godoc.org/github.com/gobuffalo/github_flavored_markdown)
|
||||
|
||||
* [github.com/gobuffalo/packr](https://godoc.org/github.com/gobuffalo/packr)
|
||||
|
||||
* [github.com/gobuffalo/plush](https://godoc.org/github.com/gobuffalo/plush)
|
||||
|
||||
* [github.com/gobuffalo/plush/ast](https://godoc.org/github.com/gobuffalo/plush/ast)
|
||||
|
||||
* [github.com/gobuffalo/plush/lexer](https://godoc.org/github.com/gobuffalo/plush/lexer)
|
||||
|
||||
* [github.com/gobuffalo/plush/parser](https://godoc.org/github.com/gobuffalo/plush/parser)
|
||||
|
||||
* [github.com/gobuffalo/plush/token](https://godoc.org/github.com/gobuffalo/plush/token)
|
||||
|
||||
* [github.com/gobuffalo/tags](https://godoc.org/github.com/gobuffalo/tags)
|
||||
|
||||
* [github.com/gobuffalo/tags/form](https://godoc.org/github.com/gobuffalo/tags/form)
|
||||
|
||||
* [github.com/gobuffalo/tags/form/bootstrap](https://godoc.org/github.com/gobuffalo/tags/form/bootstrap)
|
||||
|
||||
* [github.com/gobuffalo/uuid](https://godoc.org/github.com/gobuffalo/uuid)
|
||||
|
||||
* [github.com/gobuffalo/validate](https://godoc.org/github.com/gobuffalo/validate)
|
||||
|
||||
* [github.com/gobuffalo/validate/validators](https://godoc.org/github.com/gobuffalo/validate/validators)
|
||||
|
||||
* [github.com/joho/godotenv](https://godoc.org/github.com/joho/godotenv)
|
||||
|
||||
* [github.com/kr/pretty](https://godoc.org/github.com/kr/pretty)
|
||||
|
||||
* [github.com/markbates/going/defaults](https://godoc.org/github.com/markbates/going/defaults)
|
||||
|
||||
* [github.com/markbates/going/randx](https://godoc.org/github.com/markbates/going/randx)
|
||||
|
||||
* [github.com/markbates/going/wait](https://godoc.org/github.com/markbates/going/wait)
|
||||
|
||||
* [github.com/markbates/inflect](https://godoc.org/github.com/markbates/inflect)
|
||||
|
||||
* [github.com/microcosm-cc/bluemonday](https://godoc.org/github.com/microcosm-cc/bluemonday)
|
||||
|
||||
* [github.com/onsi/ginkgo](https://godoc.org/github.com/onsi/ginkgo)
|
||||
|
||||
* [github.com/onsi/gomega](https://godoc.org/github.com/onsi/gomega)
|
||||
|
||||
* [github.com/pkg/errors](https://godoc.org/github.com/pkg/errors)
|
||||
|
||||
* [github.com/serenize/snaker](https://godoc.org/github.com/serenize/snaker)
|
||||
|
||||
* [github.com/sergi/go-diff/diffmatchpatch](https://godoc.org/github.com/sergi/go-diff/diffmatchpatch)
|
||||
|
||||
* [github.com/shurcooL/highlight_diff](https://godoc.org/github.com/shurcooL/highlight_diff)
|
||||
|
||||
* [github.com/shurcooL/highlight_go](https://godoc.org/github.com/shurcooL/highlight_go)
|
||||
|
||||
* [github.com/shurcooL/octicon](https://godoc.org/github.com/shurcooL/octicon)
|
||||
|
||||
* [github.com/shurcooL/sanitized_anchor_name](https://godoc.org/github.com/shurcooL/sanitized_anchor_name)
|
||||
|
||||
* [github.com/sirupsen/logrus](https://godoc.org/github.com/sirupsen/logrus)
|
||||
|
||||
* [github.com/sourcegraph/annotate](https://godoc.org/github.com/sourcegraph/annotate)
|
||||
|
||||
* [github.com/sourcegraph/syntaxhighlight](https://godoc.org/github.com/sourcegraph/syntaxhighlight)
|
||||
|
||||
* [github.com/stretchr/testify/assert](https://godoc.org/github.com/stretchr/testify/assert)
|
||||
|
||||
* [github.com/stretchr/testify/require](https://godoc.org/github.com/stretchr/testify/require)
|
||||
|
||||
* [github.com/stretchr/testify/vendor/github.com/davecgh/go-spew/spew](https://godoc.org/github.com/stretchr/testify/vendor/github.com/davecgh/go-spew/spew)
|
||||
|
||||
* [github.com/stretchr/testify/vendor/github.com/pmezard/go-difflib/difflib](https://godoc.org/github.com/stretchr/testify/vendor/github.com/pmezard/go-difflib/difflib)
|
||||
|
||||
* [golang.org/x/crypto/ssh/terminal](https://godoc.org/golang.org/x/crypto/ssh/terminal)
|
||||
|
||||
* [golang.org/x/net/context](https://godoc.org/golang.org/x/net/context)
|
||||
|
||||
* [golang.org/x/net/html](https://godoc.org/golang.org/x/net/html)
|
||||
|
||||
* [golang.org/x/net/html/atom](https://godoc.org/golang.org/x/net/html/atom)
|
||||
|
||||
* [golang.org/x/sync/errgroup](https://godoc.org/golang.org/x/sync/errgroup)
|
||||
|
||||
* [golang.org/x/sys/unix](https://godoc.org/golang.org/x/sys/unix)
|
||||
|
||||
* [golang.org/x/tools/go/ast/astutil](https://godoc.org/golang.org/x/tools/go/ast/astutil)
|
||||
|
||||
* [golang.org/x/tools/imports](https://godoc.org/golang.org/x/tools/imports)
|
||||
|
||||
* [golang.org/x/tools/internal/fastwalk](https://godoc.org/golang.org/x/tools/internal/fastwalk)
|
||||
|
||||
* [gopkg.in/check.v1](https://godoc.org/gopkg.in/check.v1)
|
||||
|
||||
* [gopkg.in/russross/blackfriday.v1](https://godoc.org/gopkg.in/russross/blackfriday.v1)
|
||||
15
vendor/github.com/gobuffalo/genny/confirm.go
generated
vendored
Normal file
15
vendor/github.com/gobuffalo/genny/confirm.go
generated
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
package genny
|
||||
|
||||
import (
|
||||
"bufio"
|
||||
"fmt"
|
||||
"os"
|
||||
)
|
||||
|
||||
func Confirm(msg string) bool {
|
||||
reader := bufio.NewReader(os.Stdin)
|
||||
fmt.Print(msg)
|
||||
text, _ := reader.ReadString('\n')
|
||||
|
||||
return (text == "y\n" || text == "Y\n")
|
||||
}
|
||||
18
vendor/github.com/gobuffalo/genny/dir.go
generated
vendored
Normal file
18
vendor/github.com/gobuffalo/genny/dir.go
generated
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
package genny
|
||||
|
||||
import "os"
|
||||
|
||||
var _ File = Dir{}
|
||||
|
||||
type Dir struct {
|
||||
File
|
||||
Perm os.FileMode
|
||||
}
|
||||
|
||||
func NewDir(path string, perm os.FileMode) File {
|
||||
f := NewFileS(path, path)
|
||||
return Dir{
|
||||
File: f,
|
||||
Perm: perm,
|
||||
}
|
||||
}
|
||||
112
vendor/github.com/gobuffalo/genny/disk.go
generated
vendored
Normal file
112
vendor/github.com/gobuffalo/genny/disk.go
generated
vendored
Normal file
@@ -0,0 +1,112 @@
|
||||
package genny
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"io"
|
||||
"os"
|
||||
"runtime"
|
||||
"sort"
|
||||
"strings"
|
||||
"sync"
|
||||
|
||||
"github.com/gobuffalo/packd"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
// Disk is a virtual file system that works
|
||||
// with both dry and wet runners. Perfect for seeding
|
||||
// Files or non-destructively deleting files
|
||||
type Disk struct {
|
||||
Runner *Runner
|
||||
files map[string]File
|
||||
moot *sync.RWMutex
|
||||
}
|
||||
|
||||
func (d *Disk) AddBox(box packd.Walker) error {
|
||||
return box.Walk(func(path string, file packd.File) error {
|
||||
d.Add(NewFile(path, file))
|
||||
return nil
|
||||
})
|
||||
}
|
||||
|
||||
// Files returns a sorted list of all the files in the disk
|
||||
func (d *Disk) Files() []File {
|
||||
var files []File
|
||||
for _, f := range d.files {
|
||||
if s, ok := f.(io.Seeker); ok {
|
||||
s.Seek(0, 0)
|
||||
}
|
||||
files = append(files, f)
|
||||
}
|
||||
sort.Slice(files, func(i, j int) bool {
|
||||
return files[i].Name() < files[j].Name()
|
||||
})
|
||||
return files
|
||||
}
|
||||
|
||||
func newDisk(r *Runner) *Disk {
|
||||
return &Disk{
|
||||
Runner: r,
|
||||
files: map[string]File{},
|
||||
moot: &sync.RWMutex{},
|
||||
}
|
||||
}
|
||||
|
||||
// Remove a file(s) from the virtual disk.
|
||||
func (d *Disk) Remove(name string) {
|
||||
d.moot.Lock()
|
||||
defer d.moot.Unlock()
|
||||
for f, _ := range d.files {
|
||||
if strings.HasPrefix(f, name) {
|
||||
delete(d.files, f)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Delete calls the Runner#Delete function
|
||||
func (d *Disk) Delete(name string) error {
|
||||
return d.Runner.Delete(name)
|
||||
}
|
||||
|
||||
// Add file to the virtual disk
|
||||
func (d *Disk) Add(f File) {
|
||||
d.moot.Lock()
|
||||
defer d.moot.Unlock()
|
||||
d.files[f.Name()] = f
|
||||
}
|
||||
|
||||
// Find a file from the virtual disk. If the file doesn't
|
||||
// exist it will try to read the file from the physical disk.
|
||||
func (d *Disk) Find(name string) (File, error) {
|
||||
|
||||
d.moot.RLock()
|
||||
if f, ok := d.files[name]; ok {
|
||||
if seek, ok := f.(io.Seeker); ok {
|
||||
seek.Seek(0, 0)
|
||||
}
|
||||
d.moot.RUnlock()
|
||||
return f, nil
|
||||
}
|
||||
d.moot.RUnlock()
|
||||
|
||||
gf := NewFile(name, bytes.NewReader([]byte("")))
|
||||
|
||||
osname := name
|
||||
if runtime.GOOS == "windows" {
|
||||
osname = strings.Replace(osname, "/", "\\", -1)
|
||||
}
|
||||
f, err := os.Open(osname)
|
||||
if err != nil {
|
||||
return gf, errors.WithStack(err)
|
||||
}
|
||||
defer f.Close()
|
||||
|
||||
bb := &bytes.Buffer{}
|
||||
|
||||
if _, err := io.Copy(bb, f); err != nil {
|
||||
return gf, errors.WithStack(err)
|
||||
}
|
||||
gf = NewFile(name, bb)
|
||||
d.Add(gf)
|
||||
return gf, nil
|
||||
}
|
||||
15
vendor/github.com/gobuffalo/genny/dry_runner.go
generated
vendored
Normal file
15
vendor/github.com/gobuffalo/genny/dry_runner.go
generated
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
package genny
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/gobuffalo/logger"
|
||||
)
|
||||
|
||||
// DryRunner will NOT execute commands and write files
|
||||
// it is NOT destructive
|
||||
func DryRunner(ctx context.Context) *Runner {
|
||||
r := NewRunner(ctx)
|
||||
r.Logger = logger.New(logger.DebugLevel)
|
||||
return r
|
||||
}
|
||||
8
vendor/github.com/gobuffalo/genny/events.go
generated
vendored
Normal file
8
vendor/github.com/gobuffalo/genny/events.go
generated
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
package genny
|
||||
|
||||
const (
|
||||
EvtStarted = "genny:runner:started"
|
||||
EvtFinished = "genny:runner:finished"
|
||||
EvtFinishedErr = "genny:runner:finished:err"
|
||||
EvtStepPrefix = "genny:step"
|
||||
)
|
||||
32
vendor/github.com/gobuffalo/genny/file.go
generated
vendored
Normal file
32
vendor/github.com/gobuffalo/genny/file.go
generated
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
package genny
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"io"
|
||||
"runtime"
|
||||
"strings"
|
||||
|
||||
"github.com/gobuffalo/packd"
|
||||
)
|
||||
|
||||
// File interface for working with files
|
||||
type File = packd.SimpleFile
|
||||
|
||||
// NewFile takes the name of the file you want to
|
||||
// write to and a reader to reader from
|
||||
func NewFile(name string, r io.Reader) File {
|
||||
osname := name
|
||||
if runtime.GOOS == "windows" {
|
||||
osname = strings.Replace(osname, "\\", "/", -1)
|
||||
}
|
||||
f, _ := packd.NewFile(osname, r)
|
||||
return f
|
||||
}
|
||||
|
||||
func NewFileS(name string, s string) File {
|
||||
return NewFile(name, strings.NewReader(s))
|
||||
}
|
||||
|
||||
func NewFileB(name string, s []byte) File {
|
||||
return NewFile(name, bytes.NewReader(s))
|
||||
}
|
||||
84
vendor/github.com/gobuffalo/genny/force.go
generated
vendored
Normal file
84
vendor/github.com/gobuffalo/genny/force.go
generated
vendored
Normal file
@@ -0,0 +1,84 @@
|
||||
package genny
|
||||
|
||||
import (
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/gobuffalo/packd"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
// ForceBox will mount each file in the box and wrap it with ForceFile
|
||||
func ForceBox(g *Generator, box packd.Walker, force bool) error {
|
||||
return box.Walk(func(path string, bf packd.File) error {
|
||||
f := NewFile(path, bf)
|
||||
ff := ForceFile(f, force)
|
||||
f, err := ff(f)
|
||||
if err != nil {
|
||||
return errors.WithStack(err)
|
||||
}
|
||||
g.File(f)
|
||||
return nil
|
||||
})
|
||||
}
|
||||
|
||||
// ForceFile is a TransformerFn that will return an error if the path exists if `force` is false. If `force` is true it will delete the path.
|
||||
func ForceFile(f File, force bool) TransformerFn {
|
||||
return func(f File) (File, error) {
|
||||
path := f.Name()
|
||||
path, err := filepath.Abs(path)
|
||||
if err != nil {
|
||||
return f, errors.WithStack(err)
|
||||
}
|
||||
_, err = os.Stat(path)
|
||||
if err != nil {
|
||||
// path doesn't exist. move on.
|
||||
return f, nil
|
||||
}
|
||||
if !force {
|
||||
return f, errors.Errorf("path %s already exists", path)
|
||||
}
|
||||
if err := os.RemoveAll(path); err != nil {
|
||||
return f, errors.WithStack(err)
|
||||
}
|
||||
return f, nil
|
||||
}
|
||||
}
|
||||
|
||||
// Force is a RunFn that will return an error if the path exists if `force` is false. If `force` is true it will delete the path.
|
||||
// Is is recommended to use ForceFile when you can.
|
||||
func Force(path string, force bool) RunFn {
|
||||
if path == "." || path == "" {
|
||||
pwd, _ := os.Getwd()
|
||||
path = pwd
|
||||
}
|
||||
return func(r *Runner) error {
|
||||
path, err := filepath.Abs(path)
|
||||
if err != nil {
|
||||
return errors.WithStack(err)
|
||||
}
|
||||
fi, err := os.Stat(path)
|
||||
if err != nil {
|
||||
// path doesn't exist. move on.
|
||||
return nil
|
||||
}
|
||||
if !force {
|
||||
if !fi.IsDir() {
|
||||
return errors.Errorf("path %s already exists", path)
|
||||
}
|
||||
files, err := ioutil.ReadDir(path)
|
||||
if err != nil {
|
||||
return errors.WithStack(err)
|
||||
}
|
||||
if len(files) > 0 {
|
||||
return errors.Errorf("path %s already exists", path)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
if err := os.RemoveAll(path); err != nil {
|
||||
return errors.WithStack(err)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
}
|
||||
104
vendor/github.com/gobuffalo/genny/generator.go
generated
vendored
Normal file
104
vendor/github.com/gobuffalo/genny/generator.go
generated
vendored
Normal file
@@ -0,0 +1,104 @@
|
||||
package genny
|
||||
|
||||
import (
|
||||
"math/rand"
|
||||
"os/exec"
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
"github.com/gobuffalo/events"
|
||||
"github.com/gobuffalo/packd"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
func init() {
|
||||
rand.Seed(time.Now().UnixNano())
|
||||
}
|
||||
|
||||
// Generator is the basic type for generators to use
|
||||
type Generator struct {
|
||||
StepName string
|
||||
Should func(*Runner) bool
|
||||
Root string
|
||||
ErrorFn func(error)
|
||||
runners []RunFn
|
||||
transformers []Transformer
|
||||
moot *sync.RWMutex
|
||||
}
|
||||
|
||||
// New, well-formed, generator
|
||||
func New() *Generator {
|
||||
g := &Generator{
|
||||
StepName: stepName(),
|
||||
runners: []RunFn{},
|
||||
moot: &sync.RWMutex{},
|
||||
transformers: []Transformer{},
|
||||
}
|
||||
return g
|
||||
}
|
||||
|
||||
func (g *Generator) Event(kind string, payload events.Payload) {
|
||||
g.RunFn(func(r *Runner) error {
|
||||
return events.EmitPayload(kind, payload)
|
||||
})
|
||||
}
|
||||
|
||||
// File adds a file to be run when the generator is run
|
||||
func (g *Generator) File(f File) {
|
||||
g.RunFn(func(r *Runner) error {
|
||||
return r.File(f)
|
||||
})
|
||||
}
|
||||
|
||||
func (g *Generator) Transform(f File) (File, error) {
|
||||
g.moot.RLock()
|
||||
defer g.moot.RUnlock()
|
||||
var err error
|
||||
for _, t := range g.transformers {
|
||||
f, err = t.Transform(f)
|
||||
if err != nil {
|
||||
return f, errors.WithStack(err)
|
||||
}
|
||||
}
|
||||
|
||||
return f, nil
|
||||
}
|
||||
|
||||
// Transformer adds a file transform to the generator
|
||||
func (g *Generator) Transformer(t Transformer) {
|
||||
g.moot.Lock()
|
||||
defer g.moot.Unlock()
|
||||
g.transformers = append(g.transformers, t)
|
||||
}
|
||||
|
||||
// Command adds a command to be run when the generator is run
|
||||
func (g *Generator) Command(cmd *exec.Cmd) {
|
||||
g.RunFn(func(r *Runner) error {
|
||||
return r.Exec(cmd)
|
||||
})
|
||||
}
|
||||
|
||||
// Box walks through a packr.Box and adds Files for each entry
|
||||
// in the box.
|
||||
func (g *Generator) Box(box packd.Walker) error {
|
||||
return box.Walk(func(path string, f packd.File) error {
|
||||
g.File(NewFile(path, f))
|
||||
return nil
|
||||
})
|
||||
}
|
||||
|
||||
// RunFn adds a generic "runner" function to the generator.
|
||||
func (g *Generator) RunFn(fn RunFn) {
|
||||
g.moot.Lock()
|
||||
defer g.moot.Unlock()
|
||||
g.runners = append(g.runners, fn)
|
||||
}
|
||||
|
||||
func (g1 *Generator) Merge(g2 *Generator) {
|
||||
g2.moot.Lock()
|
||||
g1.moot.Lock()
|
||||
g1.runners = append(g1.runners, g2.runners...)
|
||||
g1.transformers = append(g1.transformers, g2.transformers...)
|
||||
g1.moot.Unlock()
|
||||
g2.moot.Unlock()
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user