From 7afe404d6db504f4082f6ef13504582330b0d3d6 Mon Sep 17 00:00:00 2001 From: Reiuji Utsuho Date: Fri, 17 May 2019 14:15:04 +0800 Subject: [PATCH] use regex to replace termux source --- _posts/help/1970-01-01-termux.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_posts/help/1970-01-01-termux.md b/_posts/help/1970-01-01-termux.md index be5b7e0..7087858 100644 --- a/_posts/help/1970-01-01-termux.md +++ b/_posts/help/1970-01-01-termux.md @@ -33,7 +33,7 @@ Termux 是运行在 Android 上的 terminal。不需要root,运行于内部存 使用如下命令自动替换官方源为 TUNA 镜像源 ``` bash -sed -i 's@dl.bintray.com/termux/termux-packages-24@mirrors.tuna.tsinghua.edu.cn/termux@' $PREFIX/etc/apt/sources.list +sed -i 's@^\(deb.*stable main\)$@#\1\ndeb https://mirrors.tuna.tsinghua.edu.cn/termux stable main@' $PREFIX/etc/apt/sources.list pkg up ```