下载安装

初入CL,先下载下载安装,在激活方法永久激活

PS:建议2022版

创建项目

image-20230327122153318

安装插件(快速版)

Jetbrains插件商店

image-20230324200423844image-20230324200426828

接着选择你已经下载到本地的插件

image-20230324200537259

image-20230327121049773

基础设置

设置字体image-20230324200247162

image-20230325093018215

image-20230327120946109

具体更多查看基础设置

创建多运行文件

image-20230327121406711

image-20230327121454803

主文件下的CMakeList,要添加

1
2
ADD_SUBDIRECTORY(线性表) #添加的文件夹名
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/bin")

添加文件夹下面的CMakeList,要添加

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
include_directories(.)
file(GLOB_RECURSE ALL_SOURCE "*.cpp" "*.c" "*.h")

add_library( # Sets the name of the library.
bladderJNI

# Sets the library as a shared library.
SHARED

# Provides a relative path to your source file(s).

#自动添加目录下的C文件
${ALL_SOURCE}
)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/bin")

如果想摆脱cmake文件

前提得是2022.3版之后
不需要cmake也能运行多个文件

image-20230327214709262

image-20230327214705198

C语言使用VScode

使用