Ctrl + Alt + T 打开终端
sudo cp /etc/apt/sources.list.bak /etc/apt/sources.list
恢复历史镜像源
Ubuntu22.04 系统添加中输入法
首先,安装 Chinese
语言包
单击桌面右上角图标,点击 Settings
,在弹出的窗口中,点击 Region & Language
,然后点击 Manage Installed Languages
或者通过这种方式打开,打开 Show Applications
,找到 Language Support
并打开,弹出如下窗口,如下图所示
如果第一次点击的话,应该会弹出如下窗口,如果没有弹出直接跳过接下来的步骤。我的认为是,此窗口是安装 中文
语言包,点击 Install
,然后等待安装完成,弹出 Language Support
窗口
在 Language Support
窗口中,单击 Install/Remove Languages...
在弹出的 Installed Languages
窗口中,找到 Chinese(simplified)
,然后将其勾选,最后单击 Apply
,如果进行了第4步的话,会发现 Chinese(simplified)
已经安装了
接下来对中文输入法进行安装。打开终端,输入下列命令
sudo apt-get install ibus-pinyin
参考:为 Ubuntu22.04 系统添加中文输入法_ubuntu22.04中文输入法-CSDN博客
下载vim
sudo 命令安装vim
sudo apt-get update
sudo apt-get install vim
查看vim安装地址
which vim
安装vscode
手动下载
cd Downloads
sudo dpkg -i
tab补全
code 运行
下载
1.C/C++
2.Code Runner
3.Run in Terminal
launch.json
{
"version": "0.2.0",
"configurations": [
{
"name": "C/C++",
"type": "cppdbg",
"request": "launch",
"program": "${fileDirname}/${fileBasenameNoExtension}",
"args": [],
"stopAtEntry": false,
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": false,
"MIMode": "gdb",
"preLaunchTask": "compile",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
]
}
]
}
{
"version": "2.0.0",
"tasks": [{
"label": "compile",
"command": "g++",
"args": [
"-g",
"${file}",
"-o",
"${fileDirname}/${fileBasenameNoExtension}"
],
"problemMatcher": {
"owner": "cpp",
"fileLocation": [
"relative",
"${workspaceRoot}"
],
"pattern": {
"regexp": "^(.*):(\\d+):(\\d+):\\s+(warning|error):\\s+(.*)$",
"file": 1,
"line": 2,
"column": 3,
"severity": 4,
"message": 5
}
},
"group": {
"kind": "build",
"isDefault": true
}
}
]
}
安装netcat
sudo apt-get install netcat
安装net-tools
使用ipconfig