mirror of
				https://gitee.com/SuperManito/LinuxMirrors
				synced 2025-11-04 16:30:26 +08:00 
			
		
		
		
	优化 & 更新文档
This commit is contained in:
		@@ -1,6 +1,6 @@
 | 
			
		||||
#!/bin/bash
 | 
			
		||||
## Author: SuperManito
 | 
			
		||||
## Modified: 2025-04-09
 | 
			
		||||
## Modified: 2025-04-10
 | 
			
		||||
## License: MIT
 | 
			
		||||
## GitHub: https://github.com/SuperManito/LinuxMirrors
 | 
			
		||||
## Website: https://linuxmirrors.cn
 | 
			
		||||
@@ -16,7 +16,7 @@
 | 
			
		||||
mirror_list_default=(
 | 
			
		||||
    "阿里云@mirrors.aliyun.com"
 | 
			
		||||
    "腾讯云@mirrors.tencent.com"
 | 
			
		||||
    "华为云@repo.huaweicloud.com"
 | 
			
		||||
    "华为云@mirrors.huaweicloud.com"
 | 
			
		||||
    "网易@mirrors.163.com"
 | 
			
		||||
    "火山引擎@mirrors.volces.com"
 | 
			
		||||
    "清华大学@mirrors.tuna.tsinghua.edu.cn"
 | 
			
		||||
@@ -140,7 +140,7 @@ mirror_list_abroad=(
 | 
			
		||||
mirror_list_extranet=(
 | 
			
		||||
    "mirrors.aliyun.com"
 | 
			
		||||
    "mirrors.tencent.com"
 | 
			
		||||
    "repo.huaweicloud.com"
 | 
			
		||||
    "mirrors.huaweicloud.com"
 | 
			
		||||
    "mirrors.volces.com"
 | 
			
		||||
)
 | 
			
		||||
# 软件源内网地址列表
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
#!/bin/bash
 | 
			
		||||
## Author: SuperManito
 | 
			
		||||
## Modified: 2025-04-05
 | 
			
		||||
## Modified: 2025-04-10
 | 
			
		||||
## License: MIT
 | 
			
		||||
## GitHub: https://github.com/SuperManito/LinuxMirrors
 | 
			
		||||
## Website: https://linuxmirrors.cn
 | 
			
		||||
@@ -10,7 +10,7 @@
 | 
			
		||||
mirror_list_docker_ce=(
 | 
			
		||||
    "阿里云@mirrors.aliyun.com/docker-ce"
 | 
			
		||||
    "腾讯云@mirrors.tencent.com/docker-ce"
 | 
			
		||||
    "华为云@repo.huaweicloud.com/docker-ce"
 | 
			
		||||
    "华为云@mirrors.huaweicloud.com/docker-ce"
 | 
			
		||||
    "微软 Azure 中国@mirror.azure.cn/docker-ce"
 | 
			
		||||
    "网易@mirrors.163.com/docker-ce"
 | 
			
		||||
    "火山引擎@mirrors.volces.com/docker"
 | 
			
		||||
 
 | 
			
		||||
@@ -13,8 +13,12 @@ hide:
 | 
			
		||||
 | 
			
		||||
<div class="grid" markdown>
 | 
			
		||||
<figure style="margin: 0 auto" markdown>
 | 
			
		||||
  { width="300" }
 | 
			
		||||
  { width="300" }
 | 
			
		||||
  <div style="width: 350px; max-width: 100vw; height: 160px; position: absolute;">
 | 
			
		||||
    <span style="top: 50%; width: 50%; height: 80px; position: absolute; background-image: var(--hero-background-image); filter: blur(68px); transform: translate(-50%, -50%);">
 | 
			
		||||
    </span>
 | 
			
		||||
  </div>
 | 
			
		||||
  <img src="/assets/images/brand/light/2.png#only-light" alt="LinuxMirrors" style="width: 300px" />
 | 
			
		||||
  <img src="/assets/images/brand/dark/2.png#only-dark" alt="LinuxMirrors" style="width: 300px" />
 | 
			
		||||
  <figcaption>GNU/Linux 更换系统软件源脚本及 Docker 安装脚本</figcaption>
 | 
			
		||||
  <figcaption>一键脚本使换源更简单</figcaption>
 | 
			
		||||
</figure>
 | 
			
		||||
 
 | 
			
		||||
@@ -198,12 +198,13 @@ hide:
 | 
			
		||||
 | 
			
		||||
    - #### 纯净模式
 | 
			
		||||
 | 
			
		||||
        !!! tip "该功能目前处于试验阶段,滚动输出的命令日志可能存在无法预料的显示问题,目前暂未发现异常"
 | 
			
		||||
        为了便于开发者使用故推出此功能,启用后会精简脚本内容输出,建议搭配其它命令选项无交互使用
 | 
			
		||||
 | 
			
		||||
        ``` bash
 | 
			
		||||
        bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --pure-mode
 | 
			
		||||
        ```
 | 
			
		||||
        > 为了便于开发者使用故推出此功能,启用后会精简脚本内容输出,建议搭配其它命令选项无交互使用
 | 
			
		||||
 | 
			
		||||
        !!! tip "滚动输出的命令日志可能存在无法预料的显示问题,不过目前暂未发现异常"
 | 
			
		||||
 | 
			
		||||
- ### 关于服务报错无法启动
 | 
			
		||||
 | 
			
		||||
@@ -230,45 +231,3 @@ hide:
 | 
			
		||||
            > `Red Hat Enterprise Linux`   `CentOS`   `Rocky Linux`   `AlmaLinux`   `Fedora`   `openEuler`   `OpenCloudOS`   `Anolis OS`
 | 
			
		||||
 | 
			
		||||
        卸载完成后重新执行脚本安装即可
 | 
			
		||||
 | 
			
		||||
## 其它
 | 
			
		||||
 | 
			
		||||
提供一些常见服务的一键换源命令,用于备忘
 | 
			
		||||
 | 
			
		||||
### NPM
 | 
			
		||||
 | 
			
		||||
适用于 `npm` `yarn` `pnpm` 等
 | 
			
		||||
 | 
			
		||||
=== "淘宝源"
 | 
			
		||||
 | 
			
		||||
    ``` bash
 | 
			
		||||
    npm config set registry https://registry.npmmirror.com/
 | 
			
		||||
    ```
 | 
			
		||||
 | 
			
		||||
=== "腾讯云"
 | 
			
		||||
 | 
			
		||||
    ``` bash
 | 
			
		||||
    npm config set registry https://mirrors.tencent.com/npm/
 | 
			
		||||
    ```
 | 
			
		||||
 | 
			
		||||
### PYPI
 | 
			
		||||
 | 
			
		||||
适用于 `pip` `pip3`
 | 
			
		||||
 | 
			
		||||
=== "阿里云"
 | 
			
		||||
 | 
			
		||||
    ``` bash
 | 
			
		||||
    pip3 config set global.index-url https://mirrors.aliyun.com/pypi/simple/
 | 
			
		||||
    ```
 | 
			
		||||
 | 
			
		||||
=== "腾讯云"
 | 
			
		||||
 | 
			
		||||
    ``` bash
 | 
			
		||||
    pip3 config set global.index-url https://mirrors.tencent.com/pypi/simple/
 | 
			
		||||
    ```
 | 
			
		||||
 | 
			
		||||
=== "中科大"
 | 
			
		||||
 | 
			
		||||
    ``` bash
 | 
			
		||||
    pip3 config set global.index-url https://pypi.mirrors.ustc.edu.cn/simple/
 | 
			
		||||
    ```
 | 
			
		||||
 
 | 
			
		||||
@@ -6,6 +6,11 @@
 | 
			
		||||
    --md-default-bg-color--dark: hsla(var(--md-hue), 15%, 14%, 1);
 | 
			
		||||
    --view-transition-z-index-foreground: 999;
 | 
			
		||||
    --view-transition-z-index-background: 1;
 | 
			
		||||
    --hero-background-image: linear-gradient(90deg, rgba(177, 177, 177, 1) 50%, rgba(177, 177, 177, 1) 50%);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
[data-md-color-scheme='slate'] {
 | 
			
		||||
    --hero-background-image: linear-gradient(90deg, rgba(147, 147, 147, 1) 50%, rgba(147, 147, 147, 1) 50%);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
[data-md-color-primary=white] {
 | 
			
		||||
@@ -16,13 +21,21 @@
 | 
			
		||||
    --md-typeset-a-color: #2080f0;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
.md-typeset .admonition.tip, .md-typeset details.tip {
 | 
			
		||||
.md-typeset .admonition.tip,
 | 
			
		||||
.md-typeset details.tip {
 | 
			
		||||
    border-color: #009400;
 | 
			
		||||
}
 | 
			
		||||
.md-typeset .tip>.admonition-title, .md-typeset .tip>summary {
 | 
			
		||||
 | 
			
		||||
.md-typeset .tip>.admonition-title,
 | 
			
		||||
.md-typeset .tip>summary {
 | 
			
		||||
    background-color: #0094001a;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
[data-md-color-scheme="slate"] .md-typeset .admonition.quote,
 | 
			
		||||
.md-typeset details.quote {
 | 
			
		||||
    border-color: hsla(225deg, 15%, 90%, 0.24);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
.md-header {
 | 
			
		||||
    background-color: hsla(240, 9%, 75%, 0.33);
 | 
			
		||||
    -webkit-backdrop-filter: blur(8px);
 | 
			
		||||
@@ -50,10 +63,6 @@
 | 
			
		||||
    content: url(/assets/images/brand/svg/logo-dark.svg);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
[data-md-color-scheme="slate"] .md-typeset .admonition.quote, .md-typeset details.quote {
 | 
			
		||||
    border-color: hsla(225deg,15%,90%,0.24);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@font-face {
 | 
			
		||||
    font-family: 'SF Mono';
 | 
			
		||||
    src: url('./fonts/SF-Mono-Regular.otf');
 | 
			
		||||
@@ -140,7 +149,7 @@
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
.sponsor-item-toc {
 | 
			
		||||
    margin: 0; 
 | 
			
		||||
    margin: 0;
 | 
			
		||||
    padding: 14px !important;
 | 
			
		||||
    height: 66px !important;
 | 
			
		||||
    box-sizing: border-box;
 | 
			
		||||
@@ -233,21 +242,47 @@
 | 
			
		||||
    padding: 65px 25px 35px !important;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
[data-termynal] {
 | 
			
		||||
    color: #000 !important;
 | 
			
		||||
    background: #e6e6e6 !important;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
[data-md-color-scheme="slate"] [data-termynal] {
 | 
			
		||||
    color: #eeeeee !important;
 | 
			
		||||
    background: #252a33 !important;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
button[data-terminal-control] {
 | 
			
		||||
    color: var(--md-typeset-a-color) !important;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
[data-termynal]:after {
 | 
			
		||||
    color: #585858 !important;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
[data-md-color-scheme="slate"] [data-termynal]:after {
 | 
			
		||||
    color: #a2a2a2 !important;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
/* 切换主题动画 */
 | 
			
		||||
::view-transition-old(root),
 | 
			
		||||
::view-transition-new(root) {
 | 
			
		||||
    animation: none;
 | 
			
		||||
    mix-blend-mode: normal;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
.dark::view-transition-old(root) {
 | 
			
		||||
    z-index: var(--view-transition-z-index-foreground);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
.dark::view-transition-new(root) {
 | 
			
		||||
    z-index: var(--view-transition-z-index-background);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
::view-transition-old(root) {
 | 
			
		||||
    z-index: var(--view-transition-z-index-background)
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
::view-transition-new(root) {
 | 
			
		||||
    z-index: var(--view-transition-z-index-foreground);
 | 
			
		||||
}
 | 
			
		||||
}
 | 
			
		||||
@@ -457,7 +457,7 @@ $ bash ChangeMirrors.sh --help
 | 
			
		||||
问题报告 https://github.com/SuperManito/LinuxMirrors/issues
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
接下来是一些高级用法的举例
 | 
			
		||||
下面是一些高级用法的举例
 | 
			
		||||
 | 
			
		||||
- ### 指定软件源地址
 | 
			
		||||
 | 
			
		||||
@@ -596,12 +596,13 @@ $ bash ChangeMirrors.sh --help
 | 
			
		||||
 | 
			
		||||
- ### 纯净模式
 | 
			
		||||
 | 
			
		||||
    !!! tip "该功能目前处于试验阶段,滚动输出的命令日志可能存在无法预料的显示问题,目前暂未发现异常"
 | 
			
		||||
    为了便于开发者使用故推出此功能,启用后会精简脚本内容输出,建议搭配其它命令选项无交互使用
 | 
			
		||||
 | 
			
		||||
    ``` bash
 | 
			
		||||
    bash <(curl -sSL https://linuxmirrors.cn/main.sh) --pure-mode
 | 
			
		||||
    ```
 | 
			
		||||
    > 为了便于开发者使用故推出此功能,启用后会精简脚本内容输出,建议搭配其它命令选项无交互使用
 | 
			
		||||
 | 
			
		||||
    !!! tip "滚动输出的命令日志可能存在无法预料的显示问题,不过目前暂未发现异常"
 | 
			
		||||
 | 
			
		||||
---
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user