fix golint errors

This commit is contained in:
matcornic 2017-03-28 18:41:38 +02:00
parent fde49fefcf
commit fc04e7ea13
6 changed files with 14 additions and 12 deletions

View File

@ -1,5 +1,7 @@
# Hermes # Hermes
[![Go Report Card](https://goreportcard.com/badge/github.com/matcornic/hermes)](https://goreportcard.com/report/github.com/matcornic/hermes)
Hermes is the Go port of the great [mailgen](https://github.com/eladnava/mailgen) engine for Node.js. Check their work, it's awesome ! Hermes is the Go port of the great [mailgen](https://github.com/eladnava/mailgen) engine for Node.js. Check their work, it's awesome !
It's a package that generates clean, responsive HTML e-mails for sending transactional e-mails (welcome e-mail, reset password e-mails, receipt e-mails and so on). It's a package that generates clean, responsive HTML e-mails for sending transactional e-mails (welcome e-mail, reset password e-mails, receipt e-mails and so on).

View File

@ -6,7 +6,7 @@ import (
"io/ioutil" "io/ioutil"
) )
type Example interface { type example interface {
Email() hermes.Email Email() hermes.Email
Name() string Name() string
} }
@ -20,7 +20,7 @@ func main() {
}, },
} }
examples := []Example{ examples := []example{
new(Welcome), new(Welcome),
new(Reset), new(Reset),
new(Receipt), new(Receipt),

View File

@ -4,14 +4,14 @@ import (
"github.com/matcornic/hermes" "github.com/matcornic/hermes"
) )
type Receipt struct { type receipt struct {
} }
func (r *Receipt) Name() string { func (r *receipt) Name() string {
return "receipt" return "receipt"
} }
func (r *Receipt) Email() hermes.Email { func (r *receipt) Email() hermes.Email {
return hermes.Email{ return hermes.Email{
Body: hermes.Body{ Body: hermes.Body{
Name: "Jon Snow", Name: "Jon Snow",

View File

@ -4,14 +4,14 @@ import (
"github.com/matcornic/hermes" "github.com/matcornic/hermes"
) )
type Reset struct { type reset struct {
} }
func (r *Reset) Name() string { func (r *reset) Name() string {
return "reset" return "reset"
} }
func (r *Reset) Email() hermes.Email { func (r *reset) Email() hermes.Email {
return hermes.Email{ return hermes.Email{
Body: hermes.Body{ Body: hermes.Body{
Name: "Jon Snow", Name: "Jon Snow",

View File

@ -4,14 +4,14 @@ import (
"github.com/matcornic/hermes" "github.com/matcornic/hermes"
) )
type Welcome struct { type welcome struct {
} }
func (w *Welcome) Name() string { func (w *welcome) Name() string {
return "welcome" return "welcome"
} }
func (w *Welcome) Email() hermes.Email { func (w *welcome) Email() hermes.Email {
return hermes.Email{ return hermes.Email{
Body: hermes.Body{ Body: hermes.Body{
Name: "Jon Snow", Name: "Jon Snow",

View File

@ -48,7 +48,7 @@ type Email struct {
type Body struct { type Body struct {
Name string // The name of the contacted person Name string // The name of the contacted person
Intros []string // Intro sentences, first displayed in the email Intros []string // Intro sentences, first displayed in the email
Dictionary []Entry // A list of key+value (usefull for displaying parameters/settings/personal info) Dictionary []Entry // A list of key+value (useful for displaying parameters/settings/personal info)
Table Table // Table is an table where you can put data (pricing grid, a bill, and so on) Table Table // Table is an table where you can put data (pricing grid, a bill, and so on)
Actions []Action // Actions are a list of actions that the user will be able to execute via a button click Actions []Action // Actions are a list of actions that the user will be able to execute via a button click
Outros []string // Outro sentences, last displayed in the email Outros []string // Outro sentences, last displayed in the email