ubuntu基本配置

记录一下每次重新安装系统之后都要进程的操作

更新源

更新源的教程

bash 复制代码
sudo bash -c "cat << EOF > /etc/apt/sources.list && apt update 
deb http://mirrors.aliyun.com/ubuntu/ jammy main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ jammy main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ jammy-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ jammy-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ jammy-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ jammy-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ jammy-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ jammy-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ jammy-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ jammy-backports main restricted universe multiverse
EOF"

安装软件

  • gcc
  • g++
  • gdb
  • git
  • vim

安装

spacevim

美化

  1. zsh

    bash 复制代码
    sudo apt install git zsh -y 
  2. oh-my-zsh,主题默认为'ys'

    bash 复制代码
    sh -c "$(curl -fsSL https://gitee.com/pocmon/ohmyzsh/raw/master/tools/install.sh)"
  3. 切换默认 shell

    bash 复制代码
    chsh -s $(which zsh)

    注销之后登录

  4. spaceVim

    修改tab为4

    默认的代码缩进值是 2,缩进的大小由选项 default_indent 设置, 如果希望使用 4 个空格作为缩进,只需要在 SpaceVim 配置文件中加入如下内容:

    bash 复制代码
    [options]
        default_indent = 4

    default_indent 这一选项的值,将被赋值到 Vim 的选项:&tabstop&softtabstop&shiftwidth。默认情况下,输入的 <Tab> 会被自动展开成对应缩进数量的空格, 可通过设置选项 expand_tab 的值为 false 来禁用这一特性:

    bash 复制代码
    [options]
        default_indent = 4
        expand_tab = true

vscode ssh

使用体验更好

gcc、g++保证了头文件

gdb 支持了运行和调试

相关推荐
likfishdn6 分钟前
Linux的文件与目录管理
linux·运维·服务器
chian-ocean26 分钟前
Linux 文件缓冲区:高效数据访问的幕后推手
linux·运维·服务器
加油=^_^=28 分钟前
【Linux】进程优先级 | 进程调度(三)
linux·运维·服务器
若云止水37 分钟前
Ubuntu 下 nginx-1.24.0 源码分析 - ngx_init_cycle 函数 - 详解(4)
数据库·nginx·ubuntu
吃汤圆的抹香鲸1 小时前
GoLand 安装包 绿色版 Win,Mac,Linux 包含IntelliJ全家桶 专为Go语言设计的集成开发环境(IDE)
linux·windows·macos·go·intellij-idea·go1.19
追寻光1 小时前
Cannot find a valid baseurl for repo: base/7/x86_64
linux
元气满满的热码式1 小时前
Docker数据卷操作实战
linux·运维·docker·云原生·容器
陆沙1 小时前
deepseek-r1-centos-本地服务器配置方法
linux·服务器·centos
北京耐用通信1 小时前
航空装配自动化神器Ethercat转profient网关搭配机器人精准控制
运维·机器人·自动化
吃汤圆的抹香鲸2 小时前
Rider 安装包 绿色版 Win/Mac/Linux 适合.NET和游戏开发者使用 2025全栈开发终极指南:从零配置到企业级实战
linux·运维·windows·sql·游戏·macos·.net