网站有做货,手机网站开发合同,网络规划设计方案模板,东莞公司品牌网站建设第一步#xff1a;安装 WSL
参考微软提供的官方指南
在管理员模式下打开 PowerShell 或 Windows 命令提示符#xff0c;方法是右键单击并选择“以管理员身份运行”#xff0c;输入 wsl --install 命令#xff0c;然后重启计算机。
第二步#xff1a;安装 ubuntu22.04
…第一步安装 WSL
参考微软提供的官方指南
在管理员模式下打开 PowerShell 或 Windows 命令提示符方法是右键单击并选择“以管理员身份运行”输入 wsl --install 命令然后重启计算机。
第二步安装 ubuntu22.04
从windows store 中下载安装
第三步修改国内源
打开文件资源管理器打开左侧的Linux文件夹定位到 etc/apt/目录将 sources.list 复制保存为 sources.list.bk。
用记事本程序打开 sources.list将其中内容修改为国内源如清华源 deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy main restricted universe multiverse deb http s://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-updates main restricted universe multiverse deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-backports main restricted universe multiverse deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-security main restricted universe multiverse 第四步启动 ubuntu22.04并更新
设置用户名、密码。sudo apt update sudo apt upgrade -y 更新 ubuntu 系统。
第五步安装所需软件包
sudo apt install cargo
第六步使用WSL终端编译Rust程序
在win11系统下打开 VScode即可使用 WSL 终端编译 Rust 程序 。