Update
44
README.md
@@ -1,54 +1,42 @@
|
||||
# LinuxMirrors
|
||||
<a href="https://github.com/SuperManito/LinuxMirrors"><img src="./icon/github-1.svg" width="34" height="42"></a>
|
||||
<a href="https://github.com/SuperManito/LinuxMirrors"><img src="./icon/github-2.svg" width="70" height="52"></a>
|
||||
ㅤ<a href="https://gitee.com/SuperManito/LinuxMirrors"><img src="./icon/gitee.svg" width="100" height="50"/></a>
|
||||
<a href="https://blog.csdn.net/u013246692/article/details/113124295"><img src="./icon/csdn.png" width="100" height="50"/></a>
|
||||
# [LinuxMirrors](./img/logo.png)
|
||||
|
||||
<a href="https://github.com/SuperManito/LinuxMirrors"><img src="./img/icon/github-1.svg" width="34" height="42"></a>
|
||||
<a href="https://github.com/SuperManito/LinuxMirrors"><img src="./img/icon/github-2.svg" width="70" height="52"></a>
|
||||
<a href="https://gitee.com/SuperManito/LinuxMirrors"><img src="./img/icon/gitee.svg" width="100" height="50"/></a>
|
||||
- __`GNU/Linux` 一键更换国内软件源脚本__
|
||||
- __本项目旨在为从事计算机相关行业的朋友们提供便利__
|
||||
- __理论支持所有架构的环境,`arm64` 环境已经过测试__
|
||||
> 🏷️点击上方图标可快速跳转至本项目所发布在的其它仓库或博客
|
||||
|
||||
### 更新日志
|
||||
- __2021 / 06 / 05__
|
||||
ㅤ新增对于 Red Hat Enterprise Linux 的全面适配。
|
||||
- __2021 / 05 / 30__
|
||||
ㅤ新增选择软件源的 WEB 协议功能,修复了一些错误。
|
||||
- __2021 / 05 / 05__
|
||||
ㅤ新增关闭防火墙功能。
|
||||
- __2021 / 04 / 24__
|
||||
ㅤ新增基于 CentOS 的添加 EPEL 扩展源功能,修复了一些错误。
|
||||
- __2021 / 04 / 22__
|
||||
ㅤ重新定义了备份原有源功能,可以通过检测判断是否执行覆盖备份操作。
|
||||
|
||||
***
|
||||
|
||||
### 已适配的 GNU/Linux 发行版 <img src="./icon/linux.svg" width="16" height="16" alt="Linux Logo"/>
|
||||
### 已适配的 GNU/Linux 发行版 <img src="./img/icon/linux.svg" width="16" height="16" alt="Linux Logo"/>
|
||||
<table>
|
||||
<tr>
|
||||
<td rowspan="7"> 支持<br/>版本<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://www.debian.org"><img src="./icon/debian.svg" width="16" height="16"/></a> Debian</td>
|
||||
<td align="center">8.0 ~ 11.1</td>
|
||||
<td><a href="https://www.debian.org"><img src="../img/icon/debian.svg" width="16" height="16"/></a> Debian</td>
|
||||
<td align="center">8.0 ~ 11.2</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://cn.ubuntu.com"><img src="./icon/ubuntu.svg" width="16" height="16"/></a> Ubuntu</td>
|
||||
<td><a href="https://cn.ubuntu.com"><img src="../img/icon/ubuntu.svg" width="16" height="16"/></a> Ubuntu</td>
|
||||
<td align="center">16.04 ~ 21.10</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://www.kali.org"><img src="./icon/kali.svg" width="16" height="16"/></a> Kali Linux</td>
|
||||
<td><a href="https://www.kali.org"><img src="../img/icon/kali.svg" width="16" height="16"/></a> Kali Linux</td>
|
||||
<td align="center">2.0 ~ 2021.4</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://access.redhat.com/products/red-hat-enterprise-linux"><img src="./icon/redhat.svg" width="16" height="16"/></a> RHEL</td>
|
||||
<td><a href="https://access.redhat.com/products/red-hat-enterprise-linux"><img src="../img/icon/redhat.svg" width="16" height="16"/></a> Red Hat Enterprise Linux</td>
|
||||
<td align="center">7.0 ~ 8.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://www.centos.org"><img src="./icon/centos.svg" width="16" height="16"/></a> CentOS</td>
|
||||
<td><a href="https://www.centos.org"><img src="../img/icon/centos.svg" width="16" height="16"/></a> CentOS</td>
|
||||
<td align="center">7.0 ~ 8.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://getfedora.org/zh_Hans_CN"><img src="./icon/fedora.ico" width="16" height="16"/></a> Fedora</td>
|
||||
<td><a href="https://getfedora.org/zh_Hans_CN"><img src="../img/icon/fedora.ico" width="16" height="16"/></a> Fedora</td>
|
||||
<td align="center">28 ~ 35</td>
|
||||
</tr>
|
||||
</table>
|
||||
@@ -117,15 +105,15 @@
|
||||
***
|
||||
|
||||
### 常见问题与帮助
|
||||
- 1. 如果提示 `Command 'curl' not found` 则说明当前未安装 `curl` 软件包,安装命令如下:
|
||||
- 如果提示 `Command 'curl' not found` 则说明当前未安装 `curl` 软件包
|
||||
|
||||
sudo apt install -y curl 或 sudo yum install -y curl
|
||||
|
||||
- 2. 如果提示 `Command 'wget' not found` 则说明当前未安装 `wget` 软件包,安装命令如下:
|
||||
- 如果提示 `Command 'wget' not found` 则说明当前未安装 `wget` 软件包
|
||||
|
||||
sudo apt install -y wget 或 sudo yum install -y wget
|
||||
|
||||
- 3. 如果提示 `bash: /proc/self/fd/11: No such file or directory`,请切换至 `Root` 用户执行。
|
||||
- 如果提示 `bash: /proc/self/fd/11: No such file or directory`,请切换至 `Root` 用户执行。
|
||||
|
||||
***
|
||||
|
||||
|
||||
BIN
docs/.DS_Store
vendored
Normal file
0
docs/.nojekyll
Normal file
123
docs/README.md
Normal file
@@ -0,0 +1,123 @@
|
||||
- #### __GNU/Linux 一键更换国内软件源脚本__ <!-- {docsify-ignore} -->
|
||||
- #### __本项目旨在为从事计算机相关行业的朋友们提供便利__ <!-- {docsify-ignore} -->
|
||||
- #### __理论支持所有架构的环境,`arm64` 环境已经过测试__ <!-- {docsify-ignore} -->
|
||||
|
||||
## 适配系统
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td rowspan="7"> 支持<br/>版本<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://www.debian.org"><img src="../img/icon/debian.svg" width="16" height="16"/></a> Debian</td>
|
||||
<td align="center">8.0 ~ 11.2</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://cn.ubuntu.com"><img src="../img/icon/ubuntu.svg" width="16" height="16"/></a> Ubuntu</td>
|
||||
<td align="center">16.04 ~ 21.10</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://www.kali.org"><img src="../img/icon/kali.svg" width="16" height="16"/></a> Kali Linux</td>
|
||||
<td align="center">2.0 ~ 2021.4</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://access.redhat.com/products/red-hat-enterprise-linux"><img src="../img/icon/redhat.svg" width="16" height="16"/></a> Red Hat Enterprise Linux</td>
|
||||
<td align="center">7.0 ~ 8.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://www.centos.org"><img src="../img/icon/centos.svg" width="16" height="16"/></a> CentOS</td>
|
||||
<td align="center">7.0 ~ 8.5</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="https://getfedora.org/zh_Hans_CN"><img src="../img/icon/fedora.ico" width="16" height="16"/></a> Fedora</td>
|
||||
<td align="center">28 ~ 35</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
> 目前仅支持上述基于 Debian 与 Redhat 系的发行版和及其部分衍生版本 \
|
||||
> 同样支持上述版本中拥有相同底层核心的其它发行版,例如 [`Armbian`](https://www.armbian.com) [`Kubuntu`](https://kubuntu.org) [`Oracle Linux`](https://www.oracle.com/cn/technical-resources) 等
|
||||
|
||||
## 软件源
|
||||
> 脚本当前使用的开源镜像站
|
||||
|
||||
| | 镜像站名称 | 镜像站地址 | IPv6 | Kali Linux | Fedora | EPEL |
|
||||
| :------: | :------: | :------: | :------: | :------: | :------: | :------: |
|
||||
| 1 | 阿里云 | [mirrors.aliyun.com](https://developer.aliyun.com/special/mirrors/notice) | √ | √ | √ | √ |
|
||||
| 2 | 腾讯云 | [mirrors.cloud.tencent.com](https://mirrors.cloud.tencent.com) | √ | √ | √ | √ |
|
||||
| 3 | 华为云 | [mirrors.huaweicloud.com](https://mirrors.huaweicloud.com) | √ | √ | √ | √ |
|
||||
| 4 | 网易 | [mirrors.163.com](https://mirrors.163.com) | | | √ | |
|
||||
| 5 | 搜狐 | [mirrors.sohu.com](https://mirrors.sohu.com) | | | | |
|
||||
| 6 | 清华大学 | [mirrors.tuna.tsinghua.edu.cn](https://mirrors.tuna.tsinghua.edu.cn) | √ | √ | √ | √ |
|
||||
| 7 | 浙江大学 | [mirrors.zju.edu.cn](https://mirrors.zju.edu.cn) | | √ | √ | √ |
|
||||
| 8 | 南京大学 | [mirrors.nju.edu.cn](https://mirrors.nju.edu.cn) | | √ | √ | √ |
|
||||
| 9 | 重庆大学 | [mirrors.cqu.edu.cn](https://mirrors.cqu.edu.cn) | | √ | √ | √ |
|
||||
| 10 | 兰州大学 | [mirror.lzu.edu.cn](https://mirror.lzu.edu.cn) | √ | | √ | √ |
|
||||
| 11 | 上海交通大学 | [mirror.sjtu.edu.cn](https://mirror.sjtu.edu.cn) | √ | √ | √ | √ |
|
||||
| 12 | 哈尔滨工业大学 | [mirrors.hit.edu.cn](https://mirrors.hit.edu.cn) | √ | √ | | √ |
|
||||
| 13 | 中国科学技术大学 | [mirrors.ustc.edu.cn](https://mirrors.ustc.edu.cn) | √ | √ | √ | √ |
|
||||
> 所有镜像站均支持 `Debian` `Ubuntu` `CentOS` 软件源,建议优先选择由企业提供的软件源
|
||||
|
||||
?> 如果使用过程中脚本不能正常输出中文内容则可对照此列表使用,顺序与脚本一致
|
||||
|
||||
## 执行流程
|
||||
- └ 选择国内源 `交互`
|
||||
- └ 检测如果是 RHEL或CentOS 系统选择是否安装/覆盖 EPEL 扩展国内源 `交互`
|
||||
- └ 选择软件源使用的 WEB 协议 `交互`
|
||||
- └ 检测 防火墙 和 SELINUX 如果开启并且系统是 RHEL或CentOS 选择是否关闭 `交互`
|
||||
- └ 备份原有源
|
||||
- └ 检测如果存在重复的备份文件选择是否覆盖 `交互`
|
||||
- └ 更换国内源
|
||||
- └ 选择是否更新软件包 `交互`
|
||||
- └ 选择是否清理已下载的软件包缓存 `交互`
|
||||
|
||||
## 如何使用
|
||||
|
||||
```bash
|
||||
bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh)
|
||||
```
|
||||
|
||||
- 1. 完整复制上面的命令到终端按回车键即可执行,若无法安装 `curl` 软件包可复制源码到本地后手动执行。
|
||||
- 2. 为了适配所有环境,建议使用 `Root` 用户执行脚本,切换命令为 `sudo -i` ,如遇报错请查看常见问题与帮助。
|
||||
- 3. 如果您使用的环境没有安装或不支持简体中文环境,请通过 `SSH客户端工具` 使用,否则将无法正确选择交互内容。
|
||||
- 4. 执行脚本过程中会自动备份原有源无需手动备份,期间会在终端输出多个主观选择交互内容,可按回车键快速确认。
|
||||
- 5. 脚本支持在原有源配置错误或者不存在的情况下使用,并且可以重复使用;脚本变更的软件源默认使用 `HTTP 协议`。
|
||||
|
||||
> **Debian** 系 Linux 默认禁用了**源码仓库**和**预发布软件源**,若需启用可将 `list` 源文件中相关内容的所在行**取消注释**
|
||||
|
||||
> **RedHat** 系 Linux 配置了所有可以配置的仓库,但有一些仓库**默认没有启用**,若需启用可将 `repo` 源文件中的 `enabled=0` 修改成 `enabled=1`
|
||||
|
||||
## 其它脚本
|
||||
- #### `Docker` 一键安装脚本 <!-- {docsify-ignore} -->
|
||||
|
||||
```bash
|
||||
bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh)
|
||||
```
|
||||
|
||||
> `Docker CE`:Docker Community Edition 镜像仓库,用于下载并安装 Docker 相关软件包。\
|
||||
> `Docker Hub`:Docker Hub 镜像仓库,默认为官方提供的公共库,用于切换下载镜像时的来源仓库,简称镜像加速器。
|
||||
|
||||
> 脚本集成安装 `Docker Engine`与 `Docker Compose`,可手动选择安装版本、下载源、镜像加速器,支持国内外服务器环境和 `ARM`架构处理器环境使用
|
||||
|
||||
## 常见问题
|
||||
- #### 如果提示 `Command 'curl' not found` 则说明当前未安装 `curl` 软件包 <!-- {docsify-ignore} -->
|
||||
|
||||
```bash
|
||||
sudo apt install -y curl 或 sudo yum install -y curl
|
||||
```
|
||||
|
||||
- #### 如果提示 `Command 'wget' not found` 则说明当前未安装 `wget` 软件包 <!-- {docsify-ignore} -->
|
||||
|
||||
```bash
|
||||
sudo apt install -y wget 或 sudo yum install -y wget
|
||||
```
|
||||
|
||||
- #### 如果提示 `bash: /proc/self/fd/11: No such file or directory`,请切换至 `Root` 用户执行。 <!-- {docsify-ignore} -->
|
||||
|
||||
## License
|
||||
Copyright © 2021, [SuperManito](https://github.com/SuperManito). Released under the [GPL-2.0](https://github.com/SuperManito/LinuxMirrors/blob/main/LICENSE)
|
||||
> 项目已设立开源许可协议,传播时需在显著位置标注来源和作者,请尊重本人的知识成果\
|
||||
> 建议通过命令直接调用脚本,如有意见与建议您可以提交至 __Issues__ ,谢谢
|
||||
|
||||
***
|
||||
|
||||
__如果您觉得这个项目不错的话可以送颗 ⭐ 吗?方便分享给更多的朋友吗?__
|
||||
3
docs/_404.md
Normal file
@@ -0,0 +1,3 @@
|
||||
!> 你走丢了哦~
|
||||
|
||||
<a><img src="../img/404.gif"></a>
|
||||
11
docs/_coverpage.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# 
|
||||
> 脚本一键更换服务器软件源,让换源更简单!
|
||||
|
||||
|
||||
<a href="https://github.com/SuperManito/LinuxMirrors"><img src="../img/icon/github-1.svg" width="34" height="42"></a>
|
||||
<a href="https://github.com/SuperManito/LinuxMirrors"><img src="../img/icon/github-2.svg" width="70" height="52"></a>
|
||||
<a href="https://gitee.com/SuperManito/LinuxMirrors"><img src="../img/icon/gitee.svg" width="100" height="50"/></a>
|
||||
|
||||
[Github](https://github.com/SuperManito/LinuxMirrors)
|
||||
[Gitee](https://gitee.com/SuperManito/LinuxMirrors)
|
||||
[开始使用](#适配系统)
|
||||
1
docs/css/default.css
Normal file
1
docs/css/vue.css
Normal file
127
docs/index.html
Normal file
@@ -0,0 +1,127 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>LinuxMirror · 让换源更简单</title>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
|
||||
<meta name="description" content="Description">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0">
|
||||
<link rel="stylesheet" href="./css/vue.css">
|
||||
<link rel="icon" type="image/x-icon" href="./img/icon/linux.svg" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="app"></div>
|
||||
<script>
|
||||
window.$docsify = {
|
||||
name: 'LinuxMirrors',
|
||||
repo: 'https://github.com/SuperManito/LinuxMirrors',
|
||||
// 导航栏logo
|
||||
logo: './img/logo.png',
|
||||
// 加载封面
|
||||
coverpage: true,
|
||||
// 主题色
|
||||
themeColor: '#1e90ff',
|
||||
// 小屏幕设备自动合并导航栏到侧边栏
|
||||
mergeNavbar: true,
|
||||
// 启用自定义404页
|
||||
notFoundPage: true,
|
||||
// 跳转后自动移到顶部
|
||||
auto2top: true,
|
||||
|
||||
// 搜索
|
||||
search: 'auto',
|
||||
search: {
|
||||
maxAge: 86400000, // 过期时间,单位毫秒,默认一天
|
||||
placeholder: '搜索',
|
||||
noData: '找不到结果!',
|
||||
// 搜索标题的最大层级, 1 - 6
|
||||
depth: 2,
|
||||
hideOtherSidebarContent: false, // 是否隐藏其他侧边栏内容
|
||||
// 避免搜索索引冲突
|
||||
// 同一域下的多个网站之间
|
||||
namespace: 'website-1',
|
||||
// 使用不同的索引作为路径前缀(namespaces)
|
||||
// 注意:仅适用于 paths: 'auto' 模式
|
||||
// 初始化索引时,我们从侧边栏查找第一个路径
|
||||
// 如果它与列表中的前缀匹配,我们将切换到相应的索引
|
||||
pathNamespaces: ['/zh-cn', '/ru-ru', '/ru-ru/v1'],
|
||||
// 您可以提供一个正则表达式来匹配前缀。在这种情况下,
|
||||
// 匹配到的字符串将被用来识别索引
|
||||
pathNamespaces: /^(\/(zh-cn|ru-ru))?(\/(v1|v2))?/
|
||||
},
|
||||
|
||||
// 浅色|暗黑主题
|
||||
darklightTheme: {
|
||||
siteFont: "PT Sans",
|
||||
defaultTheme: 'dark',
|
||||
codeFontFamily: 'Roboto Mono, Monaco, courier, monospace',
|
||||
bodyFontSize: '17px',
|
||||
light: {
|
||||
accent: '#1e90ff',
|
||||
toogleBackground: '#091a28',
|
||||
background: '#ffffff',
|
||||
textColor: '#34495e',
|
||||
codeTextColor: '#525252',
|
||||
codeBackgroundColor: '#f8f8f8',
|
||||
borderColor: 'rgba(0, 0, 0, 0.07)',
|
||||
blockQuoteColor: '#858585',
|
||||
highlightColor: '#d22778',
|
||||
sidebarSublink: '#7c7c7c',
|
||||
codeTypeColor: '#091a28',
|
||||
coverBackground: 'linear-gradient(to left bottom, hsl(118, 100%, 85%) 0%,hsl(181, 100%, 85%) 100%)',
|
||||
toogleImage: 'url(https://cdn.jsdelivr.net/npm/docsify-darklight-theme@latest/icons/moon.svg)'
|
||||
},
|
||||
dark: {
|
||||
accent: '#42b983',
|
||||
toogleBackground: '#ffffff',
|
||||
background: '#091a28',
|
||||
textColor: '#b4b4b4',
|
||||
codeTextColor: '#ffffff',
|
||||
codeBackgroundColor: '#0e2233',
|
||||
borderColor: '#0d2538',
|
||||
blockQuoteColor: '#858585',
|
||||
highlightColor: '#bb8b06',
|
||||
sidebarSublink: '#b4b4b4',
|
||||
codeTypeColor: '#ffffff',
|
||||
coverBackground: 'linear-gradient(to left bottom, hsl(118, 100%, 85%) 0%,hsl(181, 100%, 85%) 100%)',
|
||||
toogleImage: 'url(https://cdn.jsdelivr.net/npm/docsify-darklight-theme@latest/icons/sun.svg)'
|
||||
},
|
||||
// 底部跳转页码
|
||||
pagination: {
|
||||
previousText: '上一章节',
|
||||
nextText: '下一章节',
|
||||
crossChapter: true,
|
||||
crossChapterText: true,
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<!-- Docsify v4 -->
|
||||
<script src="./js/docsify@4.js"></script>
|
||||
<!-- 暗黑主题 -->
|
||||
<script src="./js/dark-theme.js" type="text/javascript"></script>
|
||||
<!-- 底部跳转页码 -->
|
||||
<script src="./js/docsify-pagination.min.js"></script>
|
||||
<!-- 复制到剪贴板 -->
|
||||
<script src="./js/docsify-copy-code.min.js"></script>
|
||||
<!-- Emoji支持 -->
|
||||
<script src="./js/emoji.min.js"></script>
|
||||
<!-- 搜索 -->
|
||||
<script src="./js/search.js"></script>
|
||||
<!-- 代码高亮 -->
|
||||
<script src="./js/prism-bash.min.js"></script>
|
||||
<!-- 更新日志 -->
|
||||
<script src="./js/change-log.js"></script>
|
||||
<!-- 离线模式 -->
|
||||
<script>
|
||||
if (typeof navigator.serviceWorker !== 'undefined') {
|
||||
navigator.serviceWorker.register('./js/sw.js')
|
||||
}
|
||||
</script>
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
||||
1
docs/js/dark-theme.js
Normal file
@@ -0,0 +1 @@
|
||||
window.$docsify.plugins=[].concat((e,o)=>{let t={siteFont:"PT Sans",defaultTheme:"dark",codeFontFamily:"Roboto Mono, Monaco, courier, monospace",bodyFontSize:"17px",dark:{accent:"#42b983",toogleBackground:"#ffffff",background:"#091a28",textColor:"#b4b4b4",codeTextColor:"#ffffff",codeBackgroundColor:"#0e2233",borderColor:"#0d2538",blockQuoteColor:"#858585",highlightColor:"#d22778",sidebarSublink:"#b4b4b4",codeTypeColor:"#ffffff",coverBackground:"linear-gradient(to left bottom, hsl(118, 100%, 85%) 0%,hsl(181, 100%, 85%) 100%)",toogleImage:"url(https://cdn.jsdelivr.net/npm/docsify-darklight-theme@latest/icons/sun.svg)"},light:{accent:"#42b983",toogleBackground:"#091a28",background:"#ffffff",textColor:"#34495e",codeTextColor:"#525252",codeBackgroundColor:"#f8f8f8",borderColor:"rgba(0, 0, 0, 0.07)",blockQuoteColor:"#858585",highlightColor:"#d22778",sidebarSublink:"#505d6b",codeTypeColor:"#091a28",coverBackground:"linear-gradient(to left bottom, hsl(118, 100%, 85%) 0%,hsl(181, 100%, 85%) 100%)",toogleImage:"url(https://cdn.jsdelivr.net/npm/docsify-darklight-theme@latest/icons/moon.svg)"}};if(o.config.hasOwnProperty("darklightTheme")){for(var[r,l]of Object.entries(o.config.darklightTheme))"light"!==r&&"dark"!==r&&"defaultTheme"!==r&&(t[r]=l);for(var[r,l]of Object.entries(t))"light"!==r&&"dark"!==r&&(t[r]=l,document.documentElement.style.setProperty("--"+r,l));if(o.config.darklightTheme.hasOwnProperty("dark"))for(var[r,l]of Object.entries(o.config.darklightTheme.dark))t.dark[r]=l;if(o.config.darklightTheme.hasOwnProperty("light"))for(var[r,l]of Object.entries(o.config.darklightTheme.light))t.light[r]=l}else for(var[r,l]of Object.entries(t))"light"!==r&&"dark"!==r&&(t[r]=l,document.documentElement.style.setProperty("--"+r,l));window.matchMedia("(prefers-color-scheme: dark)").matches?t.defaultTheme="dark":window.matchMedia("(prefers-color-scheme: light)").matches&&(t.defaultTheme="light");var d=e=>{if(localStorage.setItem("DARK_LIGHT_THEME",e),t.defaultTheme=e,"light"==e)for(var[o,r]of Object.entries(t.light))document.documentElement.style.setProperty("--"+o,r);else if("dark"==e)for(var[o,r]of Object.entries(t.dark))document.documentElement.style.setProperty("--"+o,r);document.documentElement.style.setProperty("color-scheme",e)};e.afterEach((function(e,o){o(e='<div id="docsify-darklight-theme"><p>.</p></div>'+e)})),e.doneEach((function(){let e=localStorage.getItem("DARK_LIGHT_THEME");"light"==e||"dark"==e?(t.defaultTheme=e,d(t.defaultTheme)):d(t.defaultTheme);const o=document.getElementById("docsify-darklight-theme");null!==o&&o.addEventListener("click",(function(){"light"===t.defaultTheme?d("dark"):d("light")}))}))},window.$docsify.plugins);
|
||||
9
docs/js/docsify-copy-code.min.js
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
/*!
|
||||
* docsify-copy-code
|
||||
* v2.1.1
|
||||
* https://github.com/jperasmus/docsify-copy-code
|
||||
* (c) 2017-2020 JP Erasmus <jperasmus11@gmail.com>
|
||||
* MIT license
|
||||
*/
|
||||
!function(){"use strict";function s(o){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o})(o)}!function(o,e){void 0===e&&(e={});var t=e.insertAt;if(o&&"undefined"!=typeof document){var n=document.head||document.getElementsByTagName("head")[0],c=document.createElement("style");c.type="text/css","top"===t&&n.firstChild?n.insertBefore(c,n.firstChild):n.appendChild(c),c.styleSheet?c.styleSheet.cssText=o:c.appendChild(document.createTextNode(o))}}(".docsify-copy-code-button,.docsify-copy-code-button span{cursor:pointer;transition:all .25s ease}.docsify-copy-code-button{position:absolute;z-index:1;top:0;right:0;overflow:visible;padding:.65em .8em;border:0;border-radius:0;outline:0;font-size:1em;background:grey;background:var(--theme-color,grey);color:#fff;opacity:0}.docsify-copy-code-button span{border-radius:3px;background:inherit;pointer-events:none}.docsify-copy-code-button .error,.docsify-copy-code-button .success{position:absolute;z-index:-100;top:50%;right:0;padding:.5em .65em;font-size:.825em;opacity:0;-webkit-transform:translateY(-50%);transform:translateY(-50%)}.docsify-copy-code-button.error .error,.docsify-copy-code-button.success .success{right:100%;opacity:1;-webkit-transform:translate(-115%,-50%);transform:translate(-115%,-50%)}.docsify-copy-code-button:focus,pre:hover .docsify-copy-code-button{opacity:1}"),document.querySelector('link[href*="docsify-copy-code"]')&&console.warn("[Deprecation] Link to external docsify-copy-code stylesheet is no longer necessary."),window.DocsifyCopyCodePlugin={init:function(){return function(o,e){o.ready(function(){console.warn("[Deprecation] Manually initializing docsify-copy-code using window.DocsifyCopyCodePlugin.init() is no longer necessary.")})}}},window.$docsify=window.$docsify||{},window.$docsify.plugins=[function(o,r){o.doneEach(function(){var o=Array.apply(null,document.querySelectorAll("pre[data-lang]")),c={buttonText:"点击复制",errorText:"Error",successText:"已复制"};r.config.copyCode&&Object.keys(c).forEach(function(t){var n=r.config.copyCode[t];"string"==typeof n?c[t]=n:"object"===s(n)&&Object.keys(n).some(function(o){var e=-1<location.href.indexOf(o);return c[t]=e?n[o]:c[t],e})});var e=['<button class="docsify-copy-code-button">','<span class="label">'.concat(c.buttonText,"</span>"),'<span class="error">'.concat(c.errorText,"</span>"),'<span class="success">'.concat(c.successText,"</span>"),"</button>"].join("");o.forEach(function(o){o.insertAdjacentHTML("beforeend",e)})}),o.mounted(function(){document.querySelector(".content").addEventListener("click",function(o){if(o.target.classList.contains("docsify-copy-code-button")){var e="BUTTON"===o.target.tagName?o.target:o.target.parentNode,t=document.createRange(),n=e.parentNode.querySelector("code"),c=window.getSelection();t.selectNode(n),c.removeAllRanges(),c.addRange(t);try{document.execCommand("copy")&&(e.classList.add("success"),setTimeout(function(){e.classList.remove("success")},1e3))}catch(o){console.error("docsify-copy-code: ".concat(o)),e.classList.add("error"),setTimeout(function(){e.classList.remove("error")},1e3)}"function"==typeof(c=window.getSelection()).removeRange?c.removeRange(t):"function"==typeof c.removeAllRanges&&c.removeAllRanges()}})})}].concat(window.$docsify.plugins||[])}();
|
||||
//# sourceMappingURL=docsify-copy-code.min.js.map
|
||||
1
docs/js/docsify-pagination.min.js
vendored
Normal file
1
docs/js/docsify@4.js
Normal file
1
docs/js/emoji.min.js
vendored
Normal file
1
docs/js/prism-bash.min.js
vendored
Normal file
1
docs/js/search.js
Normal file
83
docs/js/sw.js
Normal file
@@ -0,0 +1,83 @@
|
||||
/* ===========================================================
|
||||
* docsify sw.js
|
||||
* ===========================================================
|
||||
* Copyright 2016 @huxpro
|
||||
* Licensed under Apache 2.0
|
||||
* Register service worker.
|
||||
* ========================================================== */
|
||||
|
||||
const RUNTIME = 'docsify'
|
||||
const HOSTNAME_WHITELIST = [
|
||||
self.location.hostname,
|
||||
'fonts.gstatic.com',
|
||||
'fonts.googleapis.com',
|
||||
'cdn.jsdelivr.net'
|
||||
]
|
||||
|
||||
// The Util Function to hack URLs of intercepted requests
|
||||
const getFixedUrl = (req) => {
|
||||
var now = Date.now()
|
||||
var url = new URL(req.url)
|
||||
|
||||
// 1. fixed http URL
|
||||
// Just keep syncing with location.protocol
|
||||
// fetch(httpURL) belongs to active mixed content.
|
||||
// And fetch(httpRequest) is not supported yet.
|
||||
url.protocol = self.location.protocol
|
||||
|
||||
// 2. add query for caching-busting.
|
||||
// Github Pages served with Cache-Control: max-age=600
|
||||
// max-age on mutable content is error-prone, with SW life of bugs can even extend.
|
||||
// Until cache mode of Fetch API landed, we have to workaround cache-busting with query string.
|
||||
// Cache-Control-Bug: https://bugs.chromium.org/p/chromium/issues/detail?id=453190
|
||||
if (url.hostname === self.location.hostname) {
|
||||
url.search += (url.search ? '&' : '?') + 'cache-bust=' + now
|
||||
}
|
||||
return url.href
|
||||
}
|
||||
|
||||
/**
|
||||
* @Lifecycle Activate
|
||||
* New one activated when old isnt being used.
|
||||
*
|
||||
* waitUntil(): activating ====> activated
|
||||
*/
|
||||
self.addEventListener('activate', event => {
|
||||
event.waitUntil(self.clients.claim())
|
||||
})
|
||||
|
||||
/**
|
||||
* @Functional Fetch
|
||||
* All network requests are being intercepted here.
|
||||
*
|
||||
* void respondWith(Promise<Response> r)
|
||||
*/
|
||||
self.addEventListener('fetch', event => {
|
||||
// Skip some of cross-origin requests, like those for Google Analytics.
|
||||
if (HOSTNAME_WHITELIST.indexOf(new URL(event.request.url).hostname) > -1) {
|
||||
// Stale-while-revalidate
|
||||
// similar to HTTP's stale-while-revalidate: https://www.mnot.net/blog/2007/12/12/stale
|
||||
// Upgrade from Jake's to Surma's: https://gist.github.com/surma/eb441223daaedf880801ad80006389f1
|
||||
const cached = caches.match(event.request)
|
||||
const fixedUrl = getFixedUrl(event.request)
|
||||
const fetched = fetch(fixedUrl, { cache: 'no-store' })
|
||||
const fetchedCopy = fetched.then(resp => resp.clone())
|
||||
|
||||
// Call respondWith() with whatever we get first.
|
||||
// If the fetch fails (e.g disconnected), wait for the cache.
|
||||
// If there’s nothing in cache, wait for the fetch.
|
||||
// If neither yields a response, return offline pages.
|
||||
event.respondWith(
|
||||
Promise.race([fetched.catch(_ => cached), cached])
|
||||
.then(resp => resp || fetched)
|
||||
.catch(_ => { /* eat any errors */ })
|
||||
)
|
||||
|
||||
// Update the cache with the version we fetched (only for ok status)
|
||||
event.waitUntil(
|
||||
Promise.all([fetchedCopy, caches.open(RUNTIME)])
|
||||
.then(([response, cache]) => response.ok && cache.put(event.request, response))
|
||||
.catch(_ => { /* eat any errors */ })
|
||||
)
|
||||
}
|
||||
})
|
||||
BIN
img/.DS_Store
vendored
Normal file
BIN
img/404.gif
Normal file
|
After Width: | Height: | Size: 716 KiB |
|
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 5.0 KiB After Width: | Height: | Size: 5.0 KiB |
|
Before Width: | Height: | Size: 4.2 KiB After Width: | Height: | Size: 4.2 KiB |
|
Before Width: | Height: | Size: 4.2 KiB After Width: | Height: | Size: 4.2 KiB |
1
img/icon/fedora.svg
Normal file
@@ -0,0 +1 @@
|
||||
<svg width="2500" height="2500" viewBox="0 0 256 256" xmlns="http://www.w3.org/2000/svg" preserveAspectRatio="xMidYMid"><path d="M256 128.004C256 57.31 198.691 0 127.998 0 57.336 0 .05 57.262 0 127.914v99.054c.038 16.042 13.049 29.029 29.101 29.029h98.949C198.72 255.969 256 198.679 256 128.004" fill="#294172"/><path d="M165.58 30.307c-33.109 0-60.045 26.935-60.045 60.045v31.87H73.797c-33.109 0-60.045 26.937-60.045 60.046 0 33.108 26.936 60.045 60.045 60.045s60.045-26.937 60.045-60.045v-31.871h31.738c33.109 0 60.046-26.936 60.046-60.045 0-33.11-26.937-60.045-60.046-60.045zm-59.823 151.961c0 17.622-14.337 31.959-31.96 31.959s-31.96-14.337-31.96-31.959c0-17.623 14.337-31.96 31.96-31.96h31.738v.089h.222v31.871zm59.823-59.956h-31.738v-.09h-.221v-31.87c0-17.623 14.337-31.96 31.959-31.96s31.96 14.337 31.96 31.96-14.338 31.96-31.96 31.96z" fill="#3C6EB4"/><path d="M178.851 32.128c-4.66-1.218-8.238-1.786-13.271-1.786-33.177 0-60.075 26.899-60.075 60.074v31.842h-25.16c-7.845 0-14.185 6.165-14.18 13.996 0 7.782 6.27 13.973 14.032 13.973l20.831.004c2.473 0 4.479 2 4.479 4.469v27.553c-.031 17.491-14.219 31.659-31.71 31.659-5.925 0-7.392-.776-11.437-.776-8.497 0-14.182 5.696-14.182 13.528.002 6.479 5.554 12.049 12.348 13.827 4.66 1.218 8.238 1.787 13.271 1.787 33.177 0 60.075-26.899 60.075-60.075v-31.841h25.16c7.845 0 14.185-6.165 14.18-13.996 0-7.783-6.27-13.973-14.032-13.973l-20.831-.004a4.475 4.475 0 0 1-4.479-4.47V90.366c.031-17.491 14.219-31.659 31.71-31.659 5.925 0 7.392.777 11.437.777 8.497 0 14.182-5.697 14.182-13.528-.002-6.48-5.554-12.05-12.348-13.828" fill="#FFF"/></svg>
|
||||
|
After Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 14 KiB After Width: | Height: | Size: 14 KiB |
|
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 2.0 KiB |
|
Before Width: | Height: | Size: 2.7 KiB After Width: | Height: | Size: 2.7 KiB |
|
Before Width: | Height: | Size: 2.7 KiB After Width: | Height: | Size: 2.7 KiB |
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
1
img/icon/red-hat-enterprise-linux.svg
Normal file
|
After Width: | Height: | Size: 5.2 KiB |
|
Before Width: | Height: | Size: 909 B After Width: | Height: | Size: 909 B |
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
BIN
img/logo.png
Normal file
|
After Width: | Height: | Size: 2.4 KiB |