VSCode-swift v0.3.0

Version 0.3.0 of the Visual Studio Code Swift extension has been released.

You can find the changelog here.

Additions of note include:

A right click menu has been added to the Package Dependencies view which has options to use a local copy of a package dependency rather than the one downloaded from the web. This is useful if you want to work on both a product and one of its dependencies at the same time. Internally this uses swift package edit which is soon to be deprecated but we will update this feature to use whatever replaces package edit.

We have added a command Run Swift Script to run the currently open file as a Swift script. If the file has not been saved yet it will be saved to a temporary file so it can be parsed. With this you can treat an unsaved swift file as a pseudo Swift Playground.

Swift packages no longer need to be in the root folder of your workspace. You can also have multiple Swift packages folders in one workspace. This can be used to create complex workspaces which for instance include multiple Swift lambdas or combining a web frontend with its Vapor backend. Swift packages in subfolders are not activated automatically though. You need to open a file from the package for it to generate build tasks and debug launch configurations.