MCPcopy Create free account
hub / github.com/celer-pkg/celer / writeSectionTitle

Method writeSectionTitle

pkgcache/metadata.go:283–292  ·  view source on GitHub ↗
(buffer *bytes.Buffer, parents []string, nameVersion, what string)

Source from the content-addressed store, hash-verified

281}
282
283func (p Port) writeSectionTitle(buffer *bytes.Buffer, parents []string, nameVersion, what string) {
284 switch p.PortType {
285 case portTypePort:
286 buffer.WriteString(newDivider(parents, nameVersion, what))
287 case portTypeDependency:
288 buffer.WriteString(newDivider(parents, fmt.Sprintf("dependency: %s", nameVersion), what))
289 case portTypeDevDependency:
290 buffer.WriteString(newDivider(parents, fmt.Sprintf("dev_dependency: %s", nameVersion), what))
291 }
292}
293
294func (p Port) readPatch(patchFileName string) (string, error) {
295 patchFilePath := filepath.Join(filepath.Dir(p.BuildConfig.PortFile), patchFileName)

Callers 2

BuildMetaMethod · 0.95
buildMetaMethod · 0.95

Calls 2

newDividerFunction · 0.85
SprintfMethod · 0.80

Tested by

no test coverage detected