module go.stargrave.org/mmfileget
-go 1.13
+go 1.15
-require github.com/mattermost/mattermost-server v5.29.0+incompatible
+require github.com/mattermost/mattermost-server/v5 v5.39.1
-replace github.com/mattermost/mattermost-server v5.29.0+incompatible => ./mattermost-server
+replace github.com/mattermost/mattermost-server/v5 v5.39.1 => ./mattermost-server
redo-ifchange main.go vendor-done
-${GO:-go} build -o $3 -mod=vendor
+${GO:-go} build -o $3 -mod=vendor -ldflags=-s
git clone --depth 1 --branch v5.29.0 https://github.com/mattermost/mattermost-server.git
ln -fs mattermost-server/vendor .
-rm vendor/modules.txt
mkdir -p vendor/github.com/mattermost/mattermost-server
ln -fs `pwd`/mattermost-server vendor/github.com/mattermost/mattermost-server/v5
+cat > vendor/modules.txt <<EOF
+# github.com/mattermost/mattermost-server/v5 v5.39.1 => ./mattermost-server
+## explicit
+github.com/mattermost/mattermost-server/v5
+EOF
touch $3