diff options
-rw-r--r-- | .gitignore | 2 | ||||
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | cmd/generate/main.go | 10 | ||||
-rw-r--r-- | go.mod | 2 | ||||
-rw-r--r-- | imworkingon/contribs.yml (renamed from contribs.yml) | 0 | ||||
-rw-r--r-- | imworkingon/tags.yml (renamed from tags.yml) | 0 | ||||
-rw-r--r-- | imworkingon/upstreams.yml (renamed from upstreams.yml) | 0 |
7 files changed, 8 insertions, 8 deletions
@@ -1 +1 @@ -/imworkingon.html +/public/imworkingon.html @@ -1,4 +1,4 @@ -imworkingon.html: FORCE +public/imworkingon.html: FORCE go run ./cmd/generate .PHONY: FORCE diff --git a/cmd/generate/main.go b/cmd/generate/main.go index 85f452e..ab6409a 100644 --- a/cmd/generate/main.go +++ b/cmd/generate/main.go @@ -36,15 +36,15 @@ func main() { var htmlTmplStr string func mainWithError() error { - contribs, err := ReadContribs("contribs.yml") + contribs, err := ReadContribs("imworkingon/contribs.yml") if err != nil { return err } - tags, err := ReadTags("tags.yml") + tags, err := ReadTags("imworkingon/tags.yml") if err != nil { return err } - upstreams, err := ReadUpstreams("upstreams.yml") + upstreams, err := ReadUpstreams("imworkingon/upstreams.yml") if err != nil { return err } @@ -53,7 +53,7 @@ func mainWithError() error { return contribs[i].SubmittedAt.After(contribs[j].SubmittedAt) }) - tmpl := template.Must(template.New("imworkingon.html"). + tmpl := template.Must(template.New("imworkingon.html.tmpl"). Funcs(template.FuncMap{ "md2html": MarkdownToHTML, "getUpstream": func(c Contribution) Upstream { @@ -83,7 +83,7 @@ func mainWithError() error { }); err != nil { return err } - if err := os.WriteFile("imworkingon.html", out.Bytes(), 0666); err != nil { + if err := os.WriteFile("public/imworkingon.html", out.Bytes(), 0666); err != nil { return err } return nil @@ -1,4 +1,4 @@ -module git.lukeshu.com/imworkingon +module git.lukeshu.com/www go 1.22.2 diff --git a/contribs.yml b/imworkingon/contribs.yml index 6620ea7..6620ea7 100644 --- a/contribs.yml +++ b/imworkingon/contribs.yml diff --git a/tags.yml b/imworkingon/tags.yml index 8e0fa2d..8e0fa2d 100644 --- a/tags.yml +++ b/imworkingon/tags.yml diff --git a/upstreams.yml b/imworkingon/upstreams.yml index 7dc0d70..7dc0d70 100644 --- a/upstreams.yml +++ b/imworkingon/upstreams.yml |