mirror of
https://gitee.com/SuperManito/LinuxMirrors
synced 2025-11-04 00:10:27 +08:00
3.3 KiB
3.3 KiB
hide
| hide | |
|---|---|
|
执行命令
建议在使用前确认目标镜像站是否支持您正在使用的操作系统
=== ":material-home: 国内使用(默认)"
``` bash
bash <(curl -sSL https://linuxmirrors.cn/main.sh)
```
??? quote "原始执行脚本方法"
=== ":simple-github: GitHub"
``` bash
bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh)
```
=== ":simple-gitee: Gitee"
``` bash
bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh)
```
=== ":material-school: 国内教育网使用"
``` bash
bash <(curl -sSL https://linuxmirrors.cn/main.sh) --edu # (1)!
```
1. 通过 `--edu` 命令选项来使用中国大陆教育单位软件源
??? quote "原始执行脚本方法"
=== ":simple-github: GitHub"
``` bash
bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --edu
```
=== ":simple-gitee: Gitee"
``` bash
bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --edu
```
=== ":octicons-globe-16: 海外使用"
``` bash
bash <(curl -sSL https://linuxmirrors.cn/main.sh) --abroad # (1)!
```
1. 通过 `--abroad` 命令选项来使用海外软件源
??? quote "原始执行脚本方法"
=== ":simple-github: GitHub"
``` bash
bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --abroad
```
=== ":simple-gitee: Gitee"
``` bash
bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --abroad
```
注意事项
- :material-numeric-1:{style="color: #3CA7E5"} 需使用
Root用户执行脚本 -
切换命令为
sudo -i或su root,不同系统环境使用的命令不一样,因为有些系统没有在初始安装时为 Root 用户设置固定密码(例如Ubuntu)所以需要使用sudo指令来提权 - :material-numeric-2:{style="color: #3CA7E5"} 建议使用
SSH远程工具 -
如果你使用的系统终端界面不支持
UTF-8编码那么将无法正常显示中文内容,导致无法正确选择交互内容。大部分系统都会自动开启该服务,否则请参考启用方法 - :material-numeric-3:{style="color: #3CA7E5"} 如果是首次在新系统上执行脚本
-
当前执行方式依赖
curl指令来获取脚本内容并执行,所以需要先通过包管理工具来安装该软件包,否则会报错Command not found,安装方法详见常见问题,若无法安装就复制源码到本地新建.sh脚本,然后通过bash手动执行
!!! note ":octicons-heart-fill-24:{ .heart style="color: red" } 如果您觉得这个项目不错对您有所帮助的话,方便在仓库右上角给颗 ⭐ 并分享给更多的朋友吗?"