26 Star 21 Fork 17

openKylin / ide-project-manager

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README

项目管理器 Kylin Project Manager

中文|English

中文说明

1、插件安装

  • 通过插件筛选器,找到 Kylin Project Manager 插件
  • 点击安装
  • 完成安装。
  • 如果是版本升级则需要重新加载主程序插件才生效,请根据提示操作完成安装。

2、项目管理插件操作区

  • 在资源管理器展开“项目操作区”
  • 提供项目创建、配置、编译、调试、运行、打包等相关功能入口

3、创建新的项目

  • 点击“创建新的项目”,也可以通过 Ctrl+Shift+P 调起命令窗口,输入“创建项目”或“project.createProject”,选择 PROJECT:创建项目,调起页面。
  • 在右侧编辑区弹出“创建项目”页面。
  • 页面内包括:
    • 语言选择树(目前包含 c/c++ 和 Java)
      • 可以通过点击切换选择不同的语言类型来创建。
    • 创建项目录入区
      • 与语言选择树关联,切换不同的语言,会显示不同的录入内容页面。
      • 包括 关闭、上一步/下一步、创建 等功能按钮

3.1、创建C/C++项目

  • 在资源管理器展开“项目操作区”
  • 点击“创建新的项目”,也可以通过 Ctrl+Shift+P 调起命令窗口,输入“创建项目”或“project.createProject”,选择 PROJECT:创建项目,调起页面。
  • 在右侧编辑区弹出“创建项目”页面。
  • 选择C/C++ C项目

3.1.1、第一页

  • 点击“项目类型”
  • 可以切换选择“默认项目”、“静态库项目”、“动态库项目”。
  • 点击“项目构建方式”
  • 可以切换选择“makefile”、“cmake”。
  • 点击下一页

3.1.2、第二页

  • 输入合法项目名称(必填)
  • 选择项目目录(必填)
  • 输入更多信息
  • 点击下一页

3.1.3、第三页

  • 输入合法编译输出文件名(必填)
  • 输入更多编译调试运行参数
  • 点击创建

3.1.4、创建成功

  • 弹出 C/C++环境检查通过提示
  • 弹出创建项目成功提示
  • 弹出新项目页面(如当前页面未打开项目,则会在本视窗打开)
  • 点击“是,我信任此作者”,即可进行后续项目编写使用。

3.2、创建简单Java项目

  • 在资源管理器展开“项目操作区”
  • 点击“创建新的项目”,也可以通过 Ctrl+Shift+P 调起命令窗口,输入“创建项目”或“project. createProject”,选择 PROJECT:创建项目,调起页面。
  • 在右侧编辑区弹出“创建项目”页面。
  • 选择Java Java项目

3.2.1、输入信息

  • 输入合法项目名称(必填)
  • 选择项目目录(必填)
  • 输入 JDK 目录(必填)
  • 输入“输出目录”
  • 点击创建

3.2.2、创建成功

  • 弹出创建项目成功提示(注:0.1.1 版本缺失,下一版本支持)
  • 弹出新项目页面(如当前页面未打开项目,则会在本视窗打开)
  • 点击“是,我信任此作者”,即可进行后续项目编写使用。

3.3、使用构建工具创建Java项目

  • 暂不支持

4、配置当前项目

4.1、配置C/C++项目

  • 打开刚才创建的 C/C++项目 testC
  • 点击“配置当前项目”
  • 在右侧编辑区弹出“配置项目”页面。
  • 可修改项目编译输出文件内容。
  • 可选择修改编译、调试、运行参数。
  • 第二页点击保存,显示“保存成功”。完成项目编译、调试、运行参数的配置。

4.1.1、配置详细介绍

  • 项目识别: 包含vsproject.ide.json文件,内容为json数据

    • 有"language"属性

      属性值为"c"、"c++"

    • 有"buildTools"属性

      属性值为"makefile"、"cmake"

  • tasks.json配置文件

    • 文件位置:.vscode/

    • 文件作用:用来告诉 IDE 如何构建(编译)程序

    • testC项目的tasks.json实例

      说明:该build脚本,用来实现对testC项目进行编译,本实例是通过makefile实现编译。

        {
        "version": "2.0.0",
        "tasks": [
          {
          "label": "build",
          "type": "shell",
          "group": {
            "kind": "build",
            "isDefault": true
          },
          "linux": {
            "command": "bash",
            "args": [
            "-c",
            "make"
            ]
          }
          },
          ...
        ]
        }
      
    • Makefile 与配置关系 本testC项目中,Makefile文件内预制了编译和运行参数。 例如:

      • 用户在配置页面修改“编译输出文件”内容,并保存时。 实际Makefile文件内的 KConfig_outputFileName 值会跟随改变。 这样当IDE执行项目编译,调用tasks.json的build项,执行make build时,实际生成的编译输出文件会跟随Makefile文件内的KConfig_outputFileName 定义而改变。

          # KylinCode 编译配置项
          KConfig_outputFileName = main
          KConfig_compileDebugLevel = -g
          KConfig_WarningLevel = 
          KConfig_OptimizeLevel = 
          KConfig_ExtraPara = 
          KConfig_IncludesPath = 
          KConfig_LibraryPath = 
          KConfig_Libraries = 
        
      • 其他配置项修改原理与“编译输出文件”相同。

      • cmake类型与makefile原理相同。

