From f734d26adba9751b88687df1a1ff0ff908168db7 Mon Sep 17 00:00:00 2001 From: Lea Anthony Date: Thu, 31 Mar 2022 20:13:28 +1100 Subject: [PATCH] Use wailsapp/mimetype module --- .../commands/generate/template/base/go.sum | 4 ++-- .../generate/template/base/go.tmpl.mod | 2 +- .../templates/templates/svelte/go.mod.tmpl | 2 +- .../templates/templates/svelte/go.sum | 4 ++-- .../templates/templates/vanilla/go.mod.tmpl | 2 +- .../templates/templates/vanilla/go.sum | 4 ++-- v2/go.mod | 2 +- v2/go.sum | 4 ++-- v2/internal/frontend/assetserver/mimecache.go | 2 +- v2/internal/gomod/gomod_test.go | 24 +++++++++---------- 10 files changed, 25 insertions(+), 25 deletions(-) diff --git a/v2/cmd/wails/internal/commands/generate/template/base/go.sum b/v2/cmd/wails/internal/commands/generate/template/base/go.sum index 3c219b526..d470c6129 100644 --- a/v2/cmd/wails/internal/commands/generate/template/base/go.sum +++ b/v2/cmd/wails/internal/commands/generate/template/base/go.sum @@ -16,8 +16,8 @@ github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab/go.mod h1:smsv/ github.com/fatih/structtag v1.2.0/go.mod h1:mBJUNpUnHmRKrKlQQlmCrh5PuhftFbNv8Ys4/aAZl94= github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568/go.mod h1:xEzjJPgXI435gkrCt3MPfRiAkVrwSbHsst4LCFVfpJc= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= -github.com/gabriel-vasile/mimetype v1.3.1 h1:qevA6c2MtE1RorlScnixeG0VA1H4xrXyhyX3oWBynNQ= -github.com/gabriel-vasile/mimetype v1.3.1/go.mod h1:fA8fi6KUiG7MgQQ+mEWotXoEOvmxRtOJlERCzSmRvr8= +github.com/wailsapp/mimetype v1.4.1-beta.1 h1:gSnKX7WH+7aA0EEjOGUmpWXTb0Nt5B7/8Dm9wHLrnnY= +github.com/wailsapp/mimetype v1.4.1-beta.1/go.mod h1:9aV5k31bBOv5z6u+QP8TltzvNGJPmNJD4XlAL3U+j3o= github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= github.com/gin-gonic/gin v1.6.3/go.mod h1:75u5sXoLsGZoRN5Sgbi1eraJ4GU3++wFwWzhwvtwp4M= github.com/gliderlabs/ssh v0.2.2/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0= diff --git a/v2/cmd/wails/internal/commands/generate/template/base/go.tmpl.mod b/v2/cmd/wails/internal/commands/generate/template/base/go.tmpl.mod index 2b2c9dc94..69685dd1a 100644 --- a/v2/cmd/wails/internal/commands/generate/template/base/go.tmpl.mod +++ b/v2/cmd/wails/internal/commands/generate/template/base/go.tmpl.mod @@ -8,7 +8,7 @@ module changeme github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.4.1-beta.1 github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect diff --git a/v2/cmd/wails/internal/commands/initialise/templates/templates/svelte/go.mod.tmpl b/v2/cmd/wails/internal/commands/initialise/templates/templates/svelte/go.mod.tmpl index 3b74eb322..d3e1921a2 100644 --- a/v2/cmd/wails/internal/commands/initialise/templates/templates/svelte/go.mod.tmpl +++ b/v2/cmd/wails/internal/commands/initialise/templates/templates/svelte/go.mod.tmpl @@ -8,7 +8,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect -github.com/gabriel-vasile/mimetype v1.3.1 // indirect +github.com/wailsapp/mimetype v1.4.1-beta.1 github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect diff --git a/v2/cmd/wails/internal/commands/initialise/templates/templates/svelte/go.sum b/v2/cmd/wails/internal/commands/initialise/templates/templates/svelte/go.sum index bba38583c..4ba840926 100644 --- a/v2/cmd/wails/internal/commands/initialise/templates/templates/svelte/go.sum +++ b/v2/cmd/wails/internal/commands/initialise/templates/templates/svelte/go.sum @@ -17,8 +17,8 @@ github.com/fatih/structtag v1.2.0/go.mod h1:mBJUNpUnHmRKrKlQQlmCrh5PuhftFbNv8Ys4 github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568/go.mod h1:xEzjJPgXI435gkrCt3MPfRiAkVrwSbHsst4LCFVfpJc= github.com/flytam/filenamify v1.0.0/go.mod h1:Dzf9kVycwcsBlr2ATg6uxjqiFgKGH+5SKFuhdeP5zu8= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= -github.com/gabriel-vasile/mimetype v1.3.1 h1:qevA6c2MtE1RorlScnixeG0VA1H4xrXyhyX3oWBynNQ= -github.com/gabriel-vasile/mimetype v1.3.1/go.mod h1:fA8fi6KUiG7MgQQ+mEWotXoEOvmxRtOJlERCzSmRvr8= +github.com/wailsapp/mimetype v1.4.1-beta.1 h1:gSnKX7WH+7aA0EEjOGUmpWXTb0Nt5B7/8Dm9wHLrnnY= +github.com/wailsapp/mimetype v1.4.1-beta.1/go.mod h1:9aV5k31bBOv5z6u+QP8TltzvNGJPmNJD4XlAL3U+j3o= github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= github.com/gin-gonic/gin v1.6.3/go.mod h1:75u5sXoLsGZoRN5Sgbi1eraJ4GU3++wFwWzhwvtwp4M= github.com/gliderlabs/ssh v0.2.2/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0= diff --git a/v2/cmd/wails/internal/commands/initialise/templates/templates/vanilla/go.mod.tmpl b/v2/cmd/wails/internal/commands/initialise/templates/templates/vanilla/go.mod.tmpl index 3b74eb322..d3e1921a2 100644 --- a/v2/cmd/wails/internal/commands/initialise/templates/templates/vanilla/go.mod.tmpl +++ b/v2/cmd/wails/internal/commands/initialise/templates/templates/vanilla/go.mod.tmpl @@ -8,7 +8,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect -github.com/gabriel-vasile/mimetype v1.3.1 // indirect +github.com/wailsapp/mimetype v1.4.1-beta.1 github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect diff --git a/v2/cmd/wails/internal/commands/initialise/templates/templates/vanilla/go.sum b/v2/cmd/wails/internal/commands/initialise/templates/templates/vanilla/go.sum index bba38583c..4ba840926 100644 --- a/v2/cmd/wails/internal/commands/initialise/templates/templates/vanilla/go.sum +++ b/v2/cmd/wails/internal/commands/initialise/templates/templates/vanilla/go.sum @@ -17,8 +17,8 @@ github.com/fatih/structtag v1.2.0/go.mod h1:mBJUNpUnHmRKrKlQQlmCrh5PuhftFbNv8Ys4 github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568/go.mod h1:xEzjJPgXI435gkrCt3MPfRiAkVrwSbHsst4LCFVfpJc= github.com/flytam/filenamify v1.0.0/go.mod h1:Dzf9kVycwcsBlr2ATg6uxjqiFgKGH+5SKFuhdeP5zu8= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= -github.com/gabriel-vasile/mimetype v1.3.1 h1:qevA6c2MtE1RorlScnixeG0VA1H4xrXyhyX3oWBynNQ= -github.com/gabriel-vasile/mimetype v1.3.1/go.mod h1:fA8fi6KUiG7MgQQ+mEWotXoEOvmxRtOJlERCzSmRvr8= +github.com/wailsapp/mimetype v1.4.1-beta.1 h1:gSnKX7WH+7aA0EEjOGUmpWXTb0Nt5B7/8Dm9wHLrnnY= +github.com/wailsapp/mimetype v1.4.1-beta.1/go.mod h1:9aV5k31bBOv5z6u+QP8TltzvNGJPmNJD4XlAL3U+j3o= github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= github.com/gin-gonic/gin v1.6.3/go.mod h1:75u5sXoLsGZoRN5Sgbi1eraJ4GU3++wFwWzhwvtwp4M= github.com/gliderlabs/ssh v0.2.2/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0= diff --git a/v2/go.mod b/v2/go.mod index 19c743729..50889c234 100644 --- a/v2/go.mod +++ b/v2/go.mod @@ -6,7 +6,6 @@ require ( github.com/Masterminds/semver v1.5.0 github.com/flytam/filenamify v1.0.0 github.com/fsnotify/fsnotify v1.4.9 - github.com/gabriel-vasile/mimetype v1.3.1 github.com/go-git/go-billy/v5 v5.2.0 // indirect github.com/go-git/go-git/v5 v5.3.0 github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 @@ -30,6 +29,7 @@ require ( github.com/pkg/errors v0.9.1 github.com/tc-hib/winres v0.1.5 github.com/tidwall/sjson v1.1.7 + github.com/wailsapp/mimetype v1.4.1-beta.1 github.com/wzshiming/ctc v1.2.3 github.com/ztrue/tracerr v0.3.0 golang.org/x/mod v0.4.1 diff --git a/v2/go.sum b/v2/go.sum index 7fa7b327c..4b6842229 100644 --- a/v2/go.sum +++ b/v2/go.sum @@ -20,8 +20,6 @@ github.com/flytam/filenamify v1.0.0 h1:ewx6BY2dj7U6h2zGPJmt33q/BjkSf/YsY/woQvnUN github.com/flytam/filenamify v1.0.0/go.mod h1:Dzf9kVycwcsBlr2ATg6uxjqiFgKGH+5SKFuhdeP5zu8= github.com/fsnotify/fsnotify v1.4.9 h1:hsms1Qyu0jgnwNXIxa+/V/PDsU6CfLf6CNO8H7IWoS4= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= -github.com/gabriel-vasile/mimetype v1.3.1 h1:qevA6c2MtE1RorlScnixeG0VA1H4xrXyhyX3oWBynNQ= -github.com/gabriel-vasile/mimetype v1.3.1/go.mod h1:fA8fi6KUiG7MgQQ+mEWotXoEOvmxRtOJlERCzSmRvr8= github.com/gliderlabs/ssh v0.2.2 h1:6zsha5zo/TWhRhwqCD3+EarCAgZ2yN28ipRnGPnwkI0= github.com/gliderlabs/ssh v0.2.2/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0= github.com/go-git/gcfg v1.5.0 h1:Q5ViNfGF8zFgyJWPqYwA7qGFoMTEiBmdlkcfRmpIMa4= @@ -139,6 +137,8 @@ github.com/valyala/bytebufferpool v1.0.0 h1:GqA5TC/0021Y/b9FG4Oi9Mr3q7XYx6Kllzaw github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= github.com/valyala/fasttemplate v1.2.1 h1:TVEnxayobAdVkhQfrfes2IzOB6o+z4roRkPF52WA1u4= github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= +github.com/wailsapp/mimetype v1.4.1-beta.1 h1:gSnKX7WH+7aA0EEjOGUmpWXTb0Nt5B7/8Dm9wHLrnnY= +github.com/wailsapp/mimetype v1.4.1-beta.1/go.mod h1:9aV5k31bBOv5z6u+QP8TltzvNGJPmNJD4XlAL3U+j3o= github.com/wzshiming/ctc v1.2.3 h1:q+hW3IQNsjIlOFBTGZZZeIXTElFM4grF4spW/errh/c= github.com/wzshiming/ctc v1.2.3/go.mod h1:2tVAtIY7SUyraSk0JxvwmONNPFL4ARavPuEsg5+KA28= github.com/wzshiming/winseq v0.0.0-20200112104235-db357dc107ae h1:tpXvBXC3hpQBDCc9OojJZCQMVRAbT3TTdUMP8WguXkY= diff --git a/v2/internal/frontend/assetserver/mimecache.go b/v2/internal/frontend/assetserver/mimecache.go index 6d402ccbe..3d2240412 100644 --- a/v2/internal/frontend/assetserver/mimecache.go +++ b/v2/internal/frontend/assetserver/mimecache.go @@ -5,7 +5,7 @@ import ( "path/filepath" "sync" - "github.com/gabriel-vasile/mimetype" + "github.com/wailsapp/mimetype" ) var ( diff --git a/v2/internal/gomod/gomod_test.go b/v2/internal/gomod/gomod_test.go index a901da0e1..5173a2230 100644 --- a/v2/internal/gomod/gomod_test.go +++ b/v2/internal/gomod/gomod_test.go @@ -18,7 +18,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.4.1-beta.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -81,7 +81,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -122,7 +122,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -162,7 +162,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -203,7 +203,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -244,7 +244,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -287,7 +287,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -331,7 +331,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -433,7 +433,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -474,7 +474,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -515,7 +515,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect @@ -559,7 +559,7 @@ require ( github.com/andybalholm/brotli v1.0.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/fasthttp/websocket v0.0.0-20200320073529-1554a54587ab // indirect - github.com/gabriel-vasile/mimetype v1.3.1 // indirect + github.com/wailsapp/mimetype v1.3.1 // indirect github.com/go-ole/go-ole v1.2.5 // indirect github.com/gofiber/fiber/v2 v2.17.0 // indirect github.com/gofiber/websocket/v2 v2.0.8 // indirect