vscode查看Linux内核源码,vscode 查看Redis源码

简介

最近在学习Redis源码,主要是目前负责华为产品FusionInsight HD中Redis组件的相关事务,不得不学习Redis源码。本文主要讲述的是怎么经过vscode查看Redis的源码(Linux平台下面).html

配置

在项目下面增长文件夹 .vscode,而且新建文件:launch.json 、tasks.json、 c_cpp_properties.json,而且在文件中添加下面内容:c++

launch.json:redis

{

"version": "0.2.0",

"configurations": [

{

"name": "build",

"type": "cppdbg",

"request": "launch",

"program": "${workspaceFolder}/src/redis-server",

"args": [

"redis.conf"

],

"stopAtEntry": true,

"cwd": "${workspaceFolder}",

"environment": [],

"externalConsole": false,

"MIMode": "gdb",

"preLaunchTask": "shell"

}

]

}

tasks.json:shell

{

"version": "2.0.0",

"tasks": [

{

"label": "shell",

"type": "shell",

"command": "/usr/bin/make"

}

]

}

c_cpp_properties.jsonjson

{

"configurations": [

{

"name": "Linux",

"includePath": [

"${workspaceFolder}/**"

],

"defines": [],

"compilerPath": "/usr/bin/clang",

"cStandard": "c11",

"cppStandard": "c++14",

"intelliSenseMode": "clang-x64"

}

],

"version": 4

}

运行

使用快捷键F5进行编译调试。学习

标 题:《vscode 查看Redis源码》

做 者:zeekling

提 示:转载请注明文章转载自我的博客:小令童鞋ui

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值