4.2、配置Java项目

  • 打开刚才创建的 Java 项目 testJava

  • 点击“配置当前项目”

  • 在右侧编辑区弹出“配置项目”页面。

  • 打开调试配置文件 launch.json,如下代码。用来支持java项目的调试功能。

    {
      "version": "0.2.0",
      "configurations": [
          {
              "type": "java",
              "name": "Launch Current File",
              "request": "launch",
              "mainClass": "${file}",
              "args": ""
          },
          {
              "type": "java",
              "name": "Launch App",
              "request": "launch",
              "mainClass": "testgradle.App",
              "projectName": "app"
          }
      ]
    }
  • 打开任务文件 tasks.json,如下文,用来支持项目的编译和调试功能;

    {
        "version": "2.0.0", 
        "tasks": [
            {
                "label": "build", 
                "type": "shell", 
                "options": {
                    "cwd": "${workspaceFolder}"
                }, 
                "command": "javac", 
                "args": [
                    "src/main.java",
                    "-sourcepath",
                    "src",
                    "-classpath",
                    "${config:java.project.referencedLibraries}",
                    "-d", 
                    "${config:java.project.outputPath}"
                ]
            }, 
            {
                "label": "run", 
                "type": "shell", 
                "options": {
                    "cwd": "${workspaceFolder}"
                }, 
                "command": "java", 
                "args": [
                    "-cp", 
                    "${config:java.project.outputPath}", 
                    "main"
                ], 
                "dependsOn": [
                    "javac"
                ]
            }, 
            {
                "label": "clean", 
                "type": "shell", 
                "options": {
                    "cwd": "${workspaceFolder}"
                }, 
                "command": "rm $(find . -name \"*.class\")"
            }
        ]
    }
  • 打开 Java 类路径配置

    可以修改源码路径、输出路径、添加依赖库等;修改结果会保存在settings.json

  • 打开打开工作区设置页。

  • 打开工作区设置 json 文件。

4.3、配置Other项目

  • 打开其他类型的测试项目
  • 点击“配置当前项目”
  • 在右侧编辑区弹出“配置项目”页面。

包括以下:

  • 打开调试配置文件launch.json,点击可以打开文件编辑调试配置。(如当前项目没有,会弹出创建选择) 创建方法如下:

    • 点击菜单中的运行->添加配置
  • launch.json文件创建成功

  • 打开任务文件 tasks.json,点击可以打开文件编辑编译、运行等任务。(如果当前项目没有,会弹出创建选择)

    创建方法如下:

    • 点击菜单中的终端->配置任务->使用模板创建tasks.json文件->others

    • tasks.json文件创建成功

      创建的tasks.json默认内容如下:

      {
      // See https://go.microsoft.com/fwlink/?LinkId=733558
      // for the documentation about the tasks.json format
      "version": "2.0.0",
      "tasks": [
          {
              "label": "echo",
              "type": "shell",
              "command": "echo Hello"
          }
        ]
      }
    • 根据项目情况修改tasks.json文件,以testJava为例修改后内容如下:

      {
          "label": "build", 
          "type": "shell", 
          "options": {
              "cwd": "${workspaceFolder}"
          }, 
          "command": "javac", 
          "args": [
              "src/main.java",
              "-sourcepath",
              "src",
              "-classpath",
              "${config:java.project.referencedLibraries}",
              "-d", 
              "${config:java.project.outputPath}"
          ]
      }, 
      {
          "label": "run", 
          "type": "shell", 
          "options": {
              "cwd": "${workspaceFolder}"
          }, 
          "command": "java", 
          "args": [
              "-cp", 
              "${config:java.project.outputPath}", 
              "main"
          ], 
          "dependsOn": [
              "javac"
          ]
      }

      修改后,即可支持通过任务进行编译、运行等操作。

5、编译

编译功能入口,为项目开发提供快捷操作。

  • 依赖.vscode/tasks.json 文件定义。
  • 点击会打开tasks.json的 build项目执行,通过终端执行编译。

6、运行

运行功能入口,为项目开发提供快捷操作。

  • 依赖.vscode/tasks.json 文件定义。
  • 点击会打开tasks.json的所有项目,选择run项目,选择继续而不扫描任务输出,通过终端执行程序运行。

