From d8c79c22e038bf27665c0f3fb9ab8b25148227c7 Mon Sep 17 00:00:00 2001 From: James Feng Cao Date: Fri, 12 Aug 2022 11:37:01 +0800 Subject: [PATCH] rebuilding site Fri Aug 12 11:37:00 AM CST 2022 --- en/_posts/index.xml | 2 +- en/cmds/index.html | 25 +++++++++++++------------ en/index.xml | 8 ++++---- en/sitemap/index.html | 4 ++-- en/termux/index.html | 1 + en/topposts/index.xml | 6 +++--- index.html | 11 +---------- termux/profile | 3 +++ zh/cmds/index.html | 20 +++++++++++--------- zh/index.xml | 10 +++++----- zh/searchurl/backup.html | 2 +- zh/searchurl/cmds.html | 2 +- zh/searchurl/config.js | 2 +- zh/searchurl/homescreen.html | 6 +++--- zh/searchurl/res.html | 2 +- zh/searchurl/rjs.html | 6 +++--- zh/searchurl/template/config.html | 2 +- zh/sitemap/index.html | 4 ++-- zh/topposts/index.xml | 10 +++++----- 19 files changed, 62 insertions(+), 64 deletions(-) create mode 100644 termux/profile diff --git a/en/_posts/index.xml b/en/_posts/index.xml index 67b03ac..4b3e37f 100644 --- a/en/_posts/index.xml +++ b/en/_posts/index.xml @@ -165,7 +165,7 @@ Click the following links to install termux configurations: .bashrc .inputrc z.sh commacd.sh -Copy existing termux installation to other devices Using uweb to copy (Long pressing the following links and "open in new tab" to fix/send/receive): +.profile : only for kshell with naked termux (no initial packages, need the following fix for termux quick crash to be launched) diff --git a/en/cmds/index.html b/en/cmds/index.html index c2fa9c0..be2dbe2 100644 --- a/en/cmds/index.html +++ b/en/cmds/index.html @@ -50,8 +50,6 @@

Click the following links to install commands with uweb browser. Force exit and re-launch the app, then long press the button with clock icon to popup the command menu.

Configuration file "default.cmds" examples:

Clear data::toybox find /data/data/info.torapp.uweb/app_webview ! -name 'Cookies' -type f -delete

-

VPN::am start -a android.net.vpn.SETTINGS

-

wireless::am start -a android.settings.WIRELESS_SETTINGS

Append query to autocomplete:uweb:cd /data/data/info.torinfo.uweb/files;cat default.autoc query.log|toybox sort|toybox uniq -i>a.tmp;mv a.tmp default.autoc;>query.log;echo file:///data/data/info.torinfo.uweb/files/default.autoc

Clear cache::toybox rm -rf /data/data/info.torapp.uweb/cache

Clear logcat::logcat -c

@@ -60,27 +58,30 @@

config in Download::cd /data/data/info.torinfo.uweb;toybox rm -rf files;toybox mkdir -p /sdcard/Download/uweb;toybox ln -s /sdcard/Download/uweb files

html5 in Download::cd /data/data/info.torinfo.uweb/files;toybox rm -rf app;toybox mkdir -p /sdcard/Download/app;toybox ln -s /sdcard/Download/app

tgz install::toybox tar -xzf %f -C /

-

Need root permissions:

-

