安装

wsl --install 默认Ubuntu

sudo vim /etc/wsl.conf 默认登录用户切换为 root

wsl --list --all

wsl --unregister Ubuntu 删除

wsl --shutdown

wsl -d Ubuntu

wsl.exe -d Ubuntu 启动它

wsl2子系统的备份和还原 - CharyGao - 博客园

node配置

    # Download and install nvm:
    curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash

    # in lieu of restarting the shell
    \. "$HOME/.nvm/nvm.sh"

    # Download and install Node.js:
    nvm install 22

    # Verify the Node.js version:
    node -v # Should print "v22.17.1".
    nvm current # Should print "v22.17.1".

    # Verify npm version:
    npm -v # Should print "10.9.2".



    npm install -g nrm

    nrm ls

    nrm use <源名称>

    npm config set registry https://registry.npmmirror.com #手动设置淘宝源

    npm config set registry https://registry.npmjs.org/ #手动设置官方源
https://www.cnblogs.com/fps2tao/p/18198038

git设置

    apt-get install git

    git config user.name "xiao"

    git config user.email "xiao@example.com"

vscode远程链接

在Windows中使用WSL和VS Code搭建出友好的终端开发环境\_vs code wsl-CSDN博客

https://www.cnblogs.com/rthete/p/17548200.html

https://www.cnblogs.com/jixiaohua/p/15533539.html

最后修改:2025 年 08 月 07 日
快来和我交易吧。