mirror of
https://github.com/gohugoio/hugo.git
synced 2024-11-07 20:30:36 -05:00
Fix assorted typos
This commit is contained in:
parent
6512d128c6
commit
f7f549e3a7
8 changed files with 9 additions and 9 deletions
|
@ -24,7 +24,7 @@ import (
|
|||
"github.com/spf13/afero"
|
||||
)
|
||||
|
||||
// Make sure we don't accidently use this in the real Hugo.
|
||||
// Make sure we don't accidentally use this in the real Hugo.
|
||||
var _ types.DevMarker = (*stacktracerFs)(nil)
|
||||
|
||||
// NewStacktracerFs wraps the given fs printing stack traces for file creates
|
||||
|
|
|
@ -70,7 +70,7 @@ func (p pageContent) contentToRender(renderedShortcodes map[string]string) []byt
|
|||
|
||||
}
|
||||
default:
|
||||
panic(fmt.Sprintf("unkown item type %T", it))
|
||||
panic(fmt.Sprintf("unknown item type %T", it))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -560,7 +560,7 @@ func TestPageSummary(t *testing.T) {
|
|||
assertFunc := func(t *testing.T, ext string, pages page.Pages) {
|
||||
p := pages[0]
|
||||
checkPageTitle(t, p, "SimpleWithoutSummaryDelimiter")
|
||||
// Source is not Asciidoctor- or RST-compatibile so don't test them
|
||||
// Source is not Asciidoctor- or RST-compatible so don't test them
|
||||
if ext != "ad" && ext != "rst" {
|
||||
checkPageContent(t, p, normalizeExpected(ext, "<p><a href=\"https://lipsum.com/\">Lorem ipsum</a> dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>\n\n<p>Additional text.</p>\n\n<p>Further text.</p>\n"), ext)
|
||||
checkPageSummary(t, p, normalizeExpected(ext, "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. Additional text."), ext)
|
||||
|
@ -590,7 +590,7 @@ func TestPageWithSummaryParameter(t *testing.T) {
|
|||
p := pages[0]
|
||||
checkPageTitle(t, p, "SimpleWithSummaryParameter")
|
||||
checkPageContent(t, p, normalizeExpected(ext, "<p>Some text.</p>\n\n<p>Some more text.</p>\n"), ext)
|
||||
// Summary is not Asciidoctor- or RST-compatibile so don't test them
|
||||
// Summary is not Asciidoctor- or RST-compatible so don't test them
|
||||
if ext != "ad" && ext != "rst" {
|
||||
checkPageSummary(t, p, normalizeExpected(ext, "Page with summary parameter and <a href=\"http://www.example.com/\">a link</a>"), ext)
|
||||
}
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
// limitations under the License.
|
||||
|
||||
// Package modules provides a client that can be used to manage Hugo Components,
|
||||
// what's refered to as Hugo Modules. Hugo Modules is built on top of Go Modules,
|
||||
// what's referred to as Hugo Modules. Hugo Modules is built on top of Go Modules,
|
||||
// but also supports vendoring and components stored directly in the themes dir.
|
||||
package modules
|
||||
|
||||
|
|
|
@ -219,7 +219,7 @@ type PageWithoutContent interface {
|
|||
ChildCareProvider
|
||||
TreeProvider
|
||||
|
||||
// Horisontal navigation
|
||||
// Horizontal navigation
|
||||
InSectionPositioner
|
||||
PageRenderProvider
|
||||
PaginatorProvider
|
||||
|
|
|
@ -702,7 +702,7 @@ func (r *Spec) newGenericResourceWithBase(
|
|||
mediaType media.Type) *genericResource {
|
||||
|
||||
if osFileInfo != nil && osFileInfo.IsDir() {
|
||||
panic(fmt.Sprintf("dirs nto supported resource types: %v", osFileInfo))
|
||||
panic(fmt.Sprintf("dirs not supported resource types: %v", osFileInfo))
|
||||
}
|
||||
|
||||
// This value is used both to construct URLs and file paths, but start
|
||||
|
|
|
@ -61,7 +61,7 @@ func TestMerge(t *testing.T) {
|
|||
// Error cases.
|
||||
{"dst not a map", "not a map", nil, nil, true},
|
||||
{"src not a map", simpleMap, "not a map", nil, true},
|
||||
{"diferent map typs", simpleMap, map[int]interface{}{32: "a"}, nil, true},
|
||||
{"different map types", simpleMap, map[int]interface{}{32: "a"}, nil, true},
|
||||
{"all nil", nil, nil, nil, true},
|
||||
} {
|
||||
|
||||
|
|
|
@ -83,7 +83,7 @@ func (s *shortcodeTemplates) fromVariantsSlice(variants []string) (shortcodeVari
|
|||
return bestMatch, true
|
||||
}
|
||||
|
||||
// calculate a weight for two string slices of same lenght.
|
||||
// calculate a weight for two string slices of same length.
|
||||
// higher value means "better match".
|
||||
func (s *shortcodeTemplates) compareVariants(a, b []string) int {
|
||||
|
||||
|
|
Loading…
Reference in a new issue