7、调试

调试功能入口,点击进入“调试”功能

  • 依赖.vscode/launch.json文件

  • 点击“调试”按钮,进入调试页面。

  • 如图,此时项目没有launch.json文件。

  • 点击“创建 launch.json 文件。

  • 弹出选择调试器,请根据项目类型选择相应的调试器。

  • 创建完成,会进入运行调试页面。可以按项目需要修改launch.json,可以点击左侧选择需要的调试配置项

  • 点击绿色三角开始调试。

8、插件依赖说明

  • java:
    • openjdk 11
  • 打包:
    • dpkg
    • rpm
    • maven 3.6.3+

9、下载链接

10、源码构建说明

10.1 yarn 失败

配置淘宝源
 yarn config set registry http://registry.npm.taobao.org/

10.2 插件构建

cd ${projectpath}/web
yarn
cd ${projectpath}/
yarn
yarn run compile

10.3 打包

cd ${projectpath}/
yarn
yarn run compile
yarn run package

EnglishDescription

Introduction

1. Extension installation

  • Find the Kylin Project Manager extension through the extension filter

  • Click to install

  • Complete the installation.

  • If it is a version upgrade, the main program extension needs to be reloaded to take effect. Please follow the prompts to complete the installation.

2. Project management extension operation area

  • Expand the "Project Operations Area" in Explorer

  • Provide entry points for project creation, configuration, compilation, debugging, running, packaging, and other related functions

3. Create new project

  • Click on "Create New Project" or use Ctrl+Shift+P to bring up a command window, enter "Create Project" or "project. createProject", select PROJECT: Create Project, and bring up the page.

  • The "Create Project" page pops up in the editing area on the right.

  • The page includes:

  • Language selection tree (currently including c/c++and Java)

  • You can select different language types to create by clicking on the switch.

  • Create project entry area

  • Associated with the language selection tree, switching between different languages will display different input content pages.

  • Including function buttons such as close, previous/next, create, etc

4. Configure the current project

4.1. Configuring C/C++Projects

  • Open the C/C++project you just created, testC

  • Click on 'Configure Current Project'

  • The "Configuration Items" page pops up in the editing area on the right.

  • The content of the project compilation output file can be modified.

  • You can choose to modify compilation, debugging, and running parameters.

  • On the second page, click Save and the message 'Save Successfully' will appear. Complete project compilation, debugging, and configuration of running parameters.

4.2. Configuring Java Projects

  • Open the Java project you just created, testJava

  • Click on 'Configure Current Project'

  • The "Configuration Items" page pops up in the editing area on the right.

  • Open the debugging configuration file launch.json,

  • Open the task file tasks.json,

  • Open Java class path configuration

You can modify the source code path, output path, add dependency libraries, etc; The modification results will be saved in settings.json

  • Open the workspace settings page.

  • Open the workspace settings JSON file.

4.3. Configure Other Project

  • Open other types of test projects

  • Click on 'Configure Current Project'

  • The "Configuration Items" page pops up in the editing area on the right.

Including the following:

  • Open the debugging configuration file launch.json, click to open the file and edit the debugging configuration. (If the current project does not have one, a create selection will pop up)

5. Compilation

Compilation function entry, providing quick operations for project development.

  • Dependency on the. vscode/tasks.json file definition.

  • Clicking will open the build project execution for tasks.json, which will be compiled through the terminal.

6. Operation

Run the function entry to provide quick operations for project development.

  • Dependency on the. vscode/tasks.json file definition.

  • Clicking will open all the projects in tasks.json, select the run project, choose to continue without scanning the task output, and run the program through the terminal execution.

7. Debugging

Debug function entry, click to enter the "Debug" function

  • Dependency on the. vscode/launch.json file

  • Click the "Deb

8. Extension Dependencies

  • Java:
    • OpenJDK 11
  • Packaging:
    • dpkg
    • rpm
    • Maven 3.6.3+

9. Download link

10. Source Code Build Instructions

10.1 Yarn Failure

Configure Taobao registry
yarn config set registry http://registry.npm.taobao.org/

10.2 Extension Build

cd ${projectpath}/web
yarn
cd ${projectpath}/
yarn
yarn run compile

10.3 Packaging

cd ${projectpath}/
yarn
yarn run compile
yarn run package

空文件

简介

项目管理器 (Kylin Project Manager) 展开 收起
取消

发行版 (5)

全部

贡献者

全部

近期动态

加载更多
不能加载更多了
1
https://gitee.com/openkylin/ide-project-manager.git
git@gitee.com:openkylin/ide-project-manager.git
openkylin
ide-project-manager
ide-project-manager
master

搜索帮助

53164aa7 5694891 3bd8fe86 5694891