Need termux:
-cd:termux/*:cd %f;exit 1

-

vim:termux/*:vim %f

-

deduplicate history::awk -F'\t' '!s[$2]++' /data/data/info.torinfo.uweb/files/history.rec>/sdcard/a.tmp;mv /sdcard/Download/a.tmp /data/data/info.torinfo.uweb/files/history.rec

-

deduplicate bookmarks::awk '!s[$0]++' /data/data/info.torinfo.uweb/files/bookmark.html>/sdcard/Download/a.tmp;mv /sdcard/Download/a.tmp /data/data/info.torinfo.uweb/files/bookmark.html

-

deduplicate hosts::toybox tac /data/data/info.torinfo.uweb/files/default.hosts|awk -F' ' '!s[$1]++' |toybox tac>/sdcard/Download/a.tmp;mv /sdcard/Download/a.tmp /data/data/info.torinfo.uweb/files/default.hosts

-

deduplicate siteconf::toybox tac /data/data/info.torinfo.uweb/files/default.siteconf|awk -F':' '!s[$1]++' |toybox tac>/sdcard/Download/a.tmp;mv /sdcard/Download/a.tmp /data/data/info.torinfo.uweb/files/default.siteconf

+

Users should change the IP addresses in the following menus accordingly. In all cases, TV side needs to execute "wait for network msg" first. Send message to network (ex. for android TVs):
+Send clipboard:clip/uweb:printf 'i:5ji:5b';cat

Send url::printf '%u'|/system/bin/toybox nc 192.168.2.155 1500

Send url(player)::printf 'i:5g%u'|/system/bin/toybox nc 192.168.2.155 1500

Sendurl(bookmark)::printf 'i:51../home5:i:0mc16:%u'|/system/bin/toybox nc 192.168.2.155 1500

Send url(fullscreen)::printf 'i:5f%u'|/system/bin/toybox nc 192.168.2.155 1500

Send url(video)::printf 'i:0mc16:%u'|/system/bin/toybox nc 192.168.2.155 1500

Send url(clipboard):clip:(printf 'i:5b';cat)|/system/bin/toybox nc 192.168.2.155 1500

+

Need root permissions:

+

Need termux:
+VPN::am start -a android.net.vpn.SETTINGS

+

wireless::am start -a android.settings.WIRELESS_SETTINGS

+

cd:termux/*:cd %f;exit 1

+

vim:termux/*:vim %f

+

deduplicate history::awk -F'\t' '!s[$2]++' /data/data/info.torinfo.uweb/files/history.rec>/sdcard/a.tmp;mv /sdcard/Download/a.tmp /data/data/info.torinfo.uweb/files/history.rec

+

deduplicate bookmarks::awk '!s[$0]++' /data/data/info.torinfo.uweb/files/bookmark.html>/sdcard/Download/a.tmp;mv /sdcard/Download/a.tmp /data/data/info.torinfo.uweb/files/bookmark.html

+

deduplicate hosts::toybox tac /data/data/info.torinfo.uweb/files/default.hosts|awk -F' ' '!s[$1]++' |toybox tac>/sdcard/Download/a.tmp;mv /sdcard/Download/a.tmp /data/data/info.torinfo.uweb/files/default.hosts

+

deduplicate siteconf::toybox tac /data/data/info.torinfo.uweb/files/default.siteconf|awk -F':' '!s[$1]++' |toybox tac>/sdcard/Download/a.tmp;mv /sdcard/Download/a.tmp /data/data/info.torinfo.uweb/files/default.siteconf

Clipboard2PC:clip:ssh fengcao@192.168.2.120 'DISPLAY=:0 xsel -i'

ClipboardFromPC:/clip:ssh fengcao@192.168.2.120 'DISPLAY=:0 xsel -o'

Clipboard broadcast:clip:socat - UDP-DATAGRAM:255.255.255.255:1500,broadcast

Clipboard from broadcast:/clip:socat -u udp-recvfrom:1500 SYSTEM:'cat;exit'

Clipboard2QR:clip/uweb:qrencode -o /sdcard/Download/a.png;echo file:///sdcard/Download/a.png

-

"Send url" needs to modify Android TV ip address.
-Clipboard2PC needs to modify username, PC needs xsel. ssh needs to be installed inside termux (apt install openssh).
+

Clipboard2PC needs to modify username, PC needs xsel. ssh needs to be installed inside termux (apt install openssh).
Clipboard broadcast needs socat(apt install socat)。
Clipboard2QR needs libqrencode.

More commands (click to install)

diff --git a/en/index.xml b/en/index.xml index b0b647e..afb6f49 100644 --- a/en/index.xml +++ b/en/index.xml @@ -193,11 +193,11 @@ trace.moe:https://trace.moe/?url= Click the following links to install commands with uweb browser. Force exit and re-launch the app, then long press the button with clock icon to popup the command menu. Configuration file "default.cmds" examples: Clear data::toybox find /data/data/info.torapp.uweb/app_webview ! -name 'Cookies' -type f -delete -VPN::am start -a android.net.vpn.SETTINGS -wireless::am start -a android.settings.WIRELESS_SETTINGS Append query to autocomplete:uweb:cd /data/data/info.torinfo.uweb/files;cat default.autoc query.log|toybox sort|toybox uniq -i>a.tmp;mv a.tmp default.autoc;>query.log;echo file:///data/data/info.torinfo.uweb/files/default.autoc Clear cache::toybox rm -rf /data/data/info.torapp.uweb/cache -Clear logcat::logcat -c +Clear logcat::logcat -c +logcat.log::logcat -d > logcat.log +copy cookie:/clip:printf '%c'
@@ -272,7 +272,7 @@ Click the following links to install termux configurations: .bashrc .inputrc z.sh commacd.sh -Copy existing termux installation to other devices Using uweb to copy (Long pressing the following links and "open in new tab" to fix/send/receive): +.profile : only for kshell with naked termux (no initial packages, need the following fix for termux quick crash to be launched) diff --git a/en/sitemap/index.html b/en/sitemap/index.html index 6f63e99..a5a394b 100644 --- a/en/sitemap/index.html +++ b/en/sitemap/index.html @@ -50,7 +50,7 @@

UI

Customization

Advanced

Content
diff --git a/en/termux/index.html b/en/termux/index.html index 3fa0ef9..3f5481f 100644 --- a/en/termux/index.html +++ b/en/termux/index.html @@ -53,6 +53,7 @@

.inputrc

z.sh

commacd.sh

+

.profile : only for kshell with naked termux (no initial packages, need the following fix for termux quick crash to be launched)

Copy existing termux installation to other devices

Using uweb to copy (Long pressing the following links and "open in new tab" to fix/send/receive):