mirror of
https://github.com/tuna/mirror-web.git
synced 2025-12-25 20:32:46 +00:00
Merge branch 'tuna-refactor'
Signed-off-by: Miao Wang <shankerwangmiao@gmail.com>
This commit is contained in:
commit
b8cfb2af24
13
404.html
13
404.html
|
|
@ -11,12 +11,16 @@ permalink: /404.html
|
|||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="not-found">
|
||||
<div class="not-found-bg"></div>
|
||||
{% if site.meow_404 %}
|
||||
<div class="not-found-bg"></div>
|
||||
{% endif %}
|
||||
<div class="not-found-hint">
|
||||
<div class="not-found-code">
|
||||
404 NOT FOUND
|
||||
</div>
|
||||
<span class="thuhidden">呜喵,金枪鱼</span>被吃掉了
|
||||
{% if site.meow_404 %}
|
||||
<span class="thuhidden">呜喵,金枪鱼</span>被吃掉了
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="not-found-text thuhidden">
|
||||
如果您认为这一定是出了什么问题,或者正在寻找暂未包含的镜像,欢迎您前往
|
||||
|
|
@ -43,14 +47,15 @@ permalink: /404.html
|
|||
{% include footer.html %}
|
||||
<script type="application/javascript">
|
||||
(function(){
|
||||
var tag = "[" + "{{ site.issue_tag }}" + "]";
|
||||
var bugLink = document.getElementById("new_issue_bug");
|
||||
var bugURL = new URL(bugLink.href);
|
||||
bugURL.searchParams.append("title", "404 at " + location.pathname);
|
||||
bugURL.searchParams.append("title", tag + "404 at " + location.pathname);
|
||||
bugLink.href = bugURL.href;
|
||||
|
||||
var mrLink = document.getElementById("new_issue_mr");
|
||||
var mrURL = new URL(mrLink.href);
|
||||
mrURL.searchParams.append("title", "Mirror Request for new mirror " +
|
||||
mrURL.searchParams.append("title", tag + "Mirror Request for new mirror " +
|
||||
location.pathname.split('/')[1]);
|
||||
mrLink.href = mrURL.href;
|
||||
})();
|
||||
|
|
|
|||
15
_config.yml
15
_config.yml
|
|
@ -7,10 +7,25 @@
|
|||
|
||||
# Site settings
|
||||
title: 清华大学开源软件镜像站
|
||||
# title: 北京外国语大学开源软件镜像站
|
||||
school: 清华大学
|
||||
# school: 北京外国语大学
|
||||
brand: Tsinghua Open Source Mirror
|
||||
operator: 清华大学信息化技术中心
|
||||
# operator: 北外信息技术中心
|
||||
logo: true
|
||||
meow_404: true
|
||||
issue_tag: tuna
|
||||
baseurl: "" # the subpath of your site, e.g. /blog
|
||||
permalink: "/:categories/:title/"
|
||||
url: "https://mirrors.tuna.tsinghua.edu.cn"
|
||||
hostname: "mirrors.tuna.tsinghua.edu.cn"
|
||||
urlv4: "https://mirrors4.tuna.tsinghua.edu.cn"
|
||||
urlv6: "https://mirrors6.tuna.tsinghua.edu.cn"
|
||||
aosp: "aosp.tuna.tsinghua.edu.cn"
|
||||
arch_archive: "arch-archive.tuna.tsinghua.edu.cn"
|
||||
aur: "aur.tuna.tsinghua.edu.cn"
|
||||
pypi: "pypi.tuna.tsinghua.edu.cn"
|
||||
|
||||
# Build settings
|
||||
highlighter: rouge
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-lg-4 col-md-4{% if page.legacy %} col-xs-4{% endif %}">
|
||||
<p class="thuhidden">本站由清华大学信息化技术中心支持创办,由清华大学 TUNA 协会运行维护。</p>
|
||||
<p class="thuhidden">本站由{{ site.operator }}支持创办,由清华大学 TUNA 协会运行维护。</p>
|
||||
<p class="thuhidden">清华大学 TUNA 协会,全名清华大学学生网络与开源软件协会,是由清华大学热爱网络技术和开源软件的极客组成的学生技术社团。</p>
|
||||
<p>本站相关源码可在 <a href="https://github.com/tuna/tunasync"><em>这里(镜像管理器)</em></a> 和 <a href="https://github.com/tuna/mirror-web"><em>这里(镜像站网页)</em></a> 获取。</p>
|
||||
<p class="thuhidden">根据相关法律法规,本站不对欧盟用户提供服务。</p>
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
<meta charset="UTF-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<meta name="description" content="清华大学开源软件镜像站,致力于为国内和校内用户提供高质量的开源软件镜像、Linux镜像源服务,帮助用户更方便地获取开源软件。本镜像站由清华大学TUNA团队负责维护。">
|
||||
<meta name="description" content="{{ site.title }},致力于为国内和校内用户提供高质量的开源软件镜像、Linux镜像源服务,帮助用户更方便地获取开源软件。本镜像站由清华大学TUNA团队负责维护。">
|
||||
<meta name="keywords" content="镜像站,镜像源,Linux,软件源,开源">
|
||||
<meta name="author" content="TUNA">
|
||||
<link rel="shortcut icon" href="/static/img/favicon.png">
|
||||
|
|
|
|||
|
|
@ -9,23 +9,26 @@
|
|||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
{% endunless %}
|
||||
<a class="navbar-brand" href="/"><!--
|
||||
--><span class="thuhidden"><!--
|
||||
--><picture>
|
||||
<source
|
||||
srcset="/static/img/logo-small-dark.png 1x,
|
||||
/static/img/logo-small-dark@2x.png 2x,
|
||||
/static/img/logo-small-dark@3x.png 3x,
|
||||
/static/img/logo-small-dark@4x.png 4x"
|
||||
media="(prefers-color-scheme: dark)"/>
|
||||
<img src="/static/img/logo-small.png"
|
||||
srcset="/static/img/logo-small.png 1x,
|
||||
/static/img/logo-small@2x.png 2x,
|
||||
/static/img/logo-small@3x.png 3x,
|
||||
/static/img/logo-small@4x.png 4x"
|
||||
alt=""/>
|
||||
</picture>
|
||||
清华大学</span>开源软件镜像站</a>
|
||||
<a class="navbar-brand" href="/">
|
||||
<span class="thuhidden">
|
||||
{% if site.logo %}
|
||||
<picture>
|
||||
<source
|
||||
srcset="/static/img/logo-small-dark.png 1x,
|
||||
/static/img/logo-small-dark@2x.png 2x,
|
||||
/static/img/logo-small-dark@3x.png 3x,
|
||||
/static/img/logo-small-dark@4x.png 4x"
|
||||
media="(prefers-color-scheme: dark)"/>
|
||||
<img src="/static/img/logo-small.png"
|
||||
srcset="/static/img/logo-small.png 1x,
|
||||
/static/img/logo-small@2x.png 2x,
|
||||
/static/img/logo-small@3x.png 3x,
|
||||
/static/img/logo-small@4x.png 4x"
|
||||
alt=""/>
|
||||
</picture>
|
||||
{% endif %}
|
||||
{{ site.school }}</span>开源软件镜像站
|
||||
</a>
|
||||
</div>
|
||||
<div class="{% unless page.legacy %}navbar-collapse collapse {% endunless %}navbar-right">
|
||||
<ul class="nav navbar-nav" role="menubar">
|
||||
|
|
@ -34,7 +37,7 @@
|
|||
<li role="none"><a role="menuitem" href="https://tuna.moe/blog/">BLOG</a></li>
|
||||
<li role="none"><a role="menuitem" href="https://tuna.moe/feed.xml">RSS</a></li>
|
||||
<li role="none"><a role="menuitem" href="https://podcast.tuna.moe/">PODCAST</a></li>
|
||||
<li role="none" class="active"><a role="menuitem" aria-checked="true" href="http://mirrors.tuna.tsinghua.edu.cn/">MIRRORS</a></li>
|
||||
<li role="none" class="active"><a role="menuitem" aria-checked="true" href="{{ site.url }}">MIRRORS</a></li>
|
||||
</ul>
|
||||
</div><!--/.nav-collapse -->
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -91,9 +91,13 @@
|
|||
<div class="thuhidden">
|
||||
<h4> <span class="fa fa-link"></span> 域名选择 </h4>
|
||||
<ul>
|
||||
<li><a href="https://mirrors.tuna.tsinghua.edu.cn/">https://mirrors.tuna.tsinghua.edu.cn/</a> 自动选择 </li>
|
||||
<li><a href="https://mirrors6.tuna.tsinghua.edu.cn/">https://mirrors6.tuna.tsinghua.edu.cn/</a> 只解析 IPv6</li>
|
||||
<li><a href="https://mirrors4.tuna.tsinghua.edu.cn/">https://mirrors4.tuna.tsinghua.edu.cn/</a> 只解析 IPv4</li>
|
||||
<li><a href="{{ site.url }}">{{ site.url }}</a> 自动选择 </li>
|
||||
{% if site.urlv6 %}
|
||||
<li><a href="{{ site.urlv6 }}">{{ site.urlv6 }}</a> 只解析 IPv6</li>
|
||||
{% endif %}
|
||||
{% if site.urlv4 %}
|
||||
<li><a href="{{ site.urlv4 }}">{{ site.urlv4 }}</a> 只解析 IPv4</li>
|
||||
{% endif %}
|
||||
</ul>
|
||||
</div>
|
||||
{% unless page.legacy %}
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ layout: help
|
|||
修改 `/etc/yaourtrc`,去掉 `# AURURL` 的注释,修改为
|
||||
|
||||
```
|
||||
AURURL="https://aur.tuna.tsinghua.edu.cn"
|
||||
AURURL="https://{{ site.aur }}"
|
||||
```
|
||||
|
||||
## yay 用户
|
||||
|
|
@ -19,7 +19,7 @@ AURURL="https://aur.tuna.tsinghua.edu.cn"
|
|||
执行以下命令修改 aururl :
|
||||
|
||||
```
|
||||
yay --aururl "https://aur.tuna.tsinghua.edu.cn" --save
|
||||
yay --aururl "https://{{ site.aur }}" --save
|
||||
```
|
||||
|
||||
修改的配置文件位于 `~/.config/yay/config.json` ,还可通过以下命令查看修改过的配置:
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ CocoaPods 是一个 Cocoa 和 Cocoa Touch 框架的依赖管理器,具体原
|
|||
|
||||
```
|
||||
$ pod repo remove master
|
||||
$ pod repo add master https://mirrors.tuna.tsinghua.edu.cn/git/CocoaPods/Specs.git
|
||||
$ pod repo add master https://{{ site.hostname }}/git/CocoaPods/Specs.git
|
||||
$ pod repo update
|
||||
```
|
||||
|
||||
|
|
@ -21,11 +21,11 @@ $ pod repo update
|
|||
```
|
||||
$ cd ~/.cocoapods/repos
|
||||
$ pod repo remove master
|
||||
$ git clone https://mirrors.tuna.tsinghua.edu.cn/git/CocoaPods/Specs.git master
|
||||
$ git clone https://{{ site.hostname }}/git/CocoaPods/Specs.git master
|
||||
```
|
||||
|
||||
最后进入自己的工程,在自己工程的`podFile`第一行加上:
|
||||
|
||||
```
|
||||
source 'https://mirrors.tuna.tsinghua.edu.cn/git/CocoaPods/Specs.git'
|
||||
source 'https://{{ site.hostname }}/git/CocoaPods/Specs.git'
|
||||
```
|
||||
|
|
|
|||
|
|
@ -8,9 +8,9 @@ mirrorid: anaconda
|
|||
|
||||
Anaconda 是一个用于科学计算的 Python 发行版,支持 Linux, Mac, Windows, 包含了众多流行的科学计算、数据分析的 Python 包。
|
||||
|
||||
Anaconda 安装包可以到 <https://mirrors.tuna.tsinghua.edu.cn/anaconda/archive/> 下载。
|
||||
Anaconda 安装包可以到 <{{ site.url }}/anaconda/archive/> 下载。
|
||||
|
||||
TUNA 还提供了 Anaconda 仓库与第三方源(conda-forge、msys2、pytorch等,[查看完整列表](https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/))的镜像,各系统都可以通过修改用户目录下的 `.condarc` 文件。Windows 用户无法直接创建名为 `.condarc` 的文件,可先执行 `conda config --set show_channel_urls yes` 生成该文件之后再修改。
|
||||
TUNA 还提供了 Anaconda 仓库与第三方源(conda-forge、msys2、pytorch等,[查看完整列表]({{ site.url }}/anaconda/cloud/))的镜像,各系统都可以通过修改用户目录下的 `.condarc` 文件。Windows 用户无法直接创建名为 `.condarc` 的文件,可先执行 `conda config --set show_channel_urls yes` 生成该文件之后再修改。
|
||||
|
||||
注:由于更新过快难以同步,我们不同步`pytorch-nightly`, `pytorch-nightly-cpu`, `ignite-nightly`这三个包。
|
||||
|
||||
|
|
@ -18,20 +18,20 @@ TUNA 还提供了 Anaconda 仓库与第三方源(conda-forge、msys2、pytorch
|
|||
channels:
|
||||
- defaults
|
||||
show_channel_urls: true
|
||||
channel_alias: https://mirrors.tuna.tsinghua.edu.cn/anaconda
|
||||
channel_alias: {{ site.url }}/anaconda
|
||||
default_channels:
|
||||
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main
|
||||
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free
|
||||
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/r
|
||||
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/pro
|
||||
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/msys2
|
||||
- {{ site.url }}/anaconda/pkgs/main
|
||||
- {{ site.url }}/anaconda/pkgs/free
|
||||
- {{ site.url }}/anaconda/pkgs/r
|
||||
- {{ site.url }}/anaconda/pkgs/pro
|
||||
- {{ site.url }}/anaconda/pkgs/msys2
|
||||
custom_channels:
|
||||
conda-forge: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
|
||||
msys2: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
|
||||
bioconda: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
|
||||
menpo: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
|
||||
pytorch: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
|
||||
simpleitk: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
|
||||
conda-forge: {{ site.url }}/anaconda/cloud
|
||||
msys2: {{ site.url }}/anaconda/cloud
|
||||
bioconda: {{ site.url }}/anaconda/cloud
|
||||
menpo: {{ site.url }}/anaconda/cloud
|
||||
pytorch: {{ site.url }}/anaconda/cloud
|
||||
simpleitk: {{ site.url }}/anaconda/cloud
|
||||
```
|
||||
|
||||
即可添加 Anaconda Python 免费仓库。
|
||||
|
|
@ -44,7 +44,7 @@ custom_channels:
|
|||
|
||||
Miniconda 是一个 Anaconda 的轻量级替代,默认只包含了 python 和 conda,但是可以通过 pip 和 conda 来安装所需要的包。
|
||||
|
||||
Miniconda 安装包可以到 <https://mirrors.tuna.tsinghua.edu.cn/anaconda/miniconda/> 下载。
|
||||
Miniconda 安装包可以到 <{{ site.url }}/anaconda/miniconda/> 下载。
|
||||
|
||||
### 其他三方源
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ permalink: /help/AOSP/
|
|||
**注意: 本镜像是 AOSP 镜像,Android SDK因版权原因,我们不能提供镜像服务。**
|
||||
|
||||
参考 Google 教程 <https://source.android.com/setup/build/downloading>,
|
||||
将 `https://android.googlesource.com/` 全部使用 `https://aosp.tuna.tsinghua.edu.cn/` 代替即可。
|
||||
将 `https://android.googlesource.com/` 全部使用 `https://{{ site.aosp }}/` 代替即可。
|
||||
|
||||
由于使用 HTTPS 协议更安全,并且更便于我们灵活处理,所以强烈推荐使用 HTTPS 协议同步 AOSP 镜像。
|
||||
|
||||
|
|
@ -24,8 +24,8 @@ permalink: /help/AOSP/
|
|||
- **2015-12-21 : 增加每月初始化包,少量修正文档错误**
|
||||
- **2015-10-13 : 修复上游替换文档错误**
|
||||
- **2015-10-13 : 修复次级镜像文档错误**
|
||||
- **2015-10-09 : 恢复 git://aosp.tuna.tsinghua.edu.cn/aosp/ 访问**
|
||||
- **2015-10-08 : 镜像地址更新为 https://aosp.tuna.tsinghua.edu.cn/ (结尾没有/android)**
|
||||
- **2015-10-09 : 恢复 git://{{ site.aosp }}/aosp/ 访问**
|
||||
- **2015-10-08 : 镜像地址更新为 https://{{ site.aosp }}/ (结尾没有/android)**
|
||||
|
||||
### 过程摘录
|
||||
|
||||
|
|
@ -40,13 +40,13 @@ curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
|
|||
chmod a+x ~/bin/repo
|
||||
```
|
||||
|
||||
或者使用tuna的[git-repo镜像](https://mirrors.tuna.tsinghua.edu.cn/help/git-repo/)
|
||||
或者使用tuna的[git-repo镜像]({{ site.url }}/help/git-repo/)
|
||||
|
||||
#### 使用每月更新的初始化包
|
||||
|
||||
由于首次同步需要下载约 30GB 数据,过程中任何网络故障都可能造成同步失败,我们强烈建议您使用初始化包进行初始化。
|
||||
|
||||
下载 <https://mirrors.tuna.tsinghua.edu.cn/aosp-monthly/aosp-latest.tar>,下载完成后记得根据 checksum.txt 的内容校验一下。
|
||||
下载 <{{ site.url }}/aosp-monthly/aosp-latest.tar>,下载完成后记得根据 checksum.txt 的内容校验一下。
|
||||
|
||||
由于所有代码都是从隐藏的 `.repo` 目录中 checkout 出来的,所以我们只保留了 `.repo` 目录,下载后解压
|
||||
再 `repo sync` 一遍即可得到完整的目录。
|
||||
|
|
@ -54,7 +54,7 @@ chmod a+x ~/bin/repo
|
|||
使用方法如下:
|
||||
|
||||
```bash
|
||||
wget -c https://mirrors.tuna.tsinghua.edu.cn/aosp-monthly/aosp-latest.tar # 下载初始化包
|
||||
wget -c {{ site.url }}/aosp-monthly/aosp-latest.tar # 下载初始化包
|
||||
tar xf aosp-latest.tar
|
||||
cd AOSP # 解压得到的 AOSP 工程目录
|
||||
# 这时 ls 的话什么也看不到,因为只有一个隐藏的 .repo 目录
|
||||
|
|
@ -78,7 +78,7 @@ cd WORKING_DIRECTORY
|
|||
初始化仓库:
|
||||
|
||||
```
|
||||
repo init -u https://aosp.tuna.tsinghua.edu.cn/platform/manifest
|
||||
repo init -u https://{{ site.aosp }}/platform/manifest
|
||||
```
|
||||
|
||||
**如果提示无法连接到 gerrit.googlesource.com,请参照[git-repo的帮助页面](/help/git-repo)的更新一节。**
|
||||
|
|
@ -86,7 +86,7 @@ repo init -u https://aosp.tuna.tsinghua.edu.cn/platform/manifest
|
|||
如果需要某个特定的 Android 版本([列表](https://source.android.com/setup/start/build-numbers#source-code-tags-and-builds)):
|
||||
|
||||
```
|
||||
repo init -u https://aosp.tuna.tsinghua.edu.cn/platform/manifest -b android-4.0.1_r1
|
||||
repo init -u https://{{ site.aosp }}/platform/manifest -b android-4.0.1_r1
|
||||
```
|
||||
|
||||
同步源码树(以后只需执行这条命令来同步):
|
||||
|
|
@ -110,7 +110,7 @@ repo sync
|
|||
初始化:
|
||||
|
||||
```
|
||||
repo init -u https://aosp.tuna.tsinghua.edu.cn/mirror/manifest --mirror
|
||||
repo init -u https://{{ site.aosp }}/mirror/manifest --mirror
|
||||
```
|
||||
|
||||
最后同步源码树:
|
||||
|
|
@ -128,14 +128,14 @@ repo sync
|
|||
如果你之前已经通过某种途径获得了 AOSP 的源码(或者你只是 init 这一步完成后),
|
||||
你希望以后通过 TUNA 同步 AOSP 部分的代码,只需要将
|
||||
`.repo/manifest.xml` 把其中的 aosp 这个 remote 的 fetch 从
|
||||
`https://android.googlesource.com` 改为 `https://aosp.tuna.tsinghua.edu.cn/`。
|
||||
`https://android.googlesource.com` 改为 `https://{{ site.aosp }}/`。
|
||||
|
||||
```diff
|
||||
<manifest>
|
||||
|
||||
<remote name="aosp"
|
||||
- fetch="https://android.googlesource.com"
|
||||
+ fetch="https://aosp.tuna.tsinghua.edu.cn"
|
||||
+ fetch="https://{{ site.aosp }}"
|
||||
review="android-review.googlesource.com" />
|
||||
|
||||
<remote name="github"
|
||||
|
|
@ -150,7 +150,7 @@ url = https://android.googlesource.com/platform/manifest
|
|||
更改为
|
||||
|
||||
```
|
||||
url = https://aosp.tuna.tsinghua.edu.cn/platform/manifest
|
||||
url = https://{{ site.aosp }}/platform/manifest
|
||||
```
|
||||
|
||||
### FAQ
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ mirrorid: archlinux
|
|||
|
||||
编辑 /etc/pacman.d/mirrorlist, 在文件的最顶端添加:
|
||||
```
|
||||
Server = https://mirrors.tuna.tsinghua.edu.cn/archlinux/$repo/os/$arch
|
||||
Server = https://{{ site.hostname }}/archlinux/$repo/os/$arch
|
||||
```
|
||||
|
||||
更新软件包缓存:
|
||||
|
|
@ -19,7 +19,7 @@ sudo pacman -Syy
|
|||
## Arch Linux Rollback Machine使用帮助
|
||||
|
||||
因为 Arch Linux 的软件仓库和 iso 列表是不维护旧版本的,在少数情况下可能会需要安装旧版本的软件或系统,
|
||||
因此TUNA维护了一个[Arch Linux Rollback Machine](https://arch-archive.tuna.tsinghua.edu.cn/)来满足这种情况。
|
||||
因此TUNA维护了一个[Arch Linux Rollback Machine](https://{{ site.arch_archive }}/)来满足这种情况。
|
||||
|
||||
Arch Linux Rollback Machine的使用方法请参照 [wiki](https://wiki.archlinux.org/index.php/Arch_Linux_Archive)。
|
||||
|
||||
|
|
|
|||
|
|
@ -13,13 +13,13 @@ Arch Linux 中文社区仓库 是由 Arch Linux
|
|||
[点击这里](https://github.com/archlinuxcn/repo) 查看。
|
||||
|
||||
* 官方仓库地址:<http://repo.archlinuxcn.org>
|
||||
* 镜像地址: <https://mirrors.tuna.tsinghua.edu.cn/archlinuxcn/>
|
||||
* 镜像地址: <https://{{ site.hostname }}/archlinuxcn/>
|
||||
|
||||
使用方法:在 `/etc/pacman.conf` 文件末尾添加以下两行:
|
||||
|
||||
```
|
||||
[archlinuxcn]
|
||||
Server = https://mirrors.tuna.tsinghua.edu.cn/archlinuxcn/$arch
|
||||
Server = https://{{ site.hostname }}/archlinuxcn/$arch
|
||||
```
|
||||
|
||||
之后安装 `archlinuxcn-keyring` 包导入 GPG key。
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ mirrorid: bananian
|
|||
[Bananian](https://www.bananian.org/) 是为 [Banana Pi](http://www.banana-pi.org/) 制作的,基于官方 Debian 仓库的发行版,
|
||||
其内核和 bootloader 为 Banana Pi 做了定制化。
|
||||
|
||||
安装镜像可以到 <https://mirrors.tuna.tsinghua.edu.cn/bananian/releases/> 获取。
|
||||
安装镜像可以到 <https://{{ site.hostname }}/bananian/releases/> 获取。
|
||||
|
||||
### 使用 TUNA 镜像作为软件仓库
|
||||
|
||||
|
|
@ -37,19 +37,19 @@ gpg --armor --export 24BFF712 | sudo apt-key add -
|
|||
<script id="apt-template" type="x-tmpl-markup">
|
||||
# 激活 TUNA bananian 镜像
|
||||
sudo cat > /etc/apt/sources.list.d/bananian.list << EOF
|
||||
deb http://mirrors.tuna.tsinghua.edu.cn/bananian/packages {{release_name}} main
|
||||
deb http://{{ site.hostname }}/bananian/packages {{release_name}} main
|
||||
EOF
|
||||
|
||||
# 激活 TUNA debian 镜像
|
||||
sudo cat > /etc/apt/sources.list << EOF
|
||||
deb http://mirrors.tuna.tsinghua.edu.cn/debian/ {{debian}} main contrib non-free
|
||||
deb http://mirrors.tuna.tsinghua.edu.cn/debian/ {{debian}}-backports main contrib non-free
|
||||
deb http://mirrors.tuna.tsinghua.edu.cn/debian/ {{debian}}-updates main contrib non-free
|
||||
deb http://mirrors.tuna.tsinghua.edu.cn/debian-security/ {{debian}}/updates main contrib non-free
|
||||
deb-src http://mirrors.tuna.tsinghua.edu.cn/debian/ {{debian}} main contrib non-free
|
||||
deb-src http://mirrors.tuna.tsinghua.edu.cn/debian/ {{debian}}-backports main contrib non-free
|
||||
deb-src http://mirrors.tuna.tsinghua.edu.cn/debian/ {{debian}}-updates main contrib non-free
|
||||
deb-src http://mirrors.tuna.tsinghua.edu.cn/debian-security/ {{debian}}/updates main contrib non-free
|
||||
deb http://{{ site.hostname }}/debian/ {{debian}} main contrib non-free
|
||||
deb http://{{ site.hostname }}/debian/ {{debian}}-backports main contrib non-free
|
||||
deb http://{{ site.hostname }}/debian/ {{debian}}-updates main contrib non-free
|
||||
deb http://{{ site.hostname }}/debian-security/ {{debian}}/updates main contrib non-free
|
||||
deb-src http://{{ site.hostname }}/debian/ {{debian}} main contrib non-free
|
||||
deb-src http://{{ site.hostname }}/debian/ {{debian}}-backports main contrib non-free
|
||||
deb-src http://{{ site.hostname }}/debian/ {{debian}}-updates main contrib non-free
|
||||
deb-src http://{{ site.hostname }}/debian-security/ {{debian}}/updates main contrib non-free
|
||||
EOF
|
||||
</script>
|
||||
{% endraw %}
|
||||
|
|
|
|||
|
|
@ -9,19 +9,19 @@ mirrorid: binutils-gdb.git
|
|||
如需克隆 Binutils 等项目的代码,使用
|
||||
|
||||
```
|
||||
git clone https://mirrors.tuna.tsinghua.edu.cn/git/binutils-gdb.git
|
||||
git clone https://{{ site.hostname }}/git/binutils-gdb.git
|
||||
```
|
||||
|
||||
若要将 tuna mirror 加入已有代码库,可在已有仓库中运行
|
||||
|
||||
```
|
||||
git remote add tuna https://mirrors.tuna.tsinghua.edu.cn/git/binutils-gdb.git
|
||||
git remote add tuna https://{{ site.hostname }}/git/binutils-gdb.git
|
||||
```
|
||||
|
||||
或运行
|
||||
|
||||
```
|
||||
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/binutils-gdb.git
|
||||
git remote set-url origin https://{{ site.hostname }}/git/binutils-gdb.git
|
||||
```
|
||||
|
||||
将默认上游设置为 TUNA 镜像
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ mirrorid: centos
|
|||
sudo mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak
|
||||
```
|
||||
|
||||
然后编辑 /etc/yum.repos.d/CentOS-Base.repo 文件,在 `mirrorlist=` 开头行前面加 `#` 注释掉;并将 `baseurl=` 开头行取消注释(如果被注释的话),把该行内的域名(例如`mirror.centos.org`)替换为 `mirrors.tuna.tsinghua.edu.cn`。
|
||||
然后编辑 /etc/yum.repos.d/CentOS-Base.repo 文件,在 `mirrorlist=` 开头行前面加 `#` 注释掉;并将 `baseurl=` 开头行取消注释(如果被注释的话),把该行内的域名(例如`mirror.centos.org`)替换为 `{{ site.hostname }}`。
|
||||
|
||||
或者,你也可以直接使用如下内容覆盖掉 /etc/yum.repos.d/CentOS-Base.repo 文件:(未经充分测试)
|
||||
|
||||
|
|
@ -45,7 +45,7 @@ sudo mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak
|
|||
{{if release_name|between>5>7}}
|
||||
[base]
|
||||
name=CentOS-$releasever - Base
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/os/$basearch/
|
||||
baseurl=https://{{ site.hostname }}/centos/$releasever/os/$basearch/
|
||||
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
|
|
@ -54,7 +54,7 @@ gpgkey=file:///etc/pki/rpm-gpg/{{release_security}}
|
|||
#released updates
|
||||
[updates]
|
||||
name=CentOS-$releasever - Updates
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/updates/$basearch/
|
||||
baseurl=https://{{ site.hostname }}/centos/$releasever/updates/$basearch/
|
||||
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
|
|
@ -63,7 +63,7 @@ gpgkey=file:///etc/pki/rpm-gpg/{{release_security}}
|
|||
{{if release_name|equals>8}}
|
||||
[Base OS]
|
||||
name=CentOS-$releasever - Base
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/BaseOS/$basearch/os/
|
||||
baseurl=https://{{ site.hostname }}/centos/$releasever/BaseOS/$basearch/os/
|
||||
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=BaseOS&infra=$infra
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
|
|
@ -71,7 +71,7 @@ gpgkey=file:///etc/pki/rpm-gpg/{{release_security}}
|
|||
|
||||
[AppStream]
|
||||
name=CentOS-$releasever - AppStream
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/AppStream/$basearch/os/
|
||||
baseurl=https://{{ site.hostname }}/centos/$releasever/AppStream/$basearch/os/
|
||||
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=AppStream&infra=$infra
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
|
|
@ -79,7 +79,7 @@ gpgkey=file:///etc/pki/rpm-gpg/{{release_security}}
|
|||
|
||||
[PowerTools]
|
||||
name=CentOS-$releasever - PowerTools
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/PowerTools/$basearch/os/
|
||||
baseurl=https://{{ site.hostname }}/centos/$releasever/PowerTools/$basearch/os/
|
||||
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=PowerTools&infra=$infra
|
||||
enabled=0
|
||||
gpgcheck=1
|
||||
|
|
@ -89,7 +89,7 @@ gpgkey=file:///etc/pki/rpm-gpg/{{release_security}}
|
|||
#additional packages that may be useful
|
||||
[extras]
|
||||
name=CentOS-$releasever - Extras
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/extras/$basearch/{{os_name}}
|
||||
baseurl=https://{{ site.hostname }}/centos/$releasever/extras/$basearch/{{os_name}}
|
||||
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extras
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
|
|
@ -99,7 +99,7 @@ gpgkey=file:///etc/pki/rpm-gpg/{{release_security}}
|
|||
#packages used/produced in the build but not released
|
||||
[addons]
|
||||
name=CentOS-$releasever - Addons
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/addons/$basearch/
|
||||
baseurl=https://{{ site.hostname }}/centos/$releasever/addons/$basearch/
|
||||
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=addons
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
|
|
@ -109,7 +109,7 @@ gpgkey=file:///etc/pki/rpm-gpg/{{release_security}}
|
|||
#additional packages that extend functionality of existing packages
|
||||
[centosplus]
|
||||
name=CentOS-$releasever - Plus
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/centosplus/$basearch/{{os_name}}
|
||||
baseurl=https://{{ site.hostname }}/centos/$releasever/centosplus/$basearch/{{os_name}}
|
||||
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplus
|
||||
gpgcheck=1
|
||||
enabled=0
|
||||
|
|
@ -119,7 +119,7 @@ gpgkey=file:///etc/pki/rpm-gpg/{{release_security}}
|
|||
#contrib - packages by Centos Users
|
||||
[contrib]
|
||||
name=CentOS-$releasever - Contrib
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/$releasever/contrib/$basearch/
|
||||
baseurl=https://{{ site.hostname }}/centos/$releasever/contrib/$basearch/
|
||||
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contrib
|
||||
gpgcheck=1
|
||||
enabled=0
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
|
|||
chmod a+x ~/bin/repo
|
||||
```
|
||||
|
||||
或者使用tuna的[git-repo镜像](https://mirrors.tuna.tsinghua.edu.cn/help/git-repo/)
|
||||
或者使用tuna的[git-repo镜像](https://{{ site.hostname }}/help/git-repo/)
|
||||
|
||||
#### 下载代码
|
||||
|
||||
|
|
@ -34,7 +34,7 @@ cd WORKING_DIRECTORY
|
|||
初始化仓库:
|
||||
|
||||
```
|
||||
repo init -u https://mirrors.tuna.tsinghua.edu.cn/git/chromiumos/chromiumos/manifest
|
||||
repo init -u https://{{ site.hostname }}/git/chromiumos/chromiumos/manifest
|
||||
```
|
||||
|
||||
**注意: 本镜像是 Chromium OS 的 master 分支的镜像,如果使用本镜像下载 Chromium OS 的其他版本很大概率会失败**
|
||||
|
|
@ -50,7 +50,7 @@ repo init -u https://mirrors.tuna.tsinghua.edu.cn/git/chromiumos/chromiumos/mani
|
|||
替换为
|
||||
|
||||
```
|
||||
"https://mirrors.tuna.tsinghua.edu.cn/git/chromiumos/"
|
||||
"https://{{ site.hostname }}/git/chromiumos/"
|
||||
```
|
||||
|
||||
接着将
|
||||
|
|
@ -62,7 +62,7 @@ repo init -u https://mirrors.tuna.tsinghua.edu.cn/git/chromiumos/chromiumos/mani
|
|||
替换为
|
||||
|
||||
```
|
||||
"https://aosp.tuna.tsinghua.edu.cn/"
|
||||
"https://{{ site.aosp }}/"
|
||||
```
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ mirrorid: clickhouse
|
|||
新建 `/etc/apt/sources.list.d/clickhouse.list`,内容为
|
||||
|
||||
```
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/clickhouse/deb/stable/ main/
|
||||
deb https://{{ site.hostname }}/clickhouse/deb/stable/ main/
|
||||
```
|
||||
|
||||
|
||||
|
|
@ -24,6 +24,6 @@ deb https://mirrors.tuna.tsinghua.edu.cn/clickhouse/deb/stable/ main/
|
|||
```
|
||||
[repo.yandex.ru_clickhouse_rpm_stable_x86_64]
|
||||
name=clickhouse stable
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/clickhouse/rpm/stable/x86_64
|
||||
baseurl=https://{{ site.hostname }}/clickhouse/rpm/stable/x86_64
|
||||
enabled=1
|
||||
```
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ mirrorid: crates.io-index.git
|
|||
replace-with = 'tuna'
|
||||
|
||||
[source.tuna]
|
||||
registry = "https://mirrors.tuna.tsinghua.edu.cn/git/crates.io-index.git"
|
||||
registry = "https://{{ site.hostname }}/git/crates.io-index.git"
|
||||
```
|
||||
|
||||
该镜像可加快 cargo 读取软件包索引的速度。
|
||||
|
|
|
|||
|
|
@ -12,10 +12,10 @@ Cygwin 镜像使用帮助
|
|||
选择`Install from Internet`, 在"User URL"处输入以下地址:
|
||||
|
||||
```
|
||||
https://mirrors.tuna.tsinghua.edu.cn/cygwin/
|
||||
https://{{ site.hostname }}/cygwin/
|
||||
```
|
||||
|
||||
点击"Add"按钮, 然后选中"https://mirrors.tuna.tsinghua.edu.cn", 点击"下一步"进行安装。
|
||||
点击"Add"按钮, 然后选中"https://{{ site.hostname }}", 点击"下一步"进行安装。
|
||||
|
||||
注意,该列表为可多选列表,注意把上面不需要的镜像点掉。
|
||||
|
||||
|
|
|
|||
|
|
@ -37,14 +37,14 @@ $ sudo apt install apt-transport-https
|
|||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ {{release_name}} main contrib non-free
|
||||
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ {{release_name}} main contrib non-free{{if release_name|notequals>sid}}
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ {{release_name}}-updates main contrib non-free
|
||||
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ {{release_name}}-updates main contrib non-free
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ {{release_name}}-backports main contrib non-free
|
||||
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ {{release_name}}-backports main contrib non-free
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/debian-security {{release_name}}{{release_security}} main contrib non-free
|
||||
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian-security {{release_name}}{{release_security}} main contrib non-free
|
||||
deb https://{{ site.hostname }}/debian/ {{release_name}} main contrib non-free
|
||||
# deb-src https://{{ site.hostname }}/debian/ {{release_name}} main contrib non-free{{if release_name|notequals>sid}}
|
||||
deb https://{{ site.hostname }}/debian/ {{release_name}}-updates main contrib non-free
|
||||
# deb-src https://{{ site.hostname }}/debian/ {{release_name}}-updates main contrib non-free
|
||||
deb https://{{ site.hostname }}/debian/ {{release_name}}-backports main contrib non-free
|
||||
# deb-src https://{{ site.hostname }}/debian/ {{release_name}}-backports main contrib non-free
|
||||
deb https://{{ site.hostname }}/debian-security {{release_name}}{{release_security}} main contrib non-free
|
||||
# deb-src https://{{ site.hostname }}/debian-security {{release_name}}{{release_security}} main contrib non-free
|
||||
{{/if}}
|
||||
|
||||
</script>
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@ sudo apt-get install apt-transport-https ca-certificates curl gnupg2 software-pr
|
|||
<p></p>
|
||||
<pre>
|
||||
<code class="language-bash" id="deb-amd64-content">sudo add-apt-repository \
|
||||
"deb [arch=amd64] https://mirrors.tuna.tsinghua.edu.cn/docker-ce/linux/{{deb_release}} \
|
||||
"deb [arch=amd64] https://{{ site.hostname }}/docker-ce/linux/{{deb_release}} \
|
||||
$(lsb_release -cs) \
|
||||
stable"</code>
|
||||
</pre>
|
||||
|
|
@ -63,7 +63,7 @@ sudo apt-get install apt-transport-https ca-certificates curl gnupg2 software-pr
|
|||
{% raw %}
|
||||
<p></p>
|
||||
<pre>
|
||||
<code id="deb-arm-content">echo "deb [arch=armhf] https://mirrors.tuna.tsinghua.edu.cn/docker-ce/linux/{{deb_release}} \
|
||||
<code id="deb-arm-content">echo "deb [arch=armhf] https://{{ site.hostname }}/docker-ce/linux/{{deb_release}} \
|
||||
$(lsb_release -cs) stable" | \
|
||||
sudo tee /etc/apt/sources.list.d/docker.list</code>
|
||||
</pre>
|
||||
|
|
@ -112,7 +112,7 @@ sudo yum install -y yum-utils device-mapper-persistent-data lvm2
|
|||
把软件仓库地址替换为 TUNA:
|
||||
|
||||
```bash
|
||||
sudo sed -i 's+download.docker.com+mirrors.tuna.tsinghua.edu.cn/docker-ce+' /etc/yum.repos.d/docker-ce.repo
|
||||
sudo sed -i 's+download.docker.com+{{ site.hostname }}/docker-ce+' /etc/yum.repos.d/docker-ce.repo
|
||||
```
|
||||
|
||||
最后安装:
|
||||
|
|
|
|||
|
|
@ -11,18 +11,18 @@ ELPA 是 Emacs 内建包管理器 `package.el` 的软件源,本镜像支持了
|
|||
|
||||
| ELPA | 镜像地址 |
|
||||
|-------------------|---------------------------------------------|
|
||||
| [GNU ELPA](http://elpa.gnu.org/) | http://mirrors.tuna.tsinghua.edu.cn/elpa/gnu/ |
|
||||
| [MELPA](https://melpa.org/) | http://mirrors.tuna.tsinghua.edu.cn/elpa/melpa/ |
|
||||
| [MELPA Stable](http://stable.melpa.org/#/) | http://mirrors.tuna.tsinghua.edu.cn/elpa/melpa-stable/ |
|
||||
| [Marmalade](https://marmalade-repo.org/) | http://mirrors.tuna.tsinghua.edu.cn/elpa/marmalade/ |
|
||||
| [Org](http://orgmode.org/elpa.html) | http://mirrors.tuna.tsinghua.edu.cn/elpa/org/ |
|
||||
| [GNU ELPA](http://elpa.gnu.org/) | http://{{ site.hostname }}/elpa/gnu/ |
|
||||
| [MELPA](https://melpa.org/) | http://{{ site.hostname }}/elpa/melpa/ |
|
||||
| [MELPA Stable](http://stable.melpa.org/#/) | http://{{ site.hostname }}/elpa/melpa-stable/ |
|
||||
| [Marmalade](https://marmalade-repo.org/) | http://{{ site.hostname }}/elpa/marmalade/ |
|
||||
| [Org](http://orgmode.org/elpa.html) | http://{{ site.hostname }}/elpa/org/ |
|
||||
|
||||
|
||||
根据你的需求,设置 package-archives ,比如用 GNU ELPA 和 MELPA:
|
||||
|
||||
```lisp
|
||||
(setq package-archives '(("gnu" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/gnu/")
|
||||
("melpa" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/melpa/")))
|
||||
(setq package-archives '(("gnu" . "http://{{ site.hostname }}/elpa/gnu/")
|
||||
("melpa" . "http://{{ site.hostname }}/elpa/melpa/")))
|
||||
(package-initialize) ;; You might already have this line
|
||||
```
|
||||
|
||||
|
|
@ -36,9 +36,9 @@ Spacemacs 用户
|
|||
|
||||
```lisp
|
||||
(setq configuration-layer--elpa-archives
|
||||
'(("melpa-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/melpa/")
|
||||
("org-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/org/")
|
||||
("gnu-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/gnu/")))
|
||||
'(("melpa-cn" . "http://{{ site.hostname }}/elpa/melpa/")
|
||||
("org-cn" . "http://{{ site.hostname }}/elpa/org/")
|
||||
("gnu-cn" . "http://{{ site.hostname }}/elpa/gnu/")))
|
||||
```
|
||||
### develop 分支
|
||||
|
||||
|
|
@ -46,9 +46,9 @@ Spacemacs 用户
|
|||
|
||||
```lisp
|
||||
(setq configuration-layer-elpa-archives
|
||||
'(("melpa-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/melpa/")
|
||||
("org-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/org/")
|
||||
("gnu-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/gnu/")))
|
||||
'(("melpa-cn" . "http://{{ site.hostname }}/elpa/melpa/")
|
||||
("org-cn" . "http://{{ site.hostname }}/elpa/org/")
|
||||
("gnu-cn" . "http://{{ site.hostname }}/elpa/gnu/")))
|
||||
```
|
||||
|
||||
Cask 用户
|
||||
|
|
@ -57,8 +57,8 @@ Cask 用户
|
|||
[Cask](https://github.com/cask/cask) 是一个 Emacs Lisp 的项目管理工具。这里还是以 GNU ELPA 和 MELPA 为例,在添加下面的代码到 Cask
|
||||
|
||||
```lisp
|
||||
(source "gnu" "http://mirrors.tuna.tsinghua.edu.cn/elpa/gnu/")
|
||||
(source "melpa" "http://mirrors.tuna.tsinghua.edu.cn/elpa/melpa/")
|
||||
(source "gnu" "http://{{ site.hostname }}/elpa/gnu/")
|
||||
(source "melpa" "http://{{ site.hostname }}/elpa/melpa/")
|
||||
```
|
||||
|
||||
关于 ELPA 的选择
|
||||
|
|
@ -86,10 +86,10 @@ URL Bug
|
|||
|
||||
事实上,末尾没有`/`的话,emacs会去尝试取以下链接:
|
||||
|
||||
- <http://mirrors.tuna.tsinghua.edu.cn/elpa/melpaarchive-contents>
|
||||
- <http://{{ site.hostname }}/elpa/melpaarchive-contents>
|
||||
|
||||
而正常的链接应该是
|
||||
|
||||
- <http://mirrors.tuna.tsinghua.edu.cn/elpa/melpa/archive-contents>
|
||||
- <http://{{ site.hostname }}/elpa/melpa/archive-contents>
|
||||
|
||||
这个是emacs自己的bug。在 <https://github.com/melpa/melpa/issues/2139> 中有描述。
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ EPEL(Extra Packages for Enterprise Linux)是由Fedora Special Interest Group维
|
|||
|
||||
下面以CentOS 7为例讲解如何使用tuna的epel镜像。
|
||||
|
||||
首先从CentOS Extras这个源([tuna](https://mirrors.tuna.tsinghua.edu.cn/help/centos)也有镜像)里安装epel-release:
|
||||
首先从CentOS Extras这个源([tuna](https://{{ site.hostname }}/help/centos)也有镜像)里安装epel-release:
|
||||
|
||||
```
|
||||
yum install epel-release
|
||||
|
|
@ -21,14 +21,14 @@ yum install epel-release
|
|||
当前tuna已经在epel的官方镜像列表里,所以不需要其他配置,mirrorlist机制就能让你的服务器就近使用tuna的镜像。如果你想强制
|
||||
你的服务器使用tuna的镜像,可以修改`/etc/yum.repos.d/epel.repo`,将`mirrorlist`和`metalink`开头的行注释掉。
|
||||
|
||||
接下来,取消注释这个文件里`baseurl`开头的行,并将其中的`http://download.fedoraproject.org/pub`替换成`https://mirrors.tuna.tsinghua.edu.cn`。
|
||||
接下来,取消注释这个文件里`baseurl`开头的行,并将其中的`http://download.fedoraproject.org/pub`替换成`https://{{ site.hostname }}`。
|
||||
|
||||
可以用如下命令自动替换:(来自 https://github.com/tuna/issues/issues/687)
|
||||
|
||||
```
|
||||
sed -e 's!^metalink=!#metalink=!g' \
|
||||
-e 's!^#baseurl=!baseurl=!g' \
|
||||
-e 's!//download\.fedoraproject\.org/pub!//mirrors.tuna.tsinghua.edu.cn!g' \
|
||||
-e 's!//download\.fedoraproject\.org/pub!//{{ site.hostname }}!g' \
|
||||
-e 's!http://mirrors\.tuna!https://mirrors.tuna!g' \
|
||||
-i /etc/yum.repos.d/epel.repo /etc/yum.repos.d/epel-testing.repo
|
||||
```
|
||||
|
|
@ -38,7 +38,7 @@ sed -e 's!^metalink=!#metalink=!g' \
|
|||
```
|
||||
[epel]
|
||||
name=Extra Packages for Enterprise Linux 7 - $basearch
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/epel/7/$basearch
|
||||
baseurl=https://{{ site.hostname }}/epel/7/$basearch
|
||||
#mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-7&arch=$basearch
|
||||
failovermethod=priority
|
||||
enabled=1
|
||||
|
|
@ -47,7 +47,7 @@ gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
|
|||
|
||||
[epel-debuginfo]
|
||||
name=Extra Packages for Enterprise Linux 7 - $basearch - Debug
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/epel/7/$basearch/debug
|
||||
baseurl=https://{{ site.hostname }}/epel/7/$basearch/debug
|
||||
#mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-debug-7&arch=$basearch
|
||||
failovermethod=priority
|
||||
enabled=0
|
||||
|
|
@ -56,7 +56,7 @@ gpgcheck=1
|
|||
|
||||
[epel-source]
|
||||
name=Extra Packages for Enterprise Linux 7 - $basearch - Source
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/epel/7/SRPMS
|
||||
baseurl=https://{{ site.hostname }}/epel/7/SRPMS
|
||||
#mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-source-7&arch=$basearch
|
||||
failovermethod=priority
|
||||
enabled=0
|
||||
|
|
|
|||
|
|
@ -8,10 +8,10 @@ mirrorid: fdroid
|
|||
|
||||
用 F-Droid 客户端打开此链接:
|
||||
|
||||
https://mirrors.tuna.tsinghua.edu.cn/fdroid/repo/?fingerprint=43238D512C1E5EB2D6569F4A3AFBF5523418B82E0A3ED1552770ABB9A9C9CCAB
|
||||
https://{{ site.hostname }}/fdroid/repo/?fingerprint=43238D512C1E5EB2D6569F4A3AFBF5523418B82E0A3ED1552770ABB9A9C9CCAB
|
||||
|
||||
或复制此链接后在客户端中添加存储库,可以将此镜像添加为用户镜像。
|
||||
|
||||
如果需要添加 Archive 库,可以使用如下链接:
|
||||
|
||||
https://mirrors.tuna.tsinghua.edu.cn/fdroid/archive?fingerprint=43238D512C1E5EB2D6569F4A3AFBF5523418B82E0A3ED1552770ABB9A9C9CCAB
|
||||
https://{{ site.hostname }}/fdroid/archive?fingerprint=43238D512C1E5EB2D6569F4A3AFBF5523418B82E0A3ED1552770ABB9A9C9CCAB
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ Fedora 29 及更旧版本已不再受官方支持,Fedora 官方已将 Fedora 2
|
|||
[fedora]
|
||||
name=Fedora $releasever - $basearch
|
||||
failovermethod=priority
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/fedora/releases/$releasever/Everything/$basearch/os/
|
||||
baseurl=https://{{ site.hostname }}/fedora/releases/$releasever/Everything/$basearch/os/
|
||||
metadata_expire=28d
|
||||
gpgcheck=1
|
||||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-$releasever-$basearch
|
||||
|
|
@ -39,7 +39,7 @@ skip_if_unavailable=False
|
|||
[updates]
|
||||
name=Fedora $releasever - $basearch - Updates
|
||||
failovermethod=priority
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/fedora/updates/$releasever/Everything/$basearch/
|
||||
baseurl=https://{{ site.hostname }}/fedora/updates/$releasever/Everything/$basearch/
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
metadata_expire=6h
|
||||
|
|
@ -53,7 +53,7 @@ skip_if_unavailable=False
|
|||
[fedora-modular]
|
||||
name=Fedora Modular $releasever - $basearch
|
||||
failovermethod=priority
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/fedora/releases/$releasever/Modular/$basearch/os/
|
||||
baseurl=https://{{ site.hostname }}/fedora/releases/$releasever/Modular/$basearch/os/
|
||||
enabled=1
|
||||
metadata_expire=7d
|
||||
gpgcheck=1
|
||||
|
|
@ -67,7 +67,7 @@ skip_if_unavailable=False
|
|||
[updates-modular]
|
||||
name=Fedora Modular $releasever - $basearch - Updates
|
||||
failovermethod=priority
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/fedora/updates/$releasever/Modular/$basearch/
|
||||
baseurl=https://{{ site.hostname }}/fedora/updates/$releasever/Modular/$basearch/
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
metadata_expire=6h
|
||||
|
|
|
|||
|
|
@ -9,19 +9,19 @@ mirrorid: gcc.git
|
|||
如需克隆 GCC 代码,使用
|
||||
|
||||
```
|
||||
git clone https://mirrors.tuna.tsinghua.edu.cn/git/gcc.git
|
||||
git clone https://{{ site.hostname }}/git/gcc.git
|
||||
```
|
||||
|
||||
若要将 tuna mirror 加入已有代码库,可在已有仓库中运行
|
||||
|
||||
```
|
||||
git remote add tuna https://mirrors.tuna.tsinghua.edu.cn/git/gcc.git
|
||||
git remote add tuna https://{{ site.hostname }}/git/gcc.git
|
||||
```
|
||||
|
||||
或运行
|
||||
|
||||
```
|
||||
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/gcc.git
|
||||
git remote set-url origin https://{{ site.hostname }}/git/gcc.git
|
||||
```
|
||||
|
||||
将默认上游设置为 TUNA 镜像
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ mirrorid: git-repo
|
|||
### 下载
|
||||
|
||||
```
|
||||
curl https://mirrors.tuna.tsinghua.edu.cn/git/git-repo -o repo
|
||||
curl https://{{ site.hostname }}/git/git-repo -o repo
|
||||
chmod +x repo
|
||||
```
|
||||
|
||||
|
|
@ -24,7 +24,7 @@ chmod +x repo
|
|||
repo的运行过程中会尝试访问官方的git源更新自己,如果想使用tuna的镜像源进行更新,可以将如下内容复制到你的`~/.bashrc`里
|
||||
|
||||
```
|
||||
export REPO_URL='https://mirrors.tuna.tsinghua.edu.cn/git/git-repo'
|
||||
export REPO_URL='https://{{ site.hostname }}/git/git-repo'
|
||||
```
|
||||
|
||||
并重启终端模拟器。
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ sudo apt-get install gitlab-ce
|
|||
|
||||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/{{os_name}} {{release_name}} main
|
||||
deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://{{ site.hostname }}/gitlab-ce/{{os_name}} {{release_name}} main
|
||||
</script>
|
||||
{%endraw%}
|
||||
|
||||
|
|
@ -60,7 +60,7 @@ deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://mirrors.tuna.tsinghua
|
|||
```
|
||||
[gitlab-ce]
|
||||
name=Gitlab CE Repository
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el$releasever/
|
||||
baseurl=https://{{ site.hostname }}/gitlab-ce/yum/el$releasever/
|
||||
gpgcheck=0
|
||||
enabled=1
|
||||
```
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ mirrorid: gitlab-ci-multi-runner
|
|||
## Gitlab CI Multi Runner 镜像使用帮助
|
||||
|
||||
**注意: gitlab-ci-multi-runner 镜像仅支持 x86-64 架构**,如果你需要安装版本 10 及以上的
|
||||
Runner,由于官方名称发生变化,请前往 [gitlab-runner帮助页面](https://mirrors.tuna.tsinghua.edu.cn/help/gitlab-runner/)。
|
||||
Runner,由于官方名称发生变化,请前往 [gitlab-runner帮助页面](https://{{ site.hostname }}/help/gitlab-runner/)。
|
||||
|
||||
### Debian/Ubuntu 用户
|
||||
|
||||
|
|
@ -48,7 +48,7 @@ sudo apt-get install gitlab-ci-multi-runner
|
|||
|
||||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://mirrors.tuna.tsinghua.edu.cn/gitlab-ci-multi-runner/{{os_name}} {{release_name}} main
|
||||
deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://{{ site.hostname }}/gitlab-ci-multi-runner/{{os_name}} {{release_name}} main
|
||||
</script>
|
||||
{%endraw%}
|
||||
|
||||
|
|
@ -86,7 +86,7 @@ sudo yum install gitlab-ci-multi-runner
|
|||
<script id="yum-template" type="x-tmpl-markup">
|
||||
[gitlab-ci-multi-runner]
|
||||
name=gitlab-ci-multi-runner
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/gitlab-ci-multi-runner/yum/{{release_name}}
|
||||
baseurl=https://{{ site.hostname }}/gitlab-ci-multi-runner/yum/{{release_name}}
|
||||
repo_gpgcheck=0
|
||||
gpgcheck=0
|
||||
enabled=1
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ sudo apt-get install gitlab-runner
|
|||
|
||||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://mirrors.tuna.tsinghua.edu.cn/gitlab-runner/{{os_name}} {{release_name}} main
|
||||
deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://{{ site.hostname }}/gitlab-runner/{{os_name}} {{release_name}} main
|
||||
</script>
|
||||
{%endraw%}
|
||||
|
||||
|
|
@ -86,7 +86,7 @@ sudo yum install gitlab-runner
|
|||
<script id="yum-template" type="x-tmpl-markup">
|
||||
[gitlab-runner]
|
||||
name=gitlab-runner
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/gitlab-runner/yum/{{release_name}}
|
||||
baseurl=https://{{ site.hostname }}/gitlab-runner/yum/{{release_name}}
|
||||
repo_gpgcheck=0
|
||||
gpgcheck=0
|
||||
enabled=1
|
||||
|
|
|
|||
|
|
@ -9,19 +9,19 @@ mirrorid: glibc.git
|
|||
如需克隆 GNU C Library 代码,使用
|
||||
|
||||
```
|
||||
git clone https://mirrors.tuna.tsinghua.edu.cn/git/glibc.git
|
||||
git clone https://{{ site.hostname }}/git/glibc.git
|
||||
```
|
||||
|
||||
若要将 tuna mirror 加入已有代码库,可在已有仓库中运行
|
||||
|
||||
```
|
||||
git remote add tuna https://mirrors.tuna.tsinghua.edu.cn/git/glibc.git
|
||||
git remote add tuna https://{{ site.hostname }}/git/glibc.git
|
||||
```
|
||||
|
||||
或运行
|
||||
|
||||
```
|
||||
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/glibc.git
|
||||
git remote set-url origin https://{{ site.hostname }}/git/glibc.git
|
||||
```
|
||||
|
||||
将默认上游设置为 TUNA 镜像
|
||||
|
|
|
|||
|
|
@ -21,8 +21,8 @@ cabal update
|
|||
修改 `~/.cabal/config`,加入
|
||||
|
||||
```
|
||||
repository mirrors.tuna.tsinghua.edu.cn
|
||||
url: http://mirrors.tuna.tsinghua.edu.cn/hackage
|
||||
repository {{ site.hostname }}
|
||||
url: http://{{ site.hostname }}/hackage
|
||||
```
|
||||
|
||||
为了访问速度,可以选择把官方仓库注释掉:
|
||||
|
|
@ -45,7 +45,7 @@ remote-repo: hackage.haskell.org:http://hackage.haskell.org/packages/archive
|
|||
注释掉,改为
|
||||
|
||||
```
|
||||
remote-repo: mirrors.tuna.tsinghua.edu.cn:http://mirrors.tuna.tsinghua.edu.cn/hackage
|
||||
remote-repo: {{ site.hostname }}:http://{{ site.hostname }}/hackage
|
||||
-- remote-repo: hackage.haskell.org:http://hackage.haskell.org/packages/archive
|
||||
```
|
||||
|
||||
|
|
@ -61,7 +61,7 @@ remote-repo: mirrors.tuna.tsinghua.edu.cn:http://mirrors.tuna.tsinghua.edu.cn/ha
|
|||
|
||||
```yaml
|
||||
package-indices:
|
||||
- download-prefix: http://mirrors.tuna.tsinghua.edu.cn/hackage/
|
||||
- download-prefix: http://{{ site.hostname }}/hackage/
|
||||
hackage-security:
|
||||
keyids:
|
||||
- 0a5c7ea47cd1b15f01f5f51a33adda7e655bc0f0b0615baa8e271f4c3351e21d
|
||||
|
|
@ -86,6 +86,6 @@ package-indices:
|
|||
```yaml
|
||||
package-indices:
|
||||
- name: Tsinghua
|
||||
download-prefix: http://mirrors.tuna.tsinghua.edu.cn/hackage/package/
|
||||
http: http://mirrors.tuna.tsinghua.edu.cn/hackage/00-index.tar.gz
|
||||
download-prefix: http://{{ site.hostname }}/hackage/package/
|
||||
http: http://{{ site.hostname }}/hackage/00-index.tar.gz
|
||||
```
|
||||
|
|
|
|||
|
|
@ -6,15 +6,15 @@ mirrorid: homebrew-bottles
|
|||
|
||||
## Homebrew-bottles 镜像使用帮助
|
||||
|
||||
**注:该镜像是 Homebrew 二进制预编译包的镜像。本镜像站同时提供 Homebrew 的 formula 索引的镜像(即 `brew update` 时所更新内容),请参考 [Homebrew 镜像使用帮助](https://mirrors.tuna.tsinghua.edu.cn/help/homebrew/)。**
|
||||
**注:该镜像是 Homebrew 二进制预编译包的镜像。本镜像站同时提供 Homebrew 的 formula 索引的镜像(即 `brew update` 时所更新内容),请参考 [Homebrew 镜像使用帮助](https://{{ site.hostname }}/help/homebrew/)。**
|
||||
|
||||
### 临时替换
|
||||
```bash
|
||||
export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.tuna.tsinghua.edu.cn/homebrew-bottles
|
||||
export HOMEBREW_BOTTLE_DOMAIN=https://{{ site.hostname }}/homebrew-bottles
|
||||
```
|
||||
|
||||
### 长期替换
|
||||
```bash
|
||||
echo 'export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.tuna.tsinghua.edu.cn/homebrew-bottles' >> ~/.bash_profile
|
||||
echo 'export HOMEBREW_BOTTLE_DOMAIN=https://{{ site.hostname }}/homebrew-bottles' >> ~/.bash_profile
|
||||
source ~/.bash_profile
|
||||
```
|
||||
|
|
|
|||
|
|
@ -6,22 +6,22 @@ mirrorid: homebrew
|
|||
|
||||
## Homebrew/Linuxbrew 镜像使用帮助
|
||||
|
||||
**注:该镜像是 Homebrew/Linuxbrew 的 formula 索引的镜像(即 `brew update` 时所更新内容)。本镜像站同时提供相应的二进制预编译包的镜像,请参考 [Homebrew bottles 镜像使用帮助](https://mirrors.tuna.tsinghua.edu.cn/help/homebrew-bottles/) 和 [Linuxbrew bottles 镜像使用帮助](https://mirrors.tuna.tsinghua.edu.cn/help/linuxbrew-bottles/)。**
|
||||
**注:该镜像是 Homebrew/Linuxbrew 的 formula 索引的镜像(即 `brew update` 时所更新内容)。本镜像站同时提供相应的二进制预编译包的镜像,请参考 [Homebrew bottles 镜像使用帮助](https://{{ site.hostname }}/help/homebrew-bottles/) 和 [Linuxbrew bottles 镜像使用帮助](https://{{ site.hostname }}/help/linuxbrew-bottles/)。**
|
||||
|
||||
### 替换现有上游
|
||||
|
||||
```
|
||||
# brew 程序本身,Homebrew/Linuxbrew 相同
|
||||
git -C "$(brew --repo)" remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/brew.git
|
||||
git -C "$(brew --repo)" remote set-url origin https://{{ site.hostname }}/git/homebrew/brew.git
|
||||
|
||||
# 以下针对 mac OS 系统上的 Homebrew
|
||||
git -C "$(brew --repo homebrew/core)" remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git
|
||||
git -C "$(brew --repo homebrew/cask)" remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-cask.git
|
||||
git -C "$(brew --repo homebrew/cask-fonts)" remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-cask-fonts.git
|
||||
git -C "$(brew --repo homebrew/cask-drivers)" remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-cask-drivers.git
|
||||
git -C "$(brew --repo homebrew/core)" remote set-url origin https://{{ site.hostname }}/git/homebrew/homebrew-core.git
|
||||
git -C "$(brew --repo homebrew/cask)" remote set-url origin https://{{ site.hostname }}/git/homebrew/homebrew-cask.git
|
||||
git -C "$(brew --repo homebrew/cask-fonts)" remote set-url origin https://{{ site.hostname }}/git/homebrew/homebrew-cask-fonts.git
|
||||
git -C "$(brew --repo homebrew/cask-drivers)" remote set-url origin https://{{ site.hostname }}/git/homebrew/homebrew-cask-drivers.git
|
||||
|
||||
# 以下针对 Linux 系统上的 Linuxbrew
|
||||
git -C "$(brew --repo homebrew/core)" remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/linuxbrew-core.git
|
||||
git -C "$(brew --repo homebrew/core)" remote set-url origin https://{{ site.hostname }}/git/homebrew/linuxbrew-core.git
|
||||
|
||||
# 更换后测试工作是否正常
|
||||
brew update
|
||||
|
|
@ -53,14 +53,14 @@ brew update
|
|||
```
|
||||
0. 安装 git
|
||||
1. 下载 https://raw.githubusercontent.com/Linuxbrew/install/master/install-ruby
|
||||
2. 将其中 https://homebrew.bintray.com/bottles-portable-ruby/ 换为 https://mirrors.tuna.tsinghua.edu.cn/homebrew-bottles/bottles-portable-ruby/
|
||||
2. 将其中 https://homebrew.bintray.com/bottles-portable-ruby/ 换为 https://{{ site.hostname }}/homebrew-bottles/bottles-portable-ruby/
|
||||
3. 运行 ./install-ruby 安装 portable ruby
|
||||
4. export PATH=/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/portable-ruby/current/bin:$PATH # ==> Add Ruby to your PATH
|
||||
5. 下载 https://raw.githubusercontent.com/Linuxbrew/install/master/install
|
||||
6. 将其中 https://github.com/Homebrew/brew 换为 https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/brew.git
|
||||
6. 将其中 https://github.com/Homebrew/brew 换为 https://{{ site.hostname }}/git/homebrew/brew.git
|
||||
7. 运行 ./install 安装 brew
|
||||
8. 执行到 “==> Tapping homebrew/core” 时 Ctrl-C
|
||||
9. export PATH=/home/linuxbrew/.linuxbrew/Homebrew/bin:$PATH # 将 brew 添加到 PATH
|
||||
10. git clone https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/linuxbrew-core.git "$(brew --repo homebrew/core)"
|
||||
10. git clone https://{{ site.hostname }}/git/homebrew/linuxbrew-core.git "$(brew --repo homebrew/core)"
|
||||
11. 再次运行 ./install 即可到达安装成功结果
|
||||
```
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ Kubernetes 是用于自动部署,扩展和管理容器化应用程序的开源
|
|||
|
||||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/kubernetes/apt kubernetes-{{release_name}} main
|
||||
deb https://{{ site.hostname }}/kubernetes/apt kubernetes-{{release_name}} main
|
||||
</script>
|
||||
{%endraw%}
|
||||
|
||||
|
|
@ -47,7 +47,7 @@ deb https://mirrors.tuna.tsinghua.edu.cn/kubernetes/apt kubernetes-{{release_nam
|
|||
```
|
||||
[kubernetes]
|
||||
name=kubernetes
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/kubernetes/yum/repos/kubernetes-el7-x86_64
|
||||
baseurl=https://{{ site.hostname }}/kubernetes/yum/repos/kubernetes-el7-x86_64
|
||||
enabled=1
|
||||
```
|
||||
|
||||
|
|
@ -55,4 +55,4 @@ enabled=1
|
|||
|
||||
### Minikube
|
||||
|
||||
请到 [minikube 镜像](https://mirrors.tuna.tsinghua.edu.cn/github-release/kubernetes/minikube/LatestRelease/) 下载。
|
||||
请到 [minikube 镜像](https://{{ site.hostname }}/github-release/kubernetes/minikube/LatestRelease/) 下载。
|
||||
|
|
|
|||
|
|
@ -13,6 +13,6 @@ Lineage OS 是全球最大的 Android 发行版之一,前身是 Cyanogenmod。
|
|||
|
||||
正常情况下,Lineage会根据你的地址来定向请求到最近的镜像站,因此通常情况下不需要手动选择镜像站进行下载,直接前往官方的下载网站下载即可。
|
||||
|
||||
但是如果你是校内的同学,或者因为其他原因希望一定从tuna下载Lineage的rom,可以直接访问 <https://mirrors.tuna.tsinghua.edu.cn/lineage-rom/full/> 选择设备代码及时间进行下载,或者在镜像站的主页右边或下方找到"获取下载链接",在 操作系统 -> LineageOS 下找到最新的 rom 进行下载。
|
||||
但是如果你是校内的同学,或者因为其他原因希望一定从tuna下载Lineage的rom,可以直接访问 <https://{{ site.hostname }}/lineage-rom/full/> 选择设备代码及时间进行下载,或者在镜像站的主页右边或下方找到"获取下载链接",在 操作系统 -> LineageOS 下找到最新的 rom 进行下载。
|
||||
|
||||
zip文件的使用方式请参考lineage的官方文档或自行Google。
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ permalink: /help/lineageOS/
|
|||
|
||||
## lineageOS 源代码镜像使用帮助
|
||||
|
||||
**注意: 本镜像是 lineageOS 源代码的镜像,如果是希望下载lineage的rom,请访问 <https://mirrors.tuna.tsinghua.edu.cn/help/lineage-rom/>。**
|
||||
**注意: 本镜像是 lineageOS 源代码的镜像,如果是希望下载lineage的rom,请访问 <https://{{ site.hostname }}/help/lineage-rom/>。**
|
||||
|
||||
### 过程摘录
|
||||
|
||||
|
|
@ -20,7 +20,7 @@ curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
|
|||
chmod a+x ~/bin/repo
|
||||
```
|
||||
|
||||
或者使用tuna的[git-repo镜像](https://mirrors.tuna.tsinghua.edu.cn/help/git-repo/)
|
||||
或者使用tuna的[git-repo镜像](https://{{ site.hostname }}/help/git-repo/)
|
||||
|
||||
建立工作目录:
|
||||
|
||||
|
|
@ -32,7 +32,7 @@ cd WORKING_DIRECTORY
|
|||
初始化仓库:
|
||||
|
||||
```
|
||||
repo init -u https://mirrors.tuna.tsinghua.edu.cn/git/lineageOS/LineageOS/android.git -b cm-14.1
|
||||
repo init -u https://{{ site.hostname }}/git/lineageOS/LineageOS/android.git -b cm-14.1
|
||||
```
|
||||
|
||||
(如果已经有从github同步的lineageOS源代码,可以从这里直接开始)
|
||||
|
|
@ -53,7 +53,7 @@ repo init -u https://mirrors.tuna.tsinghua.edu.cn/git/lineageOS/LineageOS/androi
|
|||
fetch="https://github.com/" />
|
||||
|
||||
<remote name="lineage"
|
||||
fetch="https://mirrors.tuna.tsinghua.edu.cn/git/lineageOS/"
|
||||
fetch="https://{{ site.hostname }}/git/lineageOS/"
|
||||
review="review.lineageos.org" />
|
||||
```
|
||||
|
||||
|
|
@ -68,7 +68,7 @@ repo init -u https://mirrors.tuna.tsinghua.edu.cn/git/lineageOS/LineageOS/androi
|
|||
|
||||
```xml
|
||||
<remote name="aosp"
|
||||
fetch="https://aosp.tuna.tsinghua.edu.cn"
|
||||
fetch="https://{{ site.aosp }}"
|
||||
```
|
||||
|
||||
将
|
||||
|
|
|
|||
|
|
@ -9,19 +9,19 @@ mirrorid: linux-firmware.git
|
|||
如需克隆 Linux 固件仓库,使用
|
||||
|
||||
```
|
||||
git clone https://mirrors.tuna.tsinghua.edu.cn/git/linux-firmware.git
|
||||
git clone https://{{ site.hostname }}/git/linux-firmware.git
|
||||
```
|
||||
|
||||
若要将 tuna mirror 加入已有仓库,可在已有仓库中运行
|
||||
|
||||
```
|
||||
git remote add tuna https://mirrors.tuna.tsinghua.edu.cn/git/linux-firmware.git
|
||||
git remote add tuna https://{{ site.hostname }}/git/linux-firmware.git
|
||||
```
|
||||
|
||||
或运行
|
||||
|
||||
```
|
||||
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/linux-firmware.git
|
||||
git remote set-url origin https://{{ site.hostname }}/git/linux-firmware.git
|
||||
```
|
||||
|
||||
将默认上游设置为 TUNA 镜像。
|
||||
|
|
|
|||
|
|
@ -9,19 +9,19 @@ mirrorid: linux-next.git
|
|||
如需克隆 linux 代码,使用
|
||||
|
||||
```
|
||||
git clone https://mirrors.tuna.tsinghua.edu.cn/git/linux-next.git
|
||||
git clone https://{{ site.hostname }}/git/linux-next.git
|
||||
```
|
||||
|
||||
若要将 tuna mirror 加入已有代码库,可在已有仓库中运行
|
||||
|
||||
```
|
||||
git remote add tuna https://mirrors.tuna.tsinghua.edu.cn/git/linux-next.git
|
||||
git remote add tuna https://{{ site.hostname }}/git/linux-next.git
|
||||
```
|
||||
|
||||
或运行
|
||||
|
||||
```
|
||||
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/linux-next.git
|
||||
git remote set-url origin https://{{ site.hostname }}/git/linux-next.git
|
||||
```
|
||||
|
||||
将默认上游设置为 TUNA 镜像。
|
||||
|
|
|
|||
|
|
@ -9,19 +9,19 @@ mirrorid: linux-stable.git
|
|||
如需克隆 linux 代码,使用
|
||||
|
||||
```
|
||||
git clone https://mirrors.tuna.tsinghua.edu.cn/git/linux-stable.git
|
||||
git clone https://{{ site.hostname }}/git/linux-stable.git
|
||||
```
|
||||
|
||||
若要将 tuna mirror 加入已有代码库,可在已有仓库中运行
|
||||
|
||||
```
|
||||
git remote add tuna https://mirrors.tuna.tsinghua.edu.cn/git/linux-stable.git
|
||||
git remote add tuna https://{{ site.hostname }}/git/linux-stable.git
|
||||
```
|
||||
|
||||
或运行
|
||||
|
||||
```
|
||||
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/linux-stable.git
|
||||
git remote set-url origin https://{{ site.hostname }}/git/linux-stable.git
|
||||
```
|
||||
|
||||
将默认上游设置为 TUNA 镜像
|
||||
|
|
|
|||
|
|
@ -9,19 +9,19 @@ mirrorid: linux.git
|
|||
如需克隆主线 linux 代码,使用
|
||||
|
||||
```
|
||||
git clone https://mirrors.tuna.tsinghua.edu.cn/git/linux.git
|
||||
git clone https://{{ site.hostname }}/git/linux.git
|
||||
```
|
||||
|
||||
若要将 tuna mirror 加入已有代码库,可在已有仓库中运行
|
||||
|
||||
```
|
||||
git remote add tuna https://mirrors.tuna.tsinghua.edu.cn/git/linux.git
|
||||
git remote add tuna https://{{ site.hostname }}/git/linux.git
|
||||
```
|
||||
|
||||
或运行
|
||||
|
||||
```
|
||||
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/linux.git
|
||||
git remote set-url origin https://{{ site.hostname }}/git/linux.git
|
||||
```
|
||||
|
||||
将默认上游设置为 TUNA 镜像
|
||||
|
|
@ -31,7 +31,7 @@ git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/linux.git
|
|||
以树莓派为例,具体操作为
|
||||
|
||||
```
|
||||
git clone https://mirrors.tuna.tsinghua.edu.cn/git/linux.git
|
||||
git clone https://{{ site.hostname }}/git/linux.git
|
||||
git remote add rasp https://github.com/raspberrypi/linux.git
|
||||
git fetch rasp
|
||||
```
|
||||
|
|
|
|||
|
|
@ -6,15 +6,15 @@ mirrorid: linuxbrew-bottles
|
|||
|
||||
## Linuxbrew-bottles 镜像使用帮助
|
||||
|
||||
**注:该镜像是 Linuxbrew 二进制预编译包的镜像。本镜像站同时提供 Linuxbrew 的 formula 索引的镜像(即 `brew update` 时所更新内容),请参考 [Linuxbrew 镜像使用帮助](https://mirrors.tuna.tsinghua.edu.cn/help/homebrew/)。**
|
||||
**注:该镜像是 Linuxbrew 二进制预编译包的镜像。本镜像站同时提供 Linuxbrew 的 formula 索引的镜像(即 `brew update` 时所更新内容),请参考 [Linuxbrew 镜像使用帮助](https://{{ site.hostname }}/help/homebrew/)。**
|
||||
|
||||
### 临时替换
|
||||
```bash
|
||||
export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.tuna.tsinghua.edu.cn/linuxbrew-bottles
|
||||
export HOMEBREW_BOTTLE_DOMAIN=https://{{ site.hostname }}/linuxbrew-bottles
|
||||
```
|
||||
|
||||
### 长期替换
|
||||
```bash
|
||||
echo 'export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.tuna.tsinghua.edu.cn/linuxbrew-bottles' >> ~/.bash_profile
|
||||
echo 'export HOMEBREW_BOTTLE_DOMAIN=https://{{ site.hostname }}/linuxbrew-bottles' >> ~/.bash_profile
|
||||
source ~/.bash_profile
|
||||
```
|
||||
|
|
|
|||
|
|
@ -9,10 +9,10 @@ mirrorid: lxc-images
|
|||
LXC 1.0 以上版本增加了 `download` 模版,支持下载定义好的系统镜像。
|
||||
|
||||
欲使用 TUNA 镜像进行下载加速,可以在 `lxc-create -t download` 的选项部分,
|
||||
增加 `--server mirrors.tuna.tsinghua.edu.cn/lxc-images` 即可,例如:
|
||||
增加 `--server {{ site.hostname }}/lxc-images` 即可,例如:
|
||||
|
||||
```
|
||||
# lxc-create -t download -n my-container -- --server mirrors.tuna.tsinghua.edu.cn/lxc-images
|
||||
# lxc-create -t download -n my-container -- --server {{ site.hostname }}/lxc-images
|
||||
```
|
||||
|
||||
**LXD/LXC 2.0使用镜像加速的方法**:
|
||||
|
|
@ -20,6 +20,6 @@ LXC 1.0 以上版本增加了 `download` 模版,支持下载定义好的系统
|
|||
创建一个remote链接,指向镜像站即可,或替换掉默认的images链接。
|
||||
|
||||
```
|
||||
# lxc remote add tuna-images https://mirrors.tuna.tsinghua.edu.cn/lxc-images/ --protocol=simplestreams --public
|
||||
# lxc remote add tuna-images https://{{ site.hostname }}/lxc-images/ --protocol=simplestreams --public
|
||||
# lxc image list tuna-images:
|
||||
```
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ https://apt.mariadb.org/mariadb/repo
|
|||
换为
|
||||
|
||||
```
|
||||
https://mirrors.tuna.tsinghua.edu.cn/mariadb/repo
|
||||
https://{{ site.hostname }}/mariadb/repo
|
||||
```
|
||||
|
||||
### RHEL/CentOS 等基于 yum 的系统
|
||||
|
|
@ -34,5 +34,5 @@ http://yum.mariadb.org
|
|||
换为
|
||||
|
||||
```
|
||||
https://mirrors.tuna.tsinghua.edu.cn/mariadb/yum
|
||||
```
|
||||
https://{{ site.hostname }}/mariadb/yum
|
||||
```
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv EA312927
|
|||
|
||||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://mirrors.tuna.tsinghua.edu.cn/mongodb/apt/{{os_name}} {{release_name}}/mongodb-org/stable {{repo-name}}
|
||||
deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://{{ site.hostname }}/mongodb/apt/{{os_name}} {{release_name}}/mongodb-org/stable {{repo-name}}
|
||||
</script>
|
||||
{%endraw%}
|
||||
|
||||
|
|
@ -57,7 +57,7 @@ sudo apt-get install -y mongodb-org
|
|||
```
|
||||
[mongodb-org]
|
||||
name=MongoDB Repository
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/mongodb/yum/el$releasever/
|
||||
baseurl=https://{{ site.hostname }}/mongodb/yum/el$releasever/
|
||||
gpgcheck=0
|
||||
enabled=1
|
||||
```
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ MSYS2 镜像使用帮助
|
|||
安装
|
||||
--------------
|
||||
|
||||
请访问该镜像目录下的 `distrib/` 目录([x86_64](https://mirrors.tuna.tsinghua.edu.cn/msys2/distrib/x86_64) 、[i686](https://mirrors.tuna.tsinghua.edu.cn/msys2/distrib/i686/)),找到名为 `msys2-<架构>-<日期>.exe` 的文件(如 `msys2-x86_64-20141113.exe`),下载安装即可。
|
||||
请访问该镜像目录下的 `distrib/` 目录([x86_64](https://{{ site.hostname }}/msys2/distrib/x86_64) 、[i686](https://{{ site.hostname }}/msys2/distrib/i686/)),找到名为 `msys2-<架构>-<日期>.exe` 的文件(如 `msys2-x86_64-20141113.exe`),下载安装即可。
|
||||
|
||||
pacman 的配置
|
||||
-------------
|
||||
|
|
@ -24,19 +24,19 @@ pacman 的配置
|
|||
编辑 `/etc/pacman.d/mirrorlist.mingw32` ,在文件开头添加:
|
||||
|
||||
```bash
|
||||
Server = https://mirrors.tuna.tsinghua.edu.cn/msys2/mingw/i686
|
||||
Server = https://{{ site.hostname }}/msys2/mingw/i686
|
||||
```
|
||||
|
||||
编辑 `/etc/pacman.d/mirrorlist.mingw64` ,在文件开头添加:
|
||||
|
||||
```bash
|
||||
Server = https://mirrors.tuna.tsinghua.edu.cn/msys2/mingw/x86_64
|
||||
Server = https://{{ site.hostname }}/msys2/mingw/x86_64
|
||||
```
|
||||
|
||||
编辑 `/etc/pacman.d/mirrorlist.msys` ,在文件开头添加:
|
||||
|
||||
```bash
|
||||
Server = https://mirrors.tuna.tsinghua.edu.cn/msys2/msys/$arch
|
||||
Server = https://{{ site.hostname }}/msys2/msys/$arch
|
||||
```
|
||||
|
||||
然后执行 `pacman -Sy` 刷新软件包数据即可。
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ mirrorid: mysql
|
|||
|
||||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/mysql/apt/{{os_name}} {{release_name}} mysql-5.6 mysql-5.7 mysql-8.0 mysql-tools
|
||||
deb https://{{ site.hostname }}/mysql/apt/{{os_name}} {{release_name}} mysql-5.6 mysql-5.7 mysql-8.0 mysql-tools
|
||||
</script>
|
||||
{%endraw%}
|
||||
|
||||
|
|
@ -68,35 +68,35 @@ deb https://mirrors.tuna.tsinghua.edu.cn/mysql/apt/{{os_name}} {{release_name}}
|
|||
<script id="yum-template" type="x-tmpl-markup">
|
||||
[mysql-connectors-community]
|
||||
name=MySQL Connectors Community
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/mysql/yum/mysql-connectors-community-{{release_name}}/
|
||||
baseurl=https://{{ site.hostname }}/mysql/yum/mysql-connectors-community-{{release_name}}/
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
|
||||
|
||||
[mysql-tools-community]
|
||||
name=MySQL Tools Community
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/mysql/yum/mysql-tools-community-{{release_name}}/
|
||||
baseurl=https://{{ site.hostname }}/mysql/yum/mysql-tools-community-{{release_name}}/
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
|
||||
|
||||
[mysql56-community]
|
||||
name=MySQL 5.6 Community Server
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/mysql/yum/mysql56-community-{{release_name}}/
|
||||
baseurl=https://{{ site.hostname }}/mysql/yum/mysql56-community-{{release_name}}/
|
||||
enabled=0
|
||||
gpgcheck=1
|
||||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
|
||||
|
||||
[mysql57-community]
|
||||
name=MySQL 5.7 Community Server
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/mysql/yum/mysql57-community-{{release_name}}/
|
||||
baseurl=https://{{ site.hostname }}/mysql/yum/mysql57-community-{{release_name}}/
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
|
||||
|
||||
[mysql80-community]
|
||||
name=MySQL 8.0 Community Server
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/mysql/yum/mysql80-community-{{release_name}}/
|
||||
baseurl=https://{{ site.hostname }}/mysql/yum/mysql80-community-{{release_name}}/
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ Nodejs Release 为各平台提供预编译的 nodejs 和 npm 等二进制文件
|
|||
```
|
||||
# 设定环境变量
|
||||
|
||||
export NODE_MIRROR=https://mirrors.tuna.tsinghua.edu.cn/nodejs-release/
|
||||
export NODE_MIRROR=https://{{ site.hostname }}/nodejs-release/
|
||||
|
||||
# 然后正常使用 n 即可
|
||||
|
||||
|
|
|
|||
|
|
@ -21,6 +21,6 @@ curl -sL https://deb.nodesource.com/setup_10.x | sudo bash -
|
|||
|
||||
编辑 `/etc/apt/sources.list.d/nodesource.list`,把
|
||||
`https://deb.nodesource.com/node/` 替换为
|
||||
`https://mirrors.tuna.tsinghua.edu.cn/nodesource/deb/` 即可。
|
||||
`https://{{ site.hostname }}/nodesource/deb/` 即可。
|
||||
|
||||
如果是 `https://deb.nodesource.com/node_10.x/` ,则改为 `https://mirrors.tuna.tsinghua.edu.cn/nodesource/deb_10.x/` 。
|
||||
如果是 `https://deb.nodesource.com/node_10.x/` ,则改为 `https://{{ site.hostname }}/nodesource/deb_10.x/` 。
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ mirrorid: packagist
|
|||
执行以下命令即可将 Composer 默认仓库设置为本站:
|
||||
|
||||
```
|
||||
composer config -g repos.packagist composer https://mirrors.tuna.tsinghua.edu.cn/packagist/index
|
||||
composer config -g repos.packagist composer https://{{ site.hostname }}/packagist/index
|
||||
```
|
||||
|
||||
该镜像只包含包索引,不含包的内容,主要目的是加快 composer 读取软件包索引的速度。
|
||||
|
|
|
|||
|
|
@ -28,8 +28,8 @@ mirrorid: proxmox
|
|||
|
||||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/proxmox/{{os_name}} {{release_name}} pve-no-subscription
|
||||
deb https://{{ site.hostname }}/proxmox/{{os_name}} {{release_name}} pve-no-subscription
|
||||
</script>
|
||||
{%endraw%}
|
||||
|
||||
ISO安装文件下载:[https://mirrors.tuna.tsinghua.edu.cn/proxmox/iso/](https://mirrors.tuna.tsinghua.edu.cn/proxmox/iso/)
|
||||
ISO安装文件下载:[https://{{ site.hostname }}/proxmox/iso/](https://{{ site.hostname }}/proxmox/iso/)
|
||||
|
|
|
|||
|
|
@ -22,8 +22,8 @@ PyBOMBS 镜像使用帮助
|
|||
```bash
|
||||
sudo pip install pybombs
|
||||
rm -rf ~/.pybombs
|
||||
pybombs recipes add gr-recipes git+https://mirrors.tuna.tsinghua.edu.cn/pybombs/recipes/gr-recipes.git
|
||||
pybombs recipes add gr-etcetera git+https://mirrors.tuna.tsinghua.edu.cn/pybombs/recipes/gr-etcetera.git
|
||||
pybombs recipes add gr-recipes git+https://{{ site.hostname }}/pybombs/recipes/gr-recipes.git
|
||||
pybombs recipes add gr-etcetera git+https://{{ site.hostname }}/pybombs/recipes/gr-etcetera.git
|
||||
mkdir gnuradio-prefix
|
||||
cd gnuradio-prefix
|
||||
pybombs prefix init
|
||||
|
|
@ -41,8 +41,8 @@ pybombs install rtl-sdr hackrf bladeRF gr-osmosdr gr-bluetooth gr-ieee-80211
|
|||
```bash
|
||||
pybombs recipes remove gr-recipes
|
||||
pybombs recipes remove gr-etcetera
|
||||
pybombs recipes add gr-recipes git+https://mirrors.tuna.tsinghua.edu.cn/pybombs/recipes/gr-recipes.git
|
||||
pybombs recipes add gr-etcetera git+https://mirrors.tuna.tsinghua.edu.cn/pybombs/recipes/gr-etcetera.git
|
||||
pybombs recipes add gr-recipes git+https://{{ site.hostname }}/pybombs/recipes/gr-recipes.git
|
||||
pybombs recipes add gr-etcetera git+https://{{ site.hostname }}/pybombs/recipes/gr-etcetera.git
|
||||
```
|
||||
|
||||
- 本镜像使用 <http://github.com/scateu/pybombs-mirror> 脚本进行构建。
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ pypi 镜像每 5 分钟同步一次。
|
|||
### 临时使用
|
||||
|
||||
```
|
||||
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple some-package
|
||||
pip install -i https://{{ site.pypi }}/simple some-package
|
||||
```
|
||||
|
||||
注意,`simple` 不能少, 是 `https` 而不是 `http`
|
||||
|
|
@ -22,11 +22,11 @@ pip install -i https://pypi.tuna.tsinghua.edu.cn/simple some-package
|
|||
|
||||
```
|
||||
pip install pip -U
|
||||
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
|
||||
pip config set global.index-url https://{{ site.pypi }}/simple
|
||||
```
|
||||
|
||||
如果您到 pip 默认源的网络连接较差,临时使用本镜像站来升级 pip:
|
||||
|
||||
```
|
||||
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple pip -U
|
||||
pip install -i https://{{ site.pypi }}/simple pip -U
|
||||
```
|
||||
|
|
|
|||
|
|
@ -9,19 +9,19 @@ mirrorid: qemu.git
|
|||
如需克隆 QEMU 代码,使用
|
||||
|
||||
```
|
||||
git clone https://mirrors.tuna.tsinghua.edu.cn/git/qemu.git
|
||||
git clone https://{{ site.hostname }}/git/qemu.git
|
||||
```
|
||||
|
||||
若要将 tuna mirror 加入已有代码库,可在已有仓库中运行
|
||||
|
||||
```
|
||||
git remote add tuna https://mirrors.tuna.tsinghua.edu.cn/git/qemu.git
|
||||
git remote add tuna https://{{ site.hostname }}/git/qemu.git
|
||||
```
|
||||
|
||||
或运行
|
||||
|
||||
```
|
||||
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/qemu.git
|
||||
git remote set-url origin https://{{ site.hostname }}/git/qemu.git
|
||||
```
|
||||
|
||||
将默认上游设置为 TUNA 镜像
|
||||
|
|
|
|||
|
|
@ -66,11 +66,11 @@ testing 版本的 7.0/wheezy,所以 Raspbian 不倾向于使用 stable/testing
|
|||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
# 编辑 `/etc/apt/sources.list` 文件,删除原文件所有内容,用以下内容取代:
|
||||
deb http://mirrors.tuna.tsinghua.edu.cn/raspbian/raspbian/ {{release_name}} main non-free contrib
|
||||
deb-src http://mirrors.tuna.tsinghua.edu.cn/raspbian/raspbian/ {{release_name}} main non-free contrib
|
||||
deb http://{{ site.hostname }}/raspbian/raspbian/ {{release_name}} main non-free contrib
|
||||
deb-src http://{{ site.hostname }}/raspbian/raspbian/ {{release_name}} main non-free contrib
|
||||
|
||||
# 编辑 `/etc/apt/sources.list.d/raspi.list` 文件,删除原文件所有内容,用以下内容取代:
|
||||
deb http://mirrors.tuna.tsinghua.edu.cn/raspberrypi/ {{release_name}} main ui
|
||||
deb http://{{ site.hostname }}/raspberrypi/ {{release_name}} main ui
|
||||
</script>
|
||||
{% endraw %}
|
||||
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ mirrorid: repo-ck
|
|||
|
||||
```
|
||||
[repo-ck]
|
||||
Server = https://mirrors.tuna.tsinghua.edu.cn/repo-ck/$arch
|
||||
Server = https://{{ site.hostname }}/repo-ck/$arch
|
||||
```
|
||||
|
||||
再增加 GPG 信任:
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ mirrorid: ros
|
|||
|
||||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/ros/ubuntu/ {{release_name}} main
|
||||
deb https://{{ site.hostname }}/ros/ubuntu/ {{release_name}} main
|
||||
</script>
|
||||
{%endraw%}
|
||||
|
||||
|
|
@ -40,4 +40,4 @@ deb https://mirrors.tuna.tsinghua.edu.cn/ros/ubuntu/ {{release_name}} main
|
|||
```
|
||||
sudo apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
|
||||
sudo apt update
|
||||
```
|
||||
```
|
||||
|
|
|
|||
|
|
@ -17,19 +17,19 @@ sudo yum install --nogpgcheck http://download1.rpmfusion.org/free/fedora/rpmfusi
|
|||
或者如下直接用 TUNA 镜像中的 rpm 包:
|
||||
|
||||
```
|
||||
sudo yum install --nogpgcheck https://mirrors.tuna.tsinghua.edu.cn/rpmfusion/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm https://mirrors.tuna.tsinghua.edu.cn/rpmfusion/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
|
||||
sudo yum install --nogpgcheck https://{{ site.hostname }}/rpmfusion/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm https://{{ site.hostname }}/rpmfusion/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
|
||||
```
|
||||
|
||||
注意:没有将当前用户设为管理员的用户,需要将 `sudo CMD` 替换为 `su -c 'CMD'`,并输入 root 密码。
|
||||
|
||||
### 修改链接指向 TUNA 镜像
|
||||
|
||||
安装成功后,修改 `/etc/yum.repos.d/` 目录下以 `rpmfusion` 开头,以 `.repo` 结尾的文件。具体而言,需要将文件中的 `baseurl=` 开头的行等号后面链接中的 `http://download1.rpmfusion.org/` 替换为 `https://mirrors.tuna.tsinghua.edu.cn/rpmfusion/`,替换后的文件类似如下:
|
||||
安装成功后,修改 `/etc/yum.repos.d/` 目录下以 `rpmfusion` 开头,以 `.repo` 结尾的文件。具体而言,需要将文件中的 `baseurl=` 开头的行等号后面链接中的 `http://download1.rpmfusion.org/` 替换为 `https://{{ site.hostname }}/rpmfusion/`,替换后的文件类似如下:
|
||||
|
||||
```
|
||||
[rpmfusion-free]
|
||||
name=RPM Fusion for Fedora $releasever - Free
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/rpmfusion/free/fedora/releases/$releasever/Everything/$basearch/os/
|
||||
baseurl=https://{{ site.hostname }}/rpmfusion/free/fedora/releases/$releasever/Everything/$basearch/os/
|
||||
mirrorlist=http://mirrors.rpmfusion.org/mirrorlist?repo=free-fedora-$releasever&arch=$basearch
|
||||
enabled=1
|
||||
metadata_expire=7d
|
||||
|
|
@ -46,7 +46,7 @@ gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rpmfusion-free-fedora-$releasever-$ba
|
|||
|
||||
[rpmfusion-free-source]
|
||||
name=RPM Fusion for Fedora $releasever - Free - Source
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/rpmfusion/free/fedora/releases/$releasever/Everything/source/SRPMS/
|
||||
baseurl=https://{{ site.hostname }}/rpmfusion/free/fedora/releases/$releasever/Everything/source/SRPMS/
|
||||
mirrorlist=http://mirrors.rpmfusion.org/mirrorlist?repo=free-fedora-source-$releasever&arch=$basearch
|
||||
enabled=0
|
||||
metadata_expire=7d
|
||||
|
|
|
|||
|
|
@ -6,16 +6,16 @@ mirrorid: stackage
|
|||
|
||||
## stackage 镜像使用帮助
|
||||
|
||||
本镜像推荐与 TUNA 的 [Hackage 镜像](https://mirrors.tuna.tsinghua.edu.cn/help/hackage/)配合使用。
|
||||
本镜像推荐与 TUNA 的 [Hackage 镜像](https://{{ site.hostname }}/help/hackage/)配合使用。
|
||||
|
||||
### stack >= v2.1.1
|
||||
|
||||
修改`~/.stack/config.yaml`(在 Windows 下是 `%APPDATA%\stack\config.yaml`), 加上:
|
||||
|
||||
```yaml
|
||||
setup-info: "http://mirrors.tuna.tsinghua.edu.cn/stackage/stack-setup.yaml"
|
||||
setup-info: "http://{{ site.hostname }}/stackage/stack-setup.yaml"
|
||||
urls:
|
||||
latest-snapshot: http://mirrors.tuna.tsinghua.edu.cn/stackage/snapshots.json
|
||||
latest-snapshot: http://{{ site.hostname }}/stackage/snapshots.json
|
||||
```
|
||||
|
||||
### stack < v2.1.1
|
||||
|
|
@ -23,9 +23,9 @@ urls:
|
|||
修改`~/.stack/config.yaml`(在 Windows 下是 `%APPDATA%\stack\config.yaml`), 加上:
|
||||
|
||||
```yaml
|
||||
setup-info: "http://mirrors.tuna.tsinghua.edu.cn/stackage/stack-setup.yaml"
|
||||
setup-info: "http://{{ site.hostname }}/stackage/stack-setup.yaml"
|
||||
urls:
|
||||
latest-snapshot: http://mirrors.tuna.tsinghua.edu.cn/stackage/snapshots.json
|
||||
lts-build-plans: http://mirrors.tuna.tsinghua.edu.cn/stackage/lts-haskell/
|
||||
nightly-build-plans: http://mirrors.tuna.tsinghua.edu.cn/stackage/stackage-nightly/
|
||||
latest-snapshot: http://{{ site.hostname }}/stackage/snapshots.json
|
||||
lts-build-plans: http://{{ site.hostname }}/stackage/lts-haskell/
|
||||
nightly-build-plans: http://{{ site.hostname }}/stackage/stackage-nightly/
|
||||
```
|
||||
|
|
|
|||
|
|
@ -33,9 +33,9 @@ Termux 是运行在 Android 上的 terminal。不需要root,运行于内部存
|
|||
使用如下命令自动替换官方源为 TUNA 镜像源
|
||||
|
||||
``` bash
|
||||
sed -i 's@^\(deb.*stable main\)$@#\1\ndeb https://mirrors.tuna.tsinghua.edu.cn/termux/termux-packages-24 stable main@' $PREFIX/etc/apt/sources.list
|
||||
sed -i 's@^\(deb.*games stable\)$@#\1\ndeb https://mirrors.tuna.tsinghua.edu.cn/termux/game-packages-24 games stable@' $PREFIX/etc/apt/sources.list.d/game.list
|
||||
sed -i 's@^\(deb.*science stable\)$@#\1\ndeb https://mirrors.tuna.tsinghua.edu.cn/termux/science-packages-24 science stable@' $PREFIX/etc/apt/sources.list.d/science.list
|
||||
sed -i 's@^\(deb.*stable main\)$@#\1\ndeb https://{{ site.hostname }}/termux/termux-packages-24 stable main@' $PREFIX/etc/apt/sources.list
|
||||
sed -i 's@^\(deb.*games stable\)$@#\1\ndeb https://{{ site.hostname }}/termux/game-packages-24 games stable@' $PREFIX/etc/apt/sources.list.d/game.list
|
||||
sed -i 's@^\(deb.*science stable\)$@#\1\ndeb https://{{ site.hostname }}/termux/science-packages-24 science stable@' $PREFIX/etc/apt/sources.list.d/science.list
|
||||
apt update && apt upgrade
|
||||
```
|
||||
|
||||
|
|
@ -45,21 +45,21 @@ apt update && apt upgrade
|
|||
|
||||
```
|
||||
# The termux repository mirror from TUNA:
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/termux/termux-packages-24 stable main
|
||||
deb https://{{ site.hostname }}/termux/termux-packages-24 stable main
|
||||
```
|
||||
|
||||
编辑 `$PREFIX/etc/apt/sources.list.d/science.list` 修改为如下内容
|
||||
|
||||
```
|
||||
# The termux repository mirror from TUNA:
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/termux/science-packages-24 science stable
|
||||
deb https://{{ site.hostname }}/termux/science-packages-24 science stable
|
||||
```
|
||||
|
||||
编辑 `$PREFIX/etc/apt/sources.list.d/game.list` 修改为如下内容
|
||||
|
||||
```
|
||||
# The termux repository mirror from TUNA:
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/termux/game-packages-24 games stable
|
||||
deb https://{{ site.hostname }}/termux/game-packages-24 games stable
|
||||
```
|
||||
请使用内置或安装在 Termux 里的文本编辑器,例如 `vi` / `vim` / `nano` 等,**不要使用 RE 管理器等其他具有 ROOT 权限的外部 APP** 来修改 Termux 的文件
|
||||
|
||||
|
|
@ -67,9 +67,9 @@ deb https://mirrors.tuna.tsinghua.edu.cn/termux/game-packages-24 games stable
|
|||
|
||||
镜像站还提供了如下社区维护的源,如需使用请自行添加:
|
||||
|
||||
- https://mirrors.tuna.tsinghua.edu.cn/termux/x11-packages
|
||||
- https://mirrors.tuna.tsinghua.edu.cn/termux/unstable-packages
|
||||
- https://mirrors.tuna.tsinghua.edu.cn/termux/termux-root-packages-24
|
||||
- https://{{ site.hostname }}/termux/x11-packages
|
||||
- https://{{ site.hostname }}/termux/unstable-packages
|
||||
- https://{{ site.hostname }}/termux/termux-root-packages-24
|
||||
|
||||
### 警告
|
||||
|
||||
|
|
|
|||
|
|
@ -35,18 +35,18 @@ TUNA 的软件源镜像。
|
|||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ {{release_name}} main restricted universe multiverse
|
||||
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ {{release_name}} main restricted universe multiverse
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ {{release_name}}-updates main restricted universe multiverse
|
||||
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ {{release_name}}-updates main restricted universe multiverse
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ {{release_name}}-backports main restricted universe multiverse
|
||||
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ {{release_name}}-backports main restricted universe multiverse
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ {{release_name}}-security main restricted universe multiverse
|
||||
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ {{release_name}}-security main restricted universe multiverse
|
||||
deb https://{{ site.hostname }}/ubuntu/ {{release_name}} main restricted universe multiverse
|
||||
# deb-src https://{{ site.hostname }}/ubuntu/ {{release_name}} main restricted universe multiverse
|
||||
deb https://{{ site.hostname }}/ubuntu/ {{release_name}}-updates main restricted universe multiverse
|
||||
# deb-src https://{{ site.hostname }}/ubuntu/ {{release_name}}-updates main restricted universe multiverse
|
||||
deb https://{{ site.hostname }}/ubuntu/ {{release_name}}-backports main restricted universe multiverse
|
||||
# deb-src https://{{ site.hostname }}/ubuntu/ {{release_name}}-backports main restricted universe multiverse
|
||||
deb https://{{ site.hostname }}/ubuntu/ {{release_name}}-security main restricted universe multiverse
|
||||
# deb-src https://{{ site.hostname }}/ubuntu/ {{release_name}}-security main restricted universe multiverse
|
||||
|
||||
# 预发布软件源,不建议启用
|
||||
# deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ {{release_name}}-proposed main restricted universe multiverse
|
||||
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ {{release_name}}-proposed main restricted universe multiverse
|
||||
# deb https://{{ site.hostname }}/ubuntu/ {{release_name}}-proposed main restricted universe multiverse
|
||||
# deb-src https://{{ site.hostname }}/ubuntu/ {{release_name}}-proposed main restricted universe multiverse
|
||||
</script>
|
||||
{% endraw %}
|
||||
|
||||
|
|
|
|||
|
|
@ -11,9 +11,9 @@ mirrorid: voidlinux
|
|||
```
|
||||
# mkdir -p /etc/xbps.d
|
||||
# cp /usr/share/xbps.d/*-repository-*.conf /etc/xbps.d/
|
||||
# sed -i 's|https://alpha.de.repo.voidlinux.org|https://mirrors.tuna.tsinghua.edu.cn/voidlinux|g' /etc/xbps.d/*-repository-*.conf
|
||||
# sed -i 's|https://alpha.de.repo.voidlinux.org|https://{{ site.hostname }}/voidlinux|g' /etc/xbps.d/*-repository-*.conf
|
||||
```
|
||||
|
||||
之后可用 `xbps-query -L` 检查是否正确替换。
|
||||
|
||||
参考[官方教程](https://docs.voidlinux.org/xbps/repositories/mirrors/changing.html)。
|
||||
参考[官方教程](https://docs.voidlinux.org/xbps/repositories/mirrors/changing.html)。
|
||||
|
|
|
|||
|
|
@ -13,5 +13,5 @@ Alpine Linux 是一个面向安全,轻量级的基于musl libc与busybox项目
|
|||
|
||||
在终端输入以下命令以替换TUNA镜像源:
|
||||
```
|
||||
sed -i 's/dl-cdn.alpinelinux.org/mirrors.tuna.tsinghua.edu.cn/g' /etc/apk/repositories
|
||||
sed -i 's/dl-cdn.alpinelinux.org/{{ site.hostname }}/g' /etc/apk/repositories
|
||||
```
|
||||
|
|
|
|||
|
|
@ -10,12 +10,12 @@ mirrorid: virtualbox
|
|||
|
||||
## Microsoft Windows
|
||||
|
||||
[点击下载 Windows 最新版](https://mirrors.tuna.tsinghua.edu.cn/virtualbox/virtualbox-Win-latest.exe)
|
||||
[点击下载 Windows 最新版](https://{{ site.hostname }}/virtualbox/virtualbox-Win-latest.exe)
|
||||
|
||||
|
||||
## Macintosh OS X
|
||||
|
||||
[点击下载 OS X 最新版](https://mirrors.tuna.tsinghua.edu.cn/virtualbox/virtualbox-osx-latest.dmg)
|
||||
[点击下载 OS X 最新版](https://{{ site.hostname }}/virtualbox/virtualbox-osx-latest.dmg)
|
||||
|
||||
# Linux
|
||||
|
||||
|
|
@ -76,7 +76,7 @@ wget -q https://www.virtualbox.org/download/oracle_vbox.asc -O- | sudo apt-key a
|
|||
|
||||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://mirrors.tuna.tsinghua.edu.cn/virtualbox/apt/ {{release_name}} contrib
|
||||
deb {{if os_name|equals>ubuntu}}https{{else}}http{{/if}}://{{ site.hostname }}/virtualbox/apt/ {{release_name}} contrib
|
||||
</script>
|
||||
{% endraw %}
|
||||
|
||||
|
|
@ -95,7 +95,7 @@ sudo apt-get install virtualbox-5.0
|
|||
```
|
||||
[virtualbox]
|
||||
name=Virtualbox Repository
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/virtualbox/rpm/el$releasever/
|
||||
baseurl=https://{{ site.hostname }}/virtualbox/rpm/el$releasever/
|
||||
gpgcheck=0
|
||||
enabled=1
|
||||
```
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ mirrorid: repoforge
|
|||
1. 运行 `cat /etc/redhat-release` 获取 EL 版本号(如 EL6, EL7 等)
|
||||
2. 向系统中添加 Repoforge 的 GPG 公钥:
|
||||
```
|
||||
rpm --import https://mirrors.tuna.tsinghua.edu.cn/repoforge/RPM-GPG-KEY.dag.txt
|
||||
rpm --import https://{{ site.hostname }}/repoforge/RPM-GPG-KEY.dag.txt
|
||||
```
|
||||
3. 运行下列命令:
|
||||
|
||||
|
|
@ -35,7 +35,7 @@ rpm --import https://mirrors.tuna.tsinghua.edu.cn/repoforge/RPM-GPG-KEY.dag.txt
|
|||
sudo cat > /etc/yum.repos.d/rpmforge.repo << EOF
|
||||
[rpmforge]
|
||||
name = RHEL $releasever - RPMforge.net - dag
|
||||
baseurl = https://mirrors.tuna.tsinghua.edu.cn/repoforge/redhat/{{release_name}}/en/$basearch/rpmforge
|
||||
baseurl = https://{{ site.hostname }}/repoforge/redhat/{{release_name}}/en/$basearch/rpmforge
|
||||
mirrorlist = http://mirrorlist.repoforge.org/{{release_name}}/mirrors-rpmforge
|
||||
enabled = 1
|
||||
protect = 0
|
||||
|
|
@ -44,7 +44,7 @@ gpgcheck = 1
|
|||
|
||||
[rpmforge-extras]
|
||||
name = RHEL $releasever - RPMforge.net - extras
|
||||
baseurl = https://mirrors.tuna.tsinghua.edu.cn/repoforge/redhat/{{release_name}}/en/$basearch/extras
|
||||
baseurl = https://{{ site.hostname }}/repoforge/redhat/{{release_name}}/en/$basearch/extras
|
||||
mirrorlist = http://mirrorlist.repoforge.org/{{release_name}}/mirrors-rpmforge-extras
|
||||
enabled = 0
|
||||
protect = 0
|
||||
|
|
@ -53,7 +53,7 @@ gpgcheck = 1
|
|||
|
||||
[rpmforge-testing]
|
||||
name = RHEL $releasever - RPMforge.net - testing
|
||||
baseurl = https://mirrors.tuna.tsinghua.edu.cn/repoforge/redhat/{{release_name}}/en/$basearch/testing
|
||||
baseurl = https://{{ site.hostname }}/repoforge/redhat/{{release_name}}/en/$basearch/testing
|
||||
mirrorlist = http://mirrorlist.repoforge.org/{{release_name}}/mirrors-rpmforge-testing
|
||||
enabled = 0
|
||||
protect = 0
|
||||
|
|
|
|||
|
|
@ -12,19 +12,19 @@ mirrorid: rubygems
|
|||
|
||||
```bash
|
||||
# 添加 TUNA 源并移除默认源
|
||||
gem sources --add https://mirrors.tuna.tsinghua.edu.cn/rubygems/ --remove https://rubygems.org/
|
||||
gem sources --add https://{{ site.hostname }}/rubygems/ --remove https://rubygems.org/
|
||||
# 列出已有源
|
||||
gem sources -l
|
||||
# 应该只有 TUNA 一个
|
||||
```
|
||||
|
||||
或者,编辑 `~/.gemrc`,将 `https://mirrors.tuna.tsinghua.edu.cn/rubygems/` 加到 `sources` 字段。
|
||||
或者,编辑 `~/.gemrc`,将 `https://{{ site.hostname }}/rubygems/` 加到 `sources` 字段。
|
||||
|
||||
## `bundler`
|
||||
|
||||
使用以下命令替换 bundler 默认源
|
||||
```bash
|
||||
bundle config mirror.https://rubygems.org https://mirrors.tuna.tsinghua.edu.cn/rubygems
|
||||
bundle config mirror.https://rubygems.org https://{{ site.hostname }}/rubygems
|
||||
```
|
||||
|
||||
官方文档: http://bundler.io/v1.16/man/bundle-config.1.html#MIRRORS-OF-GEM-SOURCES
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ Bioconductor 镜像源配置文件之一是 `.Rprofile` (linux 下位于 `~/.Rpr
|
|||
在文末添加如下语句:
|
||||
|
||||
```
|
||||
options(BioC_mirror="https://mirrors.tuna.tsinghua.edu.cn/bioconductor")
|
||||
options(BioC_mirror="https://{{ site.hostname }}/bioconductor")
|
||||
```
|
||||
|
||||
打开R即可使用该 Bioconductor 镜像源安装 Bioconductor 软件包。
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ CRAN 镜像使用帮助
|
|||
在文末添加如下语句:
|
||||
|
||||
```
|
||||
options("repos" = c(CRAN="https://mirrors.tuna.tsinghua.edu.cn/CRAN/"))
|
||||
options("repos" = c(CRAN="https://{{ site.hostname }}/CRAN/"))
|
||||
```
|
||||
|
||||
打开 R 即可使用该 CRAN 镜像源安装 R 软件包。
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ http://llvm.org/git/{llvm,clang,libcxx,lldb,clang-tools-extra,polly,zorg,compile
|
|||
使用方法:
|
||||
|
||||
```
|
||||
git clone https://mirrors.tuna.tsinghua.edu.cn/git/llvm/{reponame}.git
|
||||
git clone https://{{ site.hostname }}/git/llvm/{reponame}.git
|
||||
```
|
||||
|
||||
其中`{reponame}`为上述的仓库名称之一。请注意:由于仓库体积均较大,执行`git clone`可能需要较长时间,并且没有进度提示,请耐心等候。
|
||||
|
|
@ -23,13 +23,13 @@ git clone https://mirrors.tuna.tsinghua.edu.cn/git/llvm/{reponame}.git
|
|||
若要将 TUNA mirror 加入已有代码库,可在已有仓库中运行
|
||||
|
||||
```
|
||||
git remote add tuna https://mirrors.tuna.tsinghua.edu.cn/git/llvm/{reponame}.git
|
||||
git remote add tuna https://{{ site.hostname }}/git/llvm/{reponame}.git
|
||||
```
|
||||
|
||||
或运行
|
||||
|
||||
```
|
||||
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/llvm/{reponame}.git
|
||||
git remote set-url origin https://{{ site.hostname }}/git/llvm/{reponame}.git
|
||||
```
|
||||
|
||||
将默认上游设置为 TUNA 镜像
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ CTAN 镜像使用帮助
|
|||
在命令行中执行
|
||||
|
||||
```
|
||||
tlmgr option repository https://mirrors.tuna.tsinghua.edu.cn/CTAN/systems/texlive/tlnet
|
||||
tlmgr option repository https://{{ site.hostname }}/CTAN/systems/texlive/tlnet
|
||||
```
|
||||
|
||||
即可永久更改镜像源。
|
||||
|
|
@ -20,7 +20,7 @@ tlmgr option repository https://mirrors.tuna.tsinghua.edu.cn/CTAN/systems/texliv
|
|||
如果只需要临时切换,可以用如下命令:
|
||||
|
||||
```
|
||||
tlmgr update --all --repository https://mirrors.tuna.tsinghua.edu.cn/CTAN/systems/texlive/tlnet
|
||||
tlmgr update --all --repository https://{{ site.hostname }}/CTAN/systems/texlive/tlnet
|
||||
```
|
||||
|
||||
其中的 `update --all` 指令可根据需要修改。
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ mirrorid: openthos-src
|
|||
|
||||
# OpenTHOS 源代码镜像使用帮助
|
||||
|
||||
**注意: 本镜像是 OpenTHOS 源代码的镜像,如果是希望下载 OpenTHOS 的安装镜像,请访问 <https://mirrors.tuna.tsinghua.edu.cn/openthos/>。**
|
||||
**注意: 本镜像是 OpenTHOS 源代码的镜像,如果是希望下载 OpenTHOS 的安装镜像,请访问 <https://{{ site.hostname }}/openthos/>。**
|
||||
|
||||
OpenTHOS 是基于 Android x86 的一套具有自主知识产权的开源桌面操作系统。其源代码获取方式类似于 AOSP,
|
||||
但需要将上游地址指向 `https://mirrors.tuna.tsinghua.edu.cn/git/openthos-src/manifest`。
|
||||
但需要将上游地址指向 `https://{{ site.hostname }}/git/openthos-src/manifest`。
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ mirrorid: gentoo-portage
|
|||
在 `/etc/portage/make.conf` 中加入:
|
||||
|
||||
```
|
||||
GENTOO_MIRRORS="https://mirrors.tuna.tsinghua.edu.cn/gentoo"
|
||||
GENTOO_MIRRORS="https://{{ site.hostname }}/gentoo"
|
||||
```
|
||||
|
||||
执行 `emerge --sync` 或者 `eix-sync` 进行更新。
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ sudo apt-get install grafana
|
|||
|
||||
{% raw %}
|
||||
<script id="apt-template" type="x-tmpl-markup">
|
||||
deb https://mirrors.tuna.tsinghua.edu.cn/grafana/apt/ {{release_name}} main
|
||||
deb https://{{ site.hostname }}/grafana/apt/ {{release_name}} main
|
||||
</script>
|
||||
{%endraw%}
|
||||
|
||||
|
|
@ -83,7 +83,7 @@ sudo yum install grafana
|
|||
<script id="yum-template" type="x-tmpl-markup">
|
||||
[grafana]
|
||||
name=grafana
|
||||
baseurl=https://mirrors.tuna.tsinghua.edu.cn/grafana/yum/{{release_name}}
|
||||
baseurl=https://{{ site.hostname }}/grafana/yum/{{release_name}}
|
||||
repo_gpgcheck=0
|
||||
enabled=1
|
||||
gpgcheck=0
|
||||
|
|
|
|||
|
|
@ -15,26 +15,26 @@ TUNA 只会保留一段时间的 nightly,如果在安装时出现错误,请
|
|||
|
||||
```bash
|
||||
$ # for bash
|
||||
$ RUSTUP_DIST_SERVER=https://mirrors.tuna.tsinghua.edu.cn/rustup rustup install stable # for stable
|
||||
$ RUSTUP_DIST_SERVER=https://{{ site.hostname }}/rustup rustup install stable # for stable
|
||||
$ # for fish
|
||||
$ env RUSTUP_DIST_SERVER=https://mirrors.tuna.tsinghua.edu.cn/rustup rustup install stable # for stable
|
||||
$ env RUSTUP_DIST_SERVER=https://{{ site.hostname }}/rustup rustup install stable # for stable
|
||||
$ # for bash
|
||||
$ RUSTUP_DIST_SERVER=https://mirrors.tuna.tsinghua.edu.cn/rustup rustup install nightly # for nightly
|
||||
$ RUSTUP_DIST_SERVER=https://{{ site.hostname }}/rustup rustup install nightly # for nightly
|
||||
$ # for fish
|
||||
$ env RUSTUP_DIST_SERVER=https://mirrors.tuna.tsinghua.edu.cn/rustup rustup install nightly # for nightly
|
||||
$ env RUSTUP_DIST_SERVER=https://{{ site.hostname }}/rustup rustup install nightly # for nightly
|
||||
$ # for bash
|
||||
$ RUSTUP_DIST_SERVER=https://mirrors.tuna.tsinghua.edu.cn/rustup rustup install nightly-YYYY-mm-dd
|
||||
$ RUSTUP_DIST_SERVER=https://{{ site.hostname }}/rustup rustup install nightly-YYYY-mm-dd
|
||||
$ # for fish
|
||||
$ env RUSTUP_DIST_SERVER=https://mirrors.tuna.tsinghua.edu.cn/rustup rustup install nightly-YYYY-mm-dd
|
||||
$ env RUSTUP_DIST_SERVER=https://{{ site.hostname }}/rustup rustup install nightly-YYYY-mm-dd
|
||||
```
|
||||
|
||||
若要长期启用 TUNA 源,执行:
|
||||
|
||||
```bash
|
||||
$ # for bash
|
||||
$ echo 'export RUSTUP_DIST_SERVER=https://mirrors.tuna.tsinghua.edu.cn/rustup' >> ~/.bash_profile
|
||||
$ echo 'export RUSTUP_DIST_SERVER=https://{{ site.hostname }}/rustup' >> ~/.bash_profile
|
||||
$ # for fish
|
||||
$ echo 'set -x RUSTUP_DIST_SERVER https://mirrors.tuna.tsinghua.edu.cn/rustup' >> ~/.config/fish/config.fish
|
||||
$ echo 'set -x RUSTUP_DIST_SERVER https://{{ site.hostname }}/rustup' >> ~/.config/fish/config.fish
|
||||
```
|
||||
|
||||
注:rustup 在判断是否需要更新时依赖于 toml 的 sha256 ,由于 toml 内容中相关链接被替换为 TUNA 源,第一次切换到 TUNA 源时各个 channel 会被认为需要更新。
|
||||
|
|
|
|||
|
|
@ -19,58 +19,58 @@ mirrorid: nix
|
|||
- 单用户安装
|
||||
|
||||
```console
|
||||
$ sh <(curl https://mirrors.tuna.tsinghua.edu.cn/nix/latest/install)
|
||||
$ sh <(curl https://{{ site.hostname }}/nix/latest/install)
|
||||
```
|
||||
- 多用户安装:
|
||||
|
||||
```console
|
||||
$ sh <(curl https://mirrors.tuna.tsinghua.edu.cn/nix/latest/install) --daemon
|
||||
$ sh <(curl https://{{ site.hostname }}/nix/latest/install) --daemon
|
||||
```
|
||||
|
||||
如果需要,可以在[文件列表中手动挑选需要的版本](https://mirrors.tuna.tsinghua.edu.cn/nix)。
|
||||
如果需要,可以在[文件列表中手动挑选需要的版本](https://{{ site.hostname }}/nix)。
|
||||
|
||||
### NixOS
|
||||
|
||||
NixOS 的安装镜像和 OVF 虚拟机镜像可以在镜像站首页“下载链接”处或 <https://mirrors.tuna.tsinghua.edu.cn/nixos-images/> 下载。
|
||||
NixOS 的安装镜像和 OVF 虚拟机镜像可以在镜像站首页“下载链接”处或 <https://{{ site.hostname }}/nixos-images/> 下载。
|
||||
|
||||
### Nixpkgs binary cache
|
||||
|
||||
Binary cache 的镜像位于 <https://mirrors.tuna.tsinghua.edu.cn/nix-channels/store>,与 channel 同步更新。
|
||||
Binary cache 的镜像位于 <https://{{ site.hostname }}/nix-channels/store>,与 channel 同步更新。
|
||||
|
||||
以优先选择镜像,备选源站为例,选择以下配置之一:
|
||||
|
||||
- 单独安装的 Nix:编辑配置文件添加或修改如下项(通常系统配置在 `/etc/nix/nix.conf`,用户配置在 `~/.config/nix/nix.conf`):
|
||||
|
||||
```plain
|
||||
substituters = https://mirrors.tuna.tsinghua.edu.cn/nix-channels/store https://cache.nixos.org/
|
||||
substituters = https://{{ site.hostname }}/nix-channels/store https://cache.nixos.org/
|
||||
```
|
||||
|
||||
- NixOS 和 nix-darwin 使用如下配置:
|
||||
|
||||
```nix
|
||||
nix.binaryCaches = [ "https://mirrors.tuna.tsinghua.edu.cn/nix-channels/store" "https://cache.nixos.org/" ];
|
||||
nix.binaryCaches = [ "https://{{ site.hostname }}/nix-channels/store" "https://cache.nixos.org/" ];
|
||||
```
|
||||
|
||||
- NixOS 19.09 及以后版本和 nix-darwin 中系统会自动配置备选源站,也可用如下配置:
|
||||
|
||||
```nix
|
||||
nix.binaryCaches = [ "https://mirrors.tuna.tsinghua.edu.cn/nix-channels/store" ];
|
||||
nix.binaryCaches = [ "https://{{ site.hostname }}/nix-channels/store" ];
|
||||
```
|
||||
|
||||
### Nixpkgs channel
|
||||
|
||||
Channel 的镜像位于 <https://mirrors.tuna.tsinghua.edu.cn/nix-channels/> 目录下,使用方式与 <https://nixos.org/channels/> 相同。
|
||||
Channel 的镜像位于 <https://{{ site.hostname }}/nix-channels/> 目录下,使用方式与 <https://nixos.org/channels/> 相同。
|
||||
|
||||
单独安装的 Nix 替换 `nixpkgs-unstable` 命令如下:
|
||||
|
||||
```console
|
||||
$ nix-channel --add https://mirrors.tuna.tsinghua.edu.cn/nix-channels/nixpkgs-unstable
|
||||
$ nix-channel --add https://{{ site.hostname }}/nix-channels/nixpkgs-unstable
|
||||
$ nix-channel --update
|
||||
```
|
||||
|
||||
替换 NixOS channel 命令如下(以 root 执行,将 `19.09` 替换为系统版本):
|
||||
|
||||
```console
|
||||
# nix-channel --add https://mirrors.tuna.tsinghua.edu.cn/nix-channels/nixos-19.09
|
||||
# nix-channel --add https://{{ site.hostname }}/nix-channels/nixos-19.09
|
||||
# nix-channel --update
|
||||
```
|
||||
|
|
|
|||
|
|
@ -11,17 +11,17 @@ mirrorid: dart-pub
|
|||
库。
|
||||
|
||||
如果希望通过 TUNA 的 pub 镜像安装软件,只需要设置 [PUB_HOSTED_URL](https://www.dartlang.org/tools/pub/environment-variables)
|
||||
这个环境变量指向 https://mirrors.tuna.tsinghua.edu.cn/dart-pub/ 即可。
|
||||
这个环境变量指向 https://{{ site.hostname }}/dart-pub/ 即可。
|
||||
|
||||
以 bash 为例,临时使用 TUNA 的镜像来安装依赖:
|
||||
|
||||
```bash
|
||||
$ PUB_HOSTED_URL="https://mirrors.tuna.tsinghua.edu.cn/dart-pub/" pub get # pub
|
||||
$ PUB_HOSTED_URL="https://mirrors.tuna.tsinghua.edu.cn/dart-pub/" flutter packages get # flutter
|
||||
$ PUB_HOSTED_URL="https://{{ site.hostname }}/dart-pub/" pub get # pub
|
||||
$ PUB_HOSTED_URL="https://{{ site.hostname }}/dart-pub/" flutter packages get # flutter
|
||||
```
|
||||
|
||||
若希望长期使用 TUNA 镜像:
|
||||
|
||||
```bash
|
||||
$ echo 'export PUB_HOSTED_URL="https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"' >> ~/.bashrc
|
||||
$ echo 'export PUB_HOSTED_URL="https://{{ site.hostname }}/dart-pub/"' >> ~/.bashrc
|
||||
```
|
||||
|
|
|
|||
|
|
@ -8,18 +8,18 @@ mirrorid: flutter
|
|||
|
||||
Flutter 是一款跨平台的移动应用开发框架,由 Google 开源。用 Flutter 开发的应用可以直接编译成 ARM 代码运行在 Android 和 iOS 系统上。
|
||||
|
||||
最新版 Flutter SDK 安装包可[从镜像站下载](https://mirrors.tuna.tsinghua.edu.cn/flutter/flutter_infra/releases/stable/)。
|
||||
最新版 Flutter SDK 安装包可[从镜像站下载](https://{{ site.hostname }}/flutter/flutter_infra/releases/stable/)。
|
||||
|
||||
Flutter 首次使用或更新时需要从 Google Storage 下载文件,如您的网络访问 Google 受阻,建议使用本镜像。使用方法为设置环境变量 `FLUTTER_STORAGE_BASE_URL`,并指向 TUNA 镜像站。
|
||||
|
||||
```bash
|
||||
$ export FLUTTER_STORAGE_BASE_URL="https://mirrors.tuna.tsinghua.edu.cn/flutter"
|
||||
$ export FLUTTER_STORAGE_BASE_URL="https://{{ site.hostname }}/flutter"
|
||||
```
|
||||
|
||||
若希望长期使用 TUNA 镜像:
|
||||
|
||||
```bash
|
||||
$ echo 'export FLUTTER_STORAGE_BASE_URL="https://mirrors.tuna.tsinghua.edu.cn/flutter"' >> ~/.bashrc
|
||||
$ echo 'export FLUTTER_STORAGE_BASE_URL="https://{{ site.hostname }}/flutter"' >> ~/.bashrc
|
||||
```
|
||||
|
||||
此外 Flutter 开发中还需要用到 Dart 语言的包管理器 Pub,其镜像使用方法参见[Pub 镜像安装帮助](../dart-pub/)。
|
||||
此外 Flutter 开发中还需要用到 Dart 语言的包管理器 Pub,其镜像使用方法参见[Pub 镜像安装帮助](../dart-pub/)。
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ Arch4edu 是面向高校用户推出的非官方软件仓库,
|
|||
主要包含高校用户常用的科研、教学及开发软件。
|
||||
|
||||
* 项目地址:<https://github.com/arch4edu/arch4edu>
|
||||
* 镜像地址:<https://mirrors.tuna.tsinghua.edu.cn/arch4edu>
|
||||
* 镜像地址:<https://{{ site.hostname }}/arch4edu>
|
||||
|
||||
### 使用方法
|
||||
|
||||
|
|
@ -27,7 +27,7 @@ $ pacman-key --lsign-key 7931B6D628C8D3BA
|
|||
|
||||
```
|
||||
[arch4edu]
|
||||
Server = https://mirrors.tuna.tsinghua.edu.cn/arch4edu/$arch
|
||||
Server = https://{{ site.hostname }}/arch4edu/$arch
|
||||
```
|
||||
|
||||
* [**不推荐**] 不导入 GPG key,并直接在 `/etc/pacman.conf` 文件末尾添加以下内容:
|
||||
|
|
@ -35,5 +35,5 @@ Server = https://mirrors.tuna.tsinghua.edu.cn/arch4edu/$arch
|
|||
```
|
||||
[arch4edu]
|
||||
SigLevel = Never
|
||||
Server = https://mirrors.tuna.tsinghua.edu.cn/arch4edu/$arch
|
||||
Server = https://{{ site.hostname }}/arch4edu/$arch
|
||||
```
|
||||
|
|
|
|||
|
|
@ -20,4 +20,4 @@ mirrorid: qubesos
|
|||
或者不想使用上述命令,您可以使用如下方法
|
||||
对于 `/etc/yum.repos.d` 下的 `qubes-*.repo`:
|
||||
1. 用`#`注释掉所有的 `metalink`
|
||||
2. 将 `baseurl` 中的 `https://yum.qubes-os.org/` 替换为 `https://mirrors.tuna.tsinghua.edu.cn/qubesos/repo/yum/` ,并取消这些 `baseurl` 的注释
|
||||
2. 将 `baseurl` 中的 `https://yum.qubes-os.org/` 替换为 `https://{{ site.hostname }}/qubesos/repo/yum/` ,并取消这些 `baseurl` 的注释
|
||||
|
|
|
|||
|
|
@ -9,14 +9,14 @@ mirrorid: solus
|
|||
Solus 是一个界面美观,对新手友好的 Linux 发行版,使用 `eopkg` 作为包管理器。
|
||||
|
||||
* 项目地址:<https://getsol.us>
|
||||
* 镜像地址:<https://mirrors.tuna.tsinghua.edu.cn/solus>
|
||||
* 镜像地址:<https://{{ site.hostname }}/solus>
|
||||
|
||||
### 使用方法
|
||||
|
||||
执行以下命令
|
||||
|
||||
```
|
||||
sudo eopkg add-repo Tuna https://mirrors.tuna.tsinghua.edu.cn/solus/shannon/eopkg-index.xml.xz
|
||||
sudo eopkg add-repo Tuna https://{{ site.hostname }}/solus/shannon/eopkg-index.xml.xz
|
||||
```
|
||||
|
||||
此后,之行以下命令以启用 Tuna 源,禁用官方源
|
||||
|
|
@ -29,7 +29,7 @@ sudo eopkg disable-repo Solus
|
|||
或者用 Tuna 源直接覆盖官方源
|
||||
|
||||
```
|
||||
sudo eopkg add-repo Solus https://mirrors.tuna.tsinghua.edu.cn/solus/shannon/eopkg-index.xml.xz
|
||||
sudo eopkg add-repo Solus https://{{ site.hostname }}/solus/shannon/eopkg-index.xml.xz
|
||||
```
|
||||
|
||||
关于 `eopkg` 命令的详细用法,请执行 `eopkg help` 查看帮助。
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ mirrorid: kicad
|
|||
|
||||
### KiCad 镜像目录使用说明
|
||||
|
||||
#### [KiCad 镜像目录说明](https://mirrors.tuna.tsinghua.edu.cn/kicad/)
|
||||
#### [KiCad 镜像目录说明](https://{{ site.hostname }}/kicad/)
|
||||
|
||||
目录 | 说明 | 备注
|
||||
-----------|----------|---------
|
||||
|
|
@ -39,7 +39,7 @@ list.js |JS 脚本 |无
|
|||
|
||||
#### Windows 下载安装
|
||||
|
||||
[KiCad Windows 版本下载](https://mirrors.tuna.tsinghua.edu.cn/kicad/windows/)
|
||||
[KiCad Windows 版本下载](https://{{ site.hostname }}/kicad/windows/)
|
||||
|
||||
目录 | 说明 | 备注
|
||||
-----------|----------|---------
|
||||
|
|
@ -49,7 +49,7 @@ testing/ | 测试版本|选择对应分支下载测试
|
|||
|
||||
#### OS X 下载安装
|
||||
|
||||
[OS X 版本下载](https://mirrors.tuna.tsinghua.edu.cn/kicad/osx/)
|
||||
[OS X 版本下载](https://{{ site.hostname }}/kicad/osx/)
|
||||
|
||||
目录 | 说明 | 备注
|
||||
-----------|----------|---------
|
||||
|
|
@ -61,7 +61,7 @@ testing/ | 测试版本|选择对应分支下载测试
|
|||
|
||||
##### [AUR 包](http://kicad-pcb.org/download/arch-linux/)
|
||||
|
||||
添加 [ArchlinuxCN](https://mirrors.tuna.tsinghua.edu.cn/help/archlinuxcn/) 镜像:
|
||||
添加 [ArchlinuxCN](https://{{ site.hostname }}/help/archlinuxcn/) 镜像:
|
||||
|
||||
```
|
||||
yaourt -Syu
|
||||
|
|
|
|||
|
|
@ -11,9 +11,9 @@ mirrorid: gentoo-portage-prefix
|
|||
在运行 Bootstrap 脚本之前,可通过设置以下环境变量选择 Bootstrap 过程中使用的镜像。
|
||||
|
||||
```
|
||||
export GENTOO_MIRRORS="http://mirrors.tuna.tsinghua.edu.cn/gentoo"
|
||||
export GNU_URL="http://mirrors.tuna.tsinghua.edu.cn/gnu"
|
||||
export SNAPSHOT_URL="http://mirrors.tuna.tsinghua.edu.cn/gentoo/snapshots"
|
||||
export GENTOO_MIRRORS="http://{{ site.hostname }}/gentoo"
|
||||
export GNU_URL="http://{{ site.hostname }}/gnu"
|
||||
export SNAPSHOT_URL="http://{{ site.hostname }}/gentoo/snapshots"
|
||||
```
|
||||
|
||||
### Gentoo Portage Prefix 镜像配置:
|
||||
|
|
@ -22,7 +22,7 @@ export SNAPSHOT_URL="http://mirrors.tuna.tsinghua.edu.cn/gentoo/snapshots"
|
|||
|
||||
```
|
||||
[gentoo_prefix]
|
||||
sync-uri = rsync://mirrors.tuna.tsinghua.edu.cn/gentoo-portage-prefix
|
||||
sync-uri = rsync://{{ site.hostname }}/gentoo-portage-prefix
|
||||
```
|
||||
|
||||
### Distfiles 配置:
|
||||
|
|
@ -30,7 +30,7 @@ sync-uri = rsync://mirrors.tuna.tsinghua.edu.cn/gentoo-portage-prefix
|
|||
这部分与在 Gentoo Linux 中配置无异,在 `$EPREFIX/etc/portage/make.conf` 中加入:
|
||||
|
||||
```
|
||||
GENTOO_MIRRORS="https://mirrors.tuna.tsinghua.edu.cn/gentoo"
|
||||
GENTOO_MIRRORS="https://{{ site.hostname }}/gentoo"
|
||||
```
|
||||
|
||||
配置好以上两项以后,执行 `emerge --sync` 或者 `eix-sync` 进行更新。
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ tlpretest 是 TeX Live 在官方镜像之外发布的测试版本,详情可见
|
|||
在命令行中执行:
|
||||
|
||||
```
|
||||
tlmgr option repository https://mirrors.tuna.tsinghua.edu.cn/tlpretest
|
||||
tlmgr option repository https://{{ site.hostname }}/tlpretest
|
||||
```
|
||||
|
||||
即可永久更改镜像源。
|
||||
|
|
@ -22,7 +22,7 @@ tlmgr option repository https://mirrors.tuna.tsinghua.edu.cn/tlpretest
|
|||
如果只需要临时切换,可以用如下命令:
|
||||
|
||||
```
|
||||
tlmgr update --all --repository https://mirrors.tuna.tsinghua.edu.cn/tlpretest
|
||||
tlmgr update --all --repository https://{{ site.hostname }}/tlpretest
|
||||
```
|
||||
|
||||
其中的 `update --all` 指令可根据需要修改。
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ docker 镜像作出相应调整。
|
|||
|
||||
现在的镜像地址为:
|
||||
|
||||
- APT: http://mirrors.tuna.tsinghua.edu.cn/docker/apt/repo
|
||||
- YUM: http://mirrors.tuna.tsinghua.edu.cn/docker/yum/repo
|
||||
- APT: http://{{ site.hostname }}/docker/apt/repo
|
||||
- YUM: http://{{ site.hostname }}/docker/yum/repo
|
||||
|
||||
请根据 [docker镜像帮助](/help/docker) 调整至正确的打开方式。
|
||||
|
|
|
|||
|
|
@ -8,13 +8,13 @@ author: Justin Wong
|
|||
由于从 TUNA 初始化 AOSP 工程时需要下载 36GB 数据,过程中任何网络故障都可能造成同步失败,因此我们决定每月对
|
||||
AOSP 完整工程进行一次打包,用户可以通过 HTTP 下载。解压后使用 Android 的 `repo` 工具直接同步即可。
|
||||
|
||||
首先到 http://mirrors.tuna.tsinghua.edu.cn/aosp-monthly/ 选择合适自己的构建包,aosp-latest.tar.xz 经过了 xz 压缩,
|
||||
首先到 http://{{ site.hostname }}/aosp-monthly/ 选择合适自己的构建包,aosp-latest.tar.xz 经过了 xz 压缩,
|
||||
体积相对 aosp-latest.tar 小一些,但是也有 27G 大小,请权衡自己的网络带宽和计算能力。
|
||||
|
||||
使用方法如下:
|
||||
|
||||
```
|
||||
wget http://mirrors.tuna.tsinghua.edu.cn/aosp-monthly/aosp-latest.tar # 下载初始化包
|
||||
wget http://{{ site.hostname }}/aosp-monthly/aosp-latest.tar # 下载初始化包
|
||||
tar xf aosp-latest.tar
|
||||
cd AOSP # 解压得到的 AOSP 工程目录
|
||||
repo sync # 正常同步
|
||||
|
|
|
|||
|
|
@ -7,6 +7,6 @@ author: Xavier Yao
|
|||
|
||||
TUNA mirrors 新增 Homebrew-bottles 镜像。
|
||||
|
||||
[Homebrew](http://brew.sh) 是 OS X 操作系统最常用的包管理器之一。[Homebrew-bottles](http://mirrors.tuna.tsinghua.edu.cn/homebrew-bottles) 镜像提供了供 Homebrew 使用的预编译二进制软件包。配置方法见 [Homebrew bottles 镜像使用帮助](https://mirrors.tuna.tsinghua.edu.cn/help/homebrew-bottles/)。
|
||||
[Homebrew](http://brew.sh) 是 OS X 操作系统最常用的包管理器之一。[Homebrew-bottles](http://{{ site.hostname }}/homebrew-bottles) 镜像提供了供 Homebrew 使用的预编译二进制软件包。配置方法见 [Homebrew bottles 镜像使用帮助](https://{{ site.hostname }}/help/homebrew-bottles/)。
|
||||
|
||||
本镜像站同时提供 Homebrew 的 formula 索引的镜像(即 `brew update` 时所更新内容),配置方法请参考 [Homebrew 镜像使用帮助](https://mirrors.tuna.tsinghua.edu.cn/help/homebrew/)。
|
||||
本镜像站同时提供 Homebrew 的 formula 索引的镜像(即 `brew update` 时所更新内容),配置方法请参考 [Homebrew 镜像使用帮助](https://{{ site.hostname }}/help/homebrew/)。
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ title: "镜像站维护通知"
|
|||
author: Miao Wang
|
||||
---
|
||||
|
||||
根据清华大学信息化技术中心的统一安排,近期镜像站服务器及其依赖的网络基础设施将会陆续由主楼机房搬迁/割接至李兆基机房。在割接期间,到达镜像站的网络可能出现不稳定等情况;在服务器迁移期间,镜像站的带宽可能有所减少。为此造成的不便,我们深表歉意。具体的时间安排如下,望周知。
|
||||
根据{{ site.operator }}的统一安排,近期镜像站服务器及其依赖的网络基础设施将会陆续由主楼机房搬迁/割接至李兆基机房。在割接期间,到达镜像站的网络可能出现不稳定等情况;在服务器迁移期间,镜像站的带宽可能有所减少。为此造成的不便,我们深表歉意。具体的时间安排如下,望周知。
|
||||
|
||||
|
||||
{: .table}
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ author: Miao Wang
|
|||
|
||||
由于 Debian 将给 \<CC\>.debian.org 域名设置 CAA 记录,并禁止给 *.\<CC\>.debian.org 签署 HTTPS 证书,所以我们无法再提供 https://ftp2.cn.debian.org 的访问。
|
||||
|
||||
由于国内 ISP 经常会错误地缓存镜像站的内容,所以我们不鼓励用户使用 HTTP 访问镜像站,请大家把地址更改为 [https://mirrors.tuna.tsinghua.edu.cn](https://mirrors.tuna.tsinghua.edu.cn)
|
||||
由于国内 ISP 经常会错误地缓存镜像站的内容,所以我们不鼓励用户使用 HTTP 访问镜像站,请大家把地址更改为 [https://{{ site.hostname }}](https://{{ site.hostname }})
|
||||
|
||||
目前 ftp2.cn.debian.org 的证书将于 2017 年 11 月 25 日 过期,我们会在此之前取消 https://ftp2.cn.debian.org 的访问。
|
||||
|
||||
|
|
|
|||
|
|
@ -7,6 +7,6 @@ author: Miao Wang
|
|||
|
||||
近期,为提高服务质量,TUNA 镜像站将实施重大升级改造。预计在实施升级改造后,镜像站对外服务的能力将会有明显提升。在升级改造期间,到达镜像站的网络可能出现不稳定等情况,对外提供服务的带宽可能有所减少。本次改造时间预计最早会在 3 月 10 日前完成,对于带来的不便,我们深表歉意。如遇问题,请到 [tuna/issues](https://github.com/tuna/issues/issues) 反馈。
|
||||
|
||||
**Update 1**: 从本通知发出之时起,为配合升级改造,archlinux 每月历史镜像功能([https://arch-archive.tuna.tsinghua.edu.cn/](https://arch-archive.tuna.tsinghua.edu.cn/))暂时停止提供服务。
|
||||
**Update 1**: 从本通知发出之时起,为配合升级改造,archlinux 每月历史镜像功能([https://{{ site.arch_archive }}/](https://{{ site.arch_archive }}/))暂时停止提供服务。
|
||||
|
||||
**Update 2**: 上述维护已经完成。
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ category: news
|
|||
|
||||
为了解决这一矛盾,我们对公开的日志中的 IP 地址信息进行了一定的变换,以确保用户的隐私不被泄露的同时,尽可能减少数据研究价值的减损。具体的变换规则是:保持 IPv4 地址的前 24 位或 IPv6 地址的前 48 位不变,将 IP 地址伪随机地映射至其他地址,该映射关系在 30 秒内保持固定,每隔 30 秒发生一次改变。
|
||||
|
||||
我们目前共有两个后端服务器,日志的访问地址分别是 [https://mirrors.tuna.tsinghua.edu.cn/logs/neomirrors/](/logs/neomirrors/) 和 [https://mirrors.tuna.tsinghua.edu.cn/logs/nanomirrors/](/logs/nanomirrors/)。日志的格式是:
|
||||
我们目前共有两个后端服务器,日志的访问地址分别是 [https://{{ site.hostname }}/logs/neomirrors/](/logs/neomirrors/) 和 [https://{{ site.hostname }}/logs/nanomirrors/](/logs/nanomirrors/)。日志的格式是:
|
||||
|
||||
```
|
||||
$fake_remote_addr - $remote_user [$time_local] "$request" $status $body_bytes_sent "$sent_http_content_type" "$http_referer" "$http_user_agent" - $scheme
|
||||
|
|
|
|||
|
|
@ -1,11 +1,12 @@
|
|||
#!/bin/bash
|
||||
HOST="mirrors.tuna.tsinghua.edu.cn"
|
||||
|
||||
echo '# robots.txt for https://mirrors.tuna.tsinghua.edu.cn' > robots.txt
|
||||
echo "# robots.txt for https://$HOST" > robots.txt
|
||||
echo 'User-agent: *' >> robots.txt
|
||||
echo '' >> robots.txt
|
||||
echo 'Disallow: /logs' >> robots.txt
|
||||
|
||||
curl -s https://mirrors.tuna.tsinghua.edu.cn/static/tunasync.json | jq -r '.[] | .name' | uniq | while read name; do
|
||||
curl -s https://$HOST/static/tunasync.json | jq -r '.[] | .name' | uniq | while read name; do
|
||||
[[ -z ${name} ]] && continue
|
||||
echo "Disallow: /${name}" >> robots.txt
|
||||
done
|
||||
|
|
|
|||
Loading…
Reference in New Issue