You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/HowToGuides/GettingStarted.md
+23Lines changed: 23 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -25,6 +25,7 @@ toolchain as a one-off, there are a couple of differences:
25
25
-[Editing code](#editing-code)
26
26
-[Setting up your fork](#setting-up-your-fork)
27
27
-[First time Xcode setup](#first-time-xcode-setup)
28
+
-[Other IDEs setup](#other-ides-setup)
28
29
-[Editing](#editing)
29
30
-[Incremental builds with Ninja](#incremental-builds-with-ninja)
30
31
-[Incremental builds with Xcode](#incremental-builds-with-xcode)
@@ -358,6 +359,28 @@ select the following schemes:
358
359
run.
359
360
<!-- TODO: Insert SourceKit/stdlib specific instructions? -->
360
361
362
+
### Other IDEs setup
363
+
364
+
You can also use other editors and IDEs to work on Swift.
365
+
366
+
#### IntelliJ CLion
367
+
368
+
CLion supports CMake and Ninja. In order to configure it properly, build the swift project first using the `build-script`, then open the `swift` directory with CLion and proceed to project settings (`cmd + ,`).
369
+
370
+
In project settings, locate `Build, Execution, Deployment > CMake`. You will need to create a new profile named `RelWithDebInfoAssert` (or `Debug` if going to point it at the debug build). Enter the following information:
371
+
372
+
- Name: mirror the name of the build configuration here, e.g. `RelWithDebInfoAssert` or `Debug`
373
+
- Build type: This corresponds to `CMAKE_BUILD_TYPE` so should be e.g. `RelWithDebInfoAssert` or `Debug`
374
+
- latest versions of the IDE suggest valid values here. Generally `RelWithDebInfoAssert` is a good one to work with
- replace the `SOME_PATH` to the path where your `swift-project` directory is
380
+
- the CMAKE_BUILD_TYPE should match the build configuration name, so if you named this profile `RelWithDebInfo` the CMAKE_BUILD_TYPE should also be `RelWithDebInfo`
381
+
382
+
With this done, CLion should be able to successfully import the project and have full autocomplete and code navigation powers.
383
+
361
384
### Editing
362
385
363
386
Make changes to the code as appropriate. Implement a shiny new feature!
0 commit comments