aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Czygan <martin.czygan@gmail.com>2021-05-21 21:38:23 +0200
committerMartin Czygan <martin.czygan@gmail.com>2021-05-21 21:38:23 +0200
commitf11aa899c7a4bb0ffca72dacdafff422c435c1f1 (patch)
treecdd04bed380b80dbc5bd4961957c570b4e48583b
parentff07890fa0fd068bb6614d9f366572d6ce04caf6 (diff)
downloadrefcat-f11aa899c7a4bb0ffca72dacdafff422c435c1f1.tar.gz
refcat-f11aa899c7a4bb0ffca72dacdafff422c435c1f1.zip
more inline docs
-rw-r--r--skate/cmd/skate-cdx-lookup/main.go1
-rw-r--r--skate/cmd/skate-map/main.go2
-rw-r--r--skate/map.go2
-rw-r--r--skate/zippy.go4
4 files changed, 6 insertions, 3 deletions
diff --git a/skate/cmd/skate-cdx-lookup/main.go b/skate/cmd/skate-cdx-lookup/main.go
index 0578098..a6fc5f9 100644
--- a/skate/cmd/skate-cdx-lookup/main.go
+++ b/skate/cmd/skate-cdx-lookup/main.go
@@ -51,7 +51,6 @@ func main() {
log.Fatal(err)
}
line = strings.TrimSpace(line)
-
if !cache.Has(line) {
_, b, err := skate.LookupCDX(line)
if err != nil {
diff --git a/skate/cmd/skate-map/main.go b/skate/cmd/skate-map/main.go
index 3682e7b..6f3acb9 100644
--- a/skate/cmd/skate-map/main.go
+++ b/skate/cmd/skate-map/main.go
@@ -65,7 +65,7 @@ var (
func main() {
flag.Parse()
availableMappers := map[string]skate.Mapper{
- // Add new mapper functions here.
+ // Add new mapper functions here. TODO: add more docs.
"id": skate.Identity,
"ff": skate.CreateFixedMapper(*extraValue),
"ti": skate.MapperTitle,
diff --git a/skate/map.go b/skate/map.go
index 698725a..27bc627 100644
--- a/skate/map.go
+++ b/skate/map.go
@@ -210,7 +210,7 @@ func MapperURLFromRef(p []byte) (fields [][]byte, err error) {
// MapperPartial works on partial documents.
func MapperPartial(p []byte) (fields [][]byte, err error) {
- // XXX: slugify authors, how to compare two author strings? How do these
+ // TODO: slugify authors, how to compare two author strings? How do these
// things look like?
return nil, nil
}
diff --git a/skate/zippy.go b/skate/zippy.go
index bc65281..f2dca98 100644
--- a/skate/zippy.go
+++ b/skate/zippy.go
@@ -146,6 +146,10 @@ func ZippyVerifyRefs(releases, refs io.Reader, w io.Writer) error {
if err := enc.Encode(br); err != nil {
return err
}
+ default:
+ // XXX: We want to add unmatched pieces as well; here? We
+ // probably want to do a single final pass to complete the
+ // dataset.
}
}
return nil