all repos — homestead @ 9762929ba7b804a268e752c4b362339278806cfe

Code for my website

rename go module

Alan Pearce
commit

9762929ba7b804a268e752c4b362339278806cfe

parent

1d1d06236ad97c6c9195c8a8bb854240fdd7b485

M cmd/build/main.gocmd/build/main.go
@@ -4,8 +4,8 @@ import (
"fmt" "os" - "website/internal/builder" - "website/internal/log" + "go.alanpearce.eu/website/internal/builder" + "go.alanpearce.eu/website/internal/log" "github.com/ardanlabs/conf/v3" "github.com/pkg/errors"
M cmd/cspgenerator/cspgenerator.gocmd/cspgenerator/cspgenerator.go
@@ -1,8 +1,8 @@
package main import ( - "website/internal/config" - "website/internal/log" + "go.alanpearce.eu/website/internal/config" + "go.alanpearce.eu/website/internal/log" ) func main() {
M cmd/server/main.gocmd/server/main.go
@@ -6,8 +6,8 @@ "fmt"
"os" "os/signal" - "website/internal/log" - "website/internal/server" + "go.alanpearce.eu/website/internal/log" + "go.alanpearce.eu/website/internal/server" "github.com/ardanlabs/conf/v3" "github.com/pkg/errors"
M go.modgo.mod
@@ -1,4 +1,4 @@
-module website +module go.alanpearce.eu/website go 1.22.1
M internal/atom/atom.gointernal/atom/atom.go
@@ -4,7 +4,7 @@ import (
"encoding/xml" "time" - "website/internal/config" + "go.alanpearce.eu/website/internal/config" ) func MakeTagURI(config *config.Config, specific string) string {
M internal/builder/builder.gointernal/builder/builder.go
@@ -10,11 +10,11 @@ "path/filepath"
"slices" "time" - "website/internal/config" - "website/internal/content" - "website/internal/log" - "website/internal/sitemap" - "website/templates" + "go.alanpearce.eu/website/internal/config" + "go.alanpearce.eu/website/internal/content" + "go.alanpearce.eu/website/internal/log" + "go.alanpearce.eu/website/internal/sitemap" + "go.alanpearce.eu/website/templates" "github.com/a-h/templ" mapset "github.com/deckarep/golang-set/v2"
M internal/builder/template.gointernal/builder/template.go
@@ -7,9 +7,10 @@ "os"
"path/filepath" "strings" "text/template" - "website/internal/atom" - "website/internal/config" - "website/internal/content" + + "go.alanpearce.eu/website/internal/atom" + "go.alanpearce.eu/website/internal/config" + "go.alanpearce.eu/website/internal/content" "github.com/PuerkitoBio/goquery" "github.com/antchfx/xmlquery"
M internal/config/config.gointernal/config/config.go
@@ -4,7 +4,8 @@ import (
"io/fs" "net/url" "path/filepath" - "website/internal/log" + + "go.alanpearce.eu/website/internal/log" "github.com/BurntSushi/toml" "github.com/pkg/errors"
M internal/content/posts.gointernal/content/posts.go
@@ -8,7 +8,8 @@ "path/filepath"
"slices" "strings" "time" - "website/internal/log" + + "go.alanpearce.eu/website/internal/log" "github.com/adrg/frontmatter" mapset "github.com/deckarep/golang-set/v2"
M internal/listenfd/listenfd.gointernal/listenfd/listenfd.go
@@ -5,7 +5,8 @@ "crypto/tls"
"net" "os" "strconv" - "website/internal/log" + + "go.alanpearce.eu/website/internal/log" "github.com/pkg/errors" )
M internal/server/dev.gointernal/server/dev.go
@@ -9,7 +9,8 @@ "path"
"path/filepath" "slices" "time" - "website/internal/log" + + "go.alanpearce.eu/website/internal/log" "github.com/fsnotify/fsnotify" "github.com/pkg/errors"
M internal/server/logging.gointernal/server/logging.go
@@ -2,7 +2,8 @@ package server
import ( "net/http" - "website/internal/log" + + "go.alanpearce.eu/website/internal/log" ) type LoggingResponseWriter struct {
M internal/server/mime.gointernal/server/mime.go
@@ -2,7 +2,8 @@ package server
import ( "mime" - "website/internal/log" + + "go.alanpearce.eu/website/internal/log" ) var newMIMEs = map[string]string{
M internal/server/server.gointernal/server/server.go
@@ -13,11 +13,11 @@ "strconv"
"strings" "time" - "website/internal/builder" - cfg "website/internal/config" - "website/internal/log" - "website/internal/vcs" - "website/internal/website" + "go.alanpearce.eu/website/internal/builder" + cfg "go.alanpearce.eu/website/internal/config" + "go.alanpearce.eu/website/internal/log" + "go.alanpearce.eu/website/internal/vcs" + "go.alanpearce.eu/website/internal/website" "github.com/ardanlabs/conf/v3" "github.com/osdevisnot/sorvor/pkg/livereload"
M internal/server/tcp.gointernal/server/tcp.go
@@ -1,7 +1,7 @@
package server import ( - "website/internal/listenfd" + "go.alanpearce.eu/website/internal/listenfd" ) func (s *Server) serveTCP() error {
M internal/server/tls.gointernal/server/tls.go
@@ -6,8 +6,9 @@ "crypto/x509"
"net" "net/http" "strconv" - "website/internal/listenfd" - "website/internal/log" + + "go.alanpearce.eu/website/internal/listenfd" + "go.alanpearce.eu/website/internal/log" "github.com/ardanlabs/conf/v3" "github.com/caddyserver/caddy/v2"
M internal/sitemap/sitemap.gointernal/sitemap/sitemap.go
@@ -3,7 +3,8 @@
import ( "io" "time" - "website/internal/config" + + "go.alanpearce.eu/website/internal/config" "github.com/snabb/sitemap" )
M internal/vcs/repository.gointernal/vcs/repository.go
@@ -2,8 +2,9 @@ package vcs
import ( "os" - "website/internal/config" - "website/internal/log" + + "go.alanpearce.eu/website/internal/config" + "go.alanpearce.eu/website/internal/log" "github.com/go-git/go-git/v5" "github.com/pkg/errors"
M internal/website/filemap.gointernal/website/filemap.go
@@ -10,7 +10,7 @@ "os"
"path/filepath" "strings" - "website/internal/log" + "go.alanpearce.eu/website/internal/log" "github.com/pkg/errors" )
M internal/website/mux.gointernal/website/mux.go
@@ -4,10 +4,11 @@ import (
"encoding/json" "net/http" "strings" - "website/internal/config" - ihttp "website/internal/http" - "website/internal/log" - "website/templates" + + "go.alanpearce.eu/website/internal/config" + ihttp "go.alanpearce.eu/website/internal/http" + "go.alanpearce.eu/website/internal/log" + "go.alanpearce.eu/website/templates" "github.com/benpate/digit" "github.com/kevinpollet/nego"
M templates/error.templtemplates/error.templ
@@ -1,8 +1,8 @@
package templates import ( - "website/internal/config" - "website/internal/http" + "go.alanpearce.eu/website/internal/config" + "go.alanpearce.eu/website/internal/http" "strconv" )
M templates/homepage.templtemplates/homepage.templ
@@ -1,8 +1,8 @@
package templates import ( - "website/internal/config" - "website/internal/content" + "go.alanpearce.eu/website/internal/config" + "go.alanpearce.eu/website/internal/content" ) templ Homepage(config *config.Config, posts []content.Post, content string) {
M templates/list.templtemplates/list.templ
@@ -1,8 +1,8 @@
package templates import ( - "website/internal/config" - "website/internal/content" + "go.alanpearce.eu/website/internal/config" + "go.alanpearce.eu/website/internal/content" ) templ TagPage(config *config.Config, tag string, posts []content.Post, path string) {
M templates/page.templtemplates/page.templ
@@ -3,7 +3,7 @@
import ( "io/fs" - "website/internal/config" + "go.alanpearce.eu/website/internal/config" ) var (
@@ -70,7 +70,7 @@ </main>
<footer> Content is <a rel="license" href="http://creativecommons.org/licenses/by/4.0/">CC BY 4.0</a>. - <a href="https://git.alanpearce.eu/website/">Site source code</a> is + <a href="https://git.alanpearce.eu/go.alanpearce.eu/website/">Site source code</a> is <a href="https://opensource.org/licenses/MIT">MIT</a> </footer> @counter(site, page.Path, page.Title)
M templates/post.templtemplates/post.templ
@@ -2,8 +2,8 @@ package templates
import ( "time" - "website/internal/config" - "website/internal/content" + "go.alanpearce.eu/website/internal/config" + "go.alanpearce.eu/website/internal/content" ) func Unsafe(html string) templ.Component {
M templates/tags.templtemplates/tags.templ
@@ -1,6 +1,6 @@
package templates -import "website/internal/config" +import "go.alanpearce.eu/website/internal/config" templ tagLink(tag string, attrs templ.Attributes) { <a { attrs... } href={ templ.SafeURL("/tags/" + tag) }>#{ tag }</a>