goimports v0.5.5 Release Notes

Release Date: 2020-12-04 // over 3 years ago
  • gopls/v0.5.5

    🚀 This is a patch release to fix two bugs in gopls/v0.5.4.

    🛠 Fixes

    📦 Excessive reloading of packages outside of GOPATH or a module

    👀 See golang/go#42813.

    💅 File corruption with CRLF line endings and //-style comments

    🛠 golang/go#42646 was supposed to have been fixed in gopls/v0.5.4, but it was not. golang/go#42923 was reported and fixed.


    🛠 A full list of all issues fixed can be found in the gopls/v0.5.5 milestone. To report a new problem, please file a new issue at https://golang.org/issues/new.


Previous changes from v0.5.4

  • 🔋 Features

    Opening a project that contains a module in a subdirectory

    Previously, gopls required that you open your editor exactly at or below the module root (the directory containing the go.mod). Now, you can open a directory that contains exactly one module in a subdirectory, and gopls will work as expected. For details on multi-module workspaces, see below.

    👌 Improved error message reports

    🚑 Previously, critical error messages were reported as message pop-up that would re-trigger as you type. Many users would find this annoying. We have changed the approach to show error messages as progress reports, which should be less intrusive and appear more like status bars.

    👌 Improved memory usage for workspaces with multiple folders

    📦 We are now using a coarser cache key for package type information. If you use the gopls daemon, this may reduce your total memory usage.

    Experimental

    👍 Multi-module workspace support

    👀 The proposal described in golang/go#32394 is still in development and off by default. See our progress by tracking the multi-module workspace milestone and project.

    👍 Enable multi-module workspace support by adding the following to your settings:

    "gopls": {"experimentalWorkspaceModule": true,}
    

    With this setting, you will be able to open a directory that contains multiple modules or a directory that contains nested modules.

    Give this a try if you're interested in this new feature, but please note that it is still very experimental. Please file issues if you encounter bugs.

    🛠 Fixes

    💅 File corruption with CRLF line endings and /**/-style comments

    🏁 Previously, when you organized the imports in a file with CRLF line endings and multi-line comments, the formatter might output incorrect content for the file, rendering it invalid Go code. This issue has popped up a number of times, but we believe it has finally been fixed for good. If you are using Windows with CRLF line ending, please report any regressions. For full details, see golang/go#42646.


    🛠 A full list of all issues fixed can be found in the gopls/v0.5.4 milestone. To report a new problem, please file a new issue at https://golang.org/issues/new.

    Thank you to our contributors!

    @findleyr @heschik @pjweinb @leitzler @yangwenmai @matloob @golopot @muirdm