🧁 pacman配置
壹丨pacman配置代理¶
打开msys终端,执行:
#export http_proxy='http://username:[email protected]:3128'
#export ftp_proxy='http://username:[email protected]:3128'
export http_proxy='http://192.168.6.200:3128'
export https_proxy='http://192.168.6.200:3128'
export ftp_proxy='http://192.168.6.200:3128'
贰丨pacman配置源¶
第一步,打开配置文件:MSYS2终端上,打开以下文件
nano /etc/pacman.d/mirrorlist.mingw32
nano /etc/pacman.d/mirrorlist.mingw64
nano /etc/pacman.d/mirrorlist.msys
第二步,每个文件顶部添加国内镜像源,如中科大源:
Server = https://mirrors.ustc.edu.cn/msys2/$repo/$arch
第三步,更新数据:
pacman -Syyu
叁丨pcaman禁用SSL验证¶
第一步,打开配置文件
nano /etc/pacman.conf
第二步,修改配置,在[options]部分
[options]
SigLevel = Never
第三步,更新数据:
pacman -Syu
恢复SSL验证:
[options] SigLevel = Required
肆丨pacman卸载包¶
搜索相关名称的包:
pacman -Q | grep mingw-w64
卸载mingw-w64-ucrt-x86_64前缀的包
pacman -Rns $(pacman -Qq | grep mingw-w64-ucrt-x86_64)