• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

mlange-42 / modo / 13043300400

30 Jan 2025 12:42AM CUT coverage: 67.728%. Remained the same
13043300400

Pull #167

github

web-flow
Merge d23125652 into 443450e82
Pull Request #167: Collapse packages in file trees, use 4 columns

1213 of 1791 relevant lines covered (67.73%)

28.13 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

45.0
/format/plain.go
1
package format
2

3
import (
4
        "path"
5

6
        "github.com/mlange-42/modo/document"
7
)
8

9
type Plain struct{}
10

11
func (f *Plain) Accepts(files []string) error {
×
12
        return nil
×
13
}
×
14

15
func (f *Plain) ProcessMarkdown(element any, text string, proc *document.Processor) (string, error) {
×
16
        return text, nil
×
17
}
×
18

19
func (f *Plain) WriteAuxiliary(p *document.Package, dir string, proc *document.Processor) error {
×
20
        return nil
×
21
}
×
22

23
func (f *Plain) ToFilePath(p string, kind string) string {
6✔
24
        if kind == "package" || kind == "module" {
10✔
25
                return path.Join(p, "_index.md")
4✔
26
        }
4✔
27
        if len(p) == 0 {
2✔
28
                return p
×
29
        }
×
30
        return p + ".md"
2✔
31
}
32

33
func (f *Plain) ToLinkPath(p string, kind string) string {
3✔
34
        return f.ToFilePath(p, kind)
3✔
35
}
3✔
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc