replace packages slog and slices from golang.org/x/exp with stdlib

since we are now at go1.21 as minimum.
This commit is contained in:
Mechiel Lukkien
2024-02-08 14:49:01 +01:00
parent c698cd07d9
commit d1b87cdb0d
123 changed files with 191 additions and 4860 deletions

View File

@ -3,11 +3,10 @@ package http
import (
"encoding/xml"
"fmt"
"log/slog"
"net/http"
"strings"
"golang.org/x/exp/slog"
"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/client_golang/prometheus/promauto"
"rsc.io/qr"

View File

@ -7,6 +7,7 @@ import (
"fmt"
"io"
"io/fs"
"log/slog"
"net/http"
"os"
"path/filepath"
@ -16,8 +17,6 @@ import (
"sync"
"time"
"golang.org/x/exp/slog"
"github.com/mjl-/mox/mlog"
)

View File

@ -6,11 +6,11 @@ import (
"crypto/sha256"
"encoding/xml"
"fmt"
"slices"
"sort"
"strings"
"golang.org/x/exp/maps"
"golang.org/x/exp/slices"
"github.com/mjl-/mox/mox-"
"github.com/mjl-/mox/smtp"

View File

@ -1,13 +1,12 @@
package http
import (
"log/slog"
"net"
"net/http"
"strings"
"time"
"golang.org/x/exp/slog"
"github.com/mjl-/mox/dns"
"github.com/mjl-/mox/mlog"
"github.com/mjl-/mox/mox-"

View File

@ -10,6 +10,7 @@ import (
"fmt"
"io"
golog "log"
"log/slog"
"net"
"net/http"
"os"
@ -21,7 +22,6 @@ import (
_ "net/http/pprof"
"golang.org/x/exp/maps"
"golang.org/x/exp/slog"
"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/client_golang/prometheus/promauto"

View File

@ -13,6 +13,7 @@ import (
"io"
"io/fs"
golog "log"
"log/slog"
"net"
"net/http"
"net/http/httputil"
@ -25,8 +26,6 @@ import (
"syscall"
"time"
"golang.org/x/exp/slog"
"github.com/mjl-/mox/config"
"github.com/mjl-/mox/dns"
"github.com/mjl-/mox/mlog"