Use Go Modules, Upgrade Module to Go 1.20 #74
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Note: I don't expect this large PR to be merged, would be great if an AWS internal would go over the steps outlined in this PR to modernize and modularize the repo.
Issue #, if available:
Description of changes:
github.com/twinj/uuid
to the last compatible version (v0.0.0-20151029044442-89173bcdda19
)go build
instead ofgo build -i
(flag does not exist in go 1.20)go fmt -s -w
to go format the whole reporm -rf vendor
) and Rungo mod vendor
to vendor with go modulesSteps:
rm -rf /vendor
go fmt -s -w .
to go format the code basego mod init
go mod tidy
go mod vendor
go mod vendor
again and try to build again withmake build
(this will fail, continue reading...)go.mod
and change the version ofgithub.aaakk.us.kg/twinj/uuid
fromv1.0.0
tov0.0.0-20151029044442-89173bcdda19
go mod tidy
andgo mod vendor
again. Try building again (withmake build
)... You will now get failures related to runninggo build -i
(with an-i
flag, which is not supported in go 1.20)-i
from alias in the second line e.g.✅ Building (with
make build
) should now succeed for all the OSesHopefully this gets done one day!
Testing:
None done. I imagine the SSM team in charge of the plugin has an end-to-end user acceptance test (UAT) and some magic to vet all still works well with the latest-and-greatest version of all dependencies.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.