mirror of https://github.com/torappinfo/uweb
rebuilding site Mon Aug 1 08:22:51 PM CST 2022
parent
26bfc316fc
commit
47c46dc01a
@ -0,0 +1,67 @@
|
||||
<!doctype html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
|
||||
<link rel="stylesheet" href="/uwebzh/style.css" type="text/css" />
|
||||
<title>Termux</title>
|
||||
<script type="text/javascript">
|
||||
function findLang(){
|
||||
let href = location.href;
|
||||
for(let i=href.length-1;i>0;i--){
|
||||
if('/'==href.charAt(i) && '/'==href.charAt(i-3))
|
||||
return i;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
function nav2(page){
|
||||
let i = findLang();
|
||||
location.href = location.href.substring(0,i+1)+page;
|
||||
}
|
||||
function nav2Lang(lang){
|
||||
let i = findLang();
|
||||
let href = location.href;
|
||||
location.href = location.href.substring(0,i-2)+lang+location.href.substring(i);
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<header class='header'>
|
||||
<a class="logo" href="javascript:void(0)" onclick="return nav2('index.html')">Home</a> <a class="logo" href="javascript:void(0)" onclick="return nav2('tags/index.html')">Tags</a>
|
||||
|
||||
<nav>
|
||||
</nav>
|
||||
</header>
|
||||
<br />
|
||||
|
||||
<div class="container">
|
||||
<h1 class="title">Termux
|
||||
<br>
|
||||
<span class="subtitle"></span>
|
||||
</h1>
|
||||
<ul class="tags">
|
||||
|
||||
</ul>
|
||||
<p>Only the termux versions provided along with uweb browser can work seamlessly.</p>
|
||||
<h4 id="click-the-following-links-to-install-termux-configurations">Click the following links to install termux configurations:</h4>
|
||||
<p><a href="i:0h/data/data/com.termux/files/home/.bashrc:https://fastly.jsdelivr.net/gh/torappinfo/uwebzh/termux/bashrc">.bashrc</a></p>
|
||||
<p><a href="i:0h/data/data/com.termux/files/home/.inputrc:https://fastly.jsdelivr.net/gh/torappinfo/uwebzh/termux/inputrc">.inputrc</a></p>
|
||||
<p><a href="i:0h/data/data/com.termux/files/home/z.sh:https://fastly.jsdelivr.net/gh/rupa/z/z.sh">z.sh</a></p>
|
||||
<p><a href="i:0h/data/data/com.termux/files/home/commacd.sh:https://fastly.jsdelivr.net/gh/shyiko/commacd/commacd.sh">commacd.sh</a></p>
|
||||
<h4 id="copy-existing-termux-installation-to-other-devices">Copy existing termux installation to other devices</h4>
|
||||
<ul>
|
||||
<li>target device: install termux app, then run "apt install openssh" inside the termux.</li>
|
||||
<li>source device: Send the "~/.ssh" folder with uweb browser to the network.</li>
|
||||
<li>target device: Uweb to visit "file://data/data/com.termux/files/home/" to reach the folder, then receive the data sent by the above source device.</li>
|
||||
<li>source device: Run "sshd".</li>
|
||||
<li>target device: Run the command "scp -P 8022 -r [source ip]:.. .."</li>
|
||||
</ul>
|
||||
<h4 id="tips">Tips</h4>
|
||||
<p>File system navigation:<br>
|
||||
With <a href="https://github.com/rupa/z">z.sh</a> and <a href="https://github.com/shyiko/commacd">commacd</a>, user can reach any folder with few key stokes. Run "v" to launch uweb file manager on the current working directory, long click any file link to share.</p>
|
||||
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -0,0 +1,44 @@
|
||||
unset HISTFILE
|
||||
if [[ $EUID -ne 0 ]]; then
|
||||
history -r ~/.bash_history
|
||||
else
|
||||
history -r ~/.bash_history.root
|
||||
fi
|
||||
export HISTCONTROL=ignoreboth:erasedups
|
||||
#shopt -s histappend
|
||||
|
||||
shopt -s globstar
|
||||
|
||||
export _Z_CMD=j
|
||||
. z.sh
|
||||
. commacd.sh
|
||||
|
||||
alias j="_z"
|
||||
v(){
|
||||
file=
|
||||
if [ $1 ]; then
|
||||
file=${1}
|
||||
shift
|
||||
fi
|
||||
url="file://${PWD}/${file}"
|
||||
am start -a android.intent.action.VIEW -d "$url" $@
|
||||
}
|
||||
|
||||
d(){
|
||||
word=$1
|
||||
dict=${2:-ahd}
|
||||
tdict ~/share/dict/$dict $1
|
||||
}
|
||||
|
||||
z(){
|
||||
#usage: z word dictname percent
|
||||
word=$1
|
||||
dict=~/share/dict/$2.xz
|
||||
percent=''
|
||||
if [ "$3" ]; then
|
||||
percent=${3}p
|
||||
fi
|
||||
xz -cdf -- "$dict" | less -n +"${percent}/####$word"
|
||||
}
|
||||
|
||||
export LESS=-inR
|
@ -0,0 +1,12 @@
|
||||
set editing-mode vi
|
||||
|
||||
$if Bash
|
||||
Space: magic-space
|
||||
$endif
|
||||
"\e[A": history-search-backward
|
||||
"\e[B": history-search-forward
|
||||
|
||||
set completion-prefix-display-length 2
|
||||
|
||||
Control-j: menu-complete
|
||||
Control-k: menu-complete-backward
|
Loading…
Reference in New Issue