From c039bc7a1662ea64d22e8f58df58292ea1791842 Mon Sep 17 00:00:00 2001 From: Matthias Loibl Date: Sun, 27 Mar 2016 01:14:00 +0100 Subject: [PATCH] Fix misspellings in comments Found by https://goreportcard.com/report/github.com/drone/drone --- controller/hook.go | 2 +- engine/engine.go | 2 +- shared/docker/docker.go | 2 +- shared/token/token.go | 2 +- store/datastore/utils.go | 4 ++-- template/template.go | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/controller/hook.go b/controller/hook.go index fecb3be4..10d9e324 100644 --- a/controller/hook.go +++ b/controller/hook.go @@ -216,7 +216,7 @@ func PostHook(c *gin.Context) { log.Errorf("error setting commit status for %s/%d", repo.FullName, build.Number) } - // get the previous build so taht we can send + // get the previous build so that we can send // on status change notifications last, _ := store.GetBuildLastBefore(c, repo, build.Branch, build.ID) diff --git a/engine/engine.go b/engine/engine.go index 12022f32..add5f7a8 100644 --- a/engine/engine.go +++ b/engine/engine.go @@ -66,7 +66,7 @@ func Load(env envconfig.Env, s store.Store) Engine { engine.pool = newPool() engine.updater = &updater{engine.bus} - // quick fix to propogate HTTP_PROXY variables + // quick fix to propagate HTTP_PROXY variables // throughout the build environment. var proxyVars = []string{"HTTP_PROXY", "http_proxy", "HTTPS_PROXY", "https_proxy", "NO_PROXY", "no_proxy"} for _, proxyVar := range proxyVars { diff --git a/shared/docker/docker.go b/shared/docker/docker.go index 5952bcd7..6615871e 100644 --- a/shared/docker/docker.go +++ b/shared/docker/docker.go @@ -37,7 +37,7 @@ func Run(client dockerclient.Client, conf *dockerclient.ContainerConfig, name st // the container to exit. func RunDaemon(client dockerclient.Client, conf *dockerclient.ContainerConfig, name string) (*dockerclient.ContainerInfo, error) { - // attempts to create the contianer + // attempts to create the container id, err := client.CreateContainer(conf, name, nil) if err != nil { // and pull the image and re-create if that fails diff --git a/shared/token/token.go b/shared/token/token.go index 78ac04f7..5741d9f6 100644 --- a/shared/token/token.go +++ b/shared/token/token.go @@ -53,7 +53,7 @@ func ParseRequest(r *http.Request, fn SecretFunc) (*Token, error) { return Parse(token, fn) } - // and finally we attemt to get the token from + // and finally we attempt to get the token from // the user session cookie cookie, err := r.Cookie("user_sess") if err != nil { diff --git a/store/datastore/utils.go b/store/datastore/utils.go index ea39cff8..1d4ca8b7 100644 --- a/store/datastore/utils.go +++ b/store/datastore/utils.go @@ -53,8 +53,8 @@ func toList(listof []*model.RepoLite) (string, []interface{}) { return strings.Join(qs, ","), in } -// helper function that converts a simple repsitory list -// to a sql IN statment compatible with postgres. +// helper function that converts a simple repository list +// to a sql IN statement compatible with postgres. func toListPosgres(listof []*model.RepoLite) (string, []interface{}) { var size = len(listof) if size > 999 { diff --git a/template/template.go b/template/template.go index ac55ec03..c7c30ba9 100644 --- a/template/template.go +++ b/template/template.go @@ -51,7 +51,7 @@ func Load() *template.Template { } // marshal is a helper function to render data as JSON -// inside the tempalte. +// inside the template. func marshal(v interface{}) template.JS { a, _ := json.Marshal(v) return template.JS(a)