Skip to content

Commit 418bcfc

Browse files
authored
Merge pull request #117 from Rexbas/clion-pixi
Add description about how to use pixi in CLion
2 parents ff7db1c + 2abe5a8 commit 418bcfc

File tree

3 files changed

+22
-0
lines changed

3 files changed

+22
-0
lines changed

gettingstarted/CLion.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,28 @@ If you don't already have CLion installed, download it, license it, install it p
1212

1313
**IDE:** From upper left, choose Project from Version Control. Use https://github.com/FreeCAD/FreeCAD
1414
![Pict8](./resources/CLionPythonDebug8.png)
15+
16+
### Configure Pixi Toolchain (Optional)
17+
If you choose to use Pixi to get the dependencies then you need to configure a CLion toolchain and assign it to your CMake profile.
18+
1. Run `pixi shell` in the local FreeCAD directory to get all packages, this is also needed to update the environment after the `pixi.toml` has been changed.
19+
2. Go to Settings → Build, Execution, Deployment → Toolchains.
20+
3. Create a new "System" toolchain.
21+
4. Click on "Add environment" and select "From file".
22+
5. Enter the location of the `pixi-default.bat` for Windows or otherwise the `pixi-default.bash` script in the "Environment file" field. The file can be found in the FreeCAD repository in contrib/clion/pixi
23+
24+
![PixiPict1](./resources/CLionPixi1.png)
25+
26+
6. Go to Settings → Build, Execution, Deployment → CMake.
27+
7. Select the "conda-[your os]-debug" or "conda-[your os]-release" preset and duplicate it.
28+
8. Enable the duplicated profile and assign the created toolchain to this profile.
29+
9. If on Windows, you also need to select the Visual Studio generator.
30+
31+
![PixiPict2](./resources/CLionPixi2.png)
32+
33+
Note: If CMake does not detect any packages from the .pixi folder then the toolchain script may have failed.
34+
This may be resolved by using the absolute path to your FreeCAD repository in the `pixi-default.bash` script.
35+
36+
1537
### Building CMake
1638

1739
CLion should automatically refresh the CMake build for the application. You see results or rerun using the cmake
34.1 KB
Loading
57.6 KB
Loading

0 commit comments

Comments
 (0)