A hands-on introduction for SDE 1.0 release.
Quick Preview
Explanation
-
You can start coding with the empty folder.
-
First, as I mentioned in the project, the current design and implementations are convention-based. Basically we follow the SPM convention. So, you should set up conventions early and as possible to help tools to understand all you want.
-
write your Pacakge.swift to config the whole project, like dependencies and layouts if have.
-
Start main.swift or some other sources(main.swift is the convention for the executable product). When tpying with '.', ':', '(', you'll get code suggestions. Because it is found in many other cases the sourcekit like to give useless suggestion or nothing. But you can trigger suggestion by shortcut anytime, like "do" for "donothing()" shown in the preview.
-
Not only the single source file, SDE supports to provide helps in the project-wide sources, like click a symbol to go to its declartion in another file.
-
To make editor to show diagnostics for your sources, you need to build the project. This may be slow when first time. I guess you are still OK, because you skip the boring configure time like done in IDEA or Eclipse for JAVA or others:)
-
SDE will give you an indicator for building in the left of status bar. You can watch the stdout of building in the output console named "SPM"(or tell me if you have a better name for this console?). If the building failed, you got an red indicator.
-
By default, it will fire a build when every save. Because "save", as a convention, can help SPM and then tools understand the latest of your project. This is commonly quick and done in background process. But you can disable this behavior. And SDE also provides a shortcut 'Alt+B' for trigging a build by manual.
-
Also note, you can format the whole document or selection:)
-
Debugging is done as your expection. However, but SDE only support the variables and call stack view. Soon, I will add the expression evaluation. Sometimes, you may meet "can not read ...." when Debugging. This may be the bug of lldb at linux. I continue to investigate this problem and its solution to help your futher.
There is a example demo project if you just want to do a quick experiment.
(NOTE: sorry, the development of SDE project has been discontinued because the author can not foresee a well formed ecosystem in the Swift backend side. But all sources are there for who's interests.)