index.html 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. <!doctype html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1" />
  6. <link rel="canonical" href="https://jamesfengcao.gitlab.io/uweb/en/termux/" />
  7. <link rel="stylesheet" href="../style.css#" type="text/css" />
  8. <title>Termux</title>
  9. <script>
  10. function findLang(){
  11. let href = location.href;
  12. for(let i=href.length-1;i>0;i--){
  13. if('/'==href.charAt(i) && '/'==href.charAt(i-3))
  14. return i;
  15. }
  16. return 0;
  17. }
  18. function nav2(page){
  19. let i = findLang();
  20. location.href = location.href.substring(0,i+1)+page;
  21. }
  22. function nav2Lang(lang){
  23. let i = findLang();
  24. let href = location.href;
  25. location.href = location.href.substring(0,i-2)+lang+location.href.substring(i);
  26. }
  27. </script>
  28. </head>
  29. <body>
  30. <header class='header'>
  31. <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>
  32. <nav>
  33. </nav>
  34. </header>
  35. <br />
  36. <div class="container">
  37. <h1 class="title">Termux
  38. <br>
  39. <span class="subtitle"></span>
  40. </h1>
  41. <ul class="tags">
  42. </ul>
  43. <p>Only the termux versions provided along with uweb browser can work seamlessly. For android 10+, please install termux before installing uweb browser. If uweb is already installed, users can uninstall it first, then install termux and reinstall uweb browser.</p>
  44. <h4 id="termux-bookmarks">Termux bookmarks</h4>
  45. <p>Long pressing the following links then either &quot;commands&quot;-&gt;&quot;<a href="../urls/index.html#">bookmark</a>&quot; to add bookmarks or &quot;open in new tab&quot; to execute.<br>
  46. <a href="c:bc -l">GNU bc (basic calculator)</a><br>
  47. <a href="c:bc -l *.bc">bc with all extensions</a></p>
  48. <h4 id="click-the-following-links-to-install-termux-configurations">Click the following links to install termux configurations:</h4>
  49. <p><a href="i:0h/data/data/com.termux/files/home/.bashrc:../../termux/bashrc">.bashrc</a></p>
  50. <p><a href="i:0h/data/data/com.termux/files/home/.profile:../../termux/profile">.profile</a></p>
  51. <p><a href="i:0h/data/data/com.termux/files/home/.inputrc:../../termux/inputrc">.inputrc</a></p>
  52. <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>
  53. <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>
  54. <p><a href="i:0h/data/data/com.termux/files/home/.profile:../../termux/profile">.profile</a> : only for kshell with naked termux (no initial packages, need the following fix for termux quick crash to be launched)</p>
  55. <h4 id="copy-existing-termux-installation-to-other-devices">Copy existing termux installation to other devices</h4>
  56. <p>Using uweb to copy (Long pressing the following links and &quot;open in new tab&quot; to fix/send/receive):</p>
  57. <ul>
  58. <li>target device: install termux app.</li>
  59. <li>(optional)<a href="d::mkdir -p /data/user/0/com.termux/files/home/.termux;cd /data/user/0/com.termux/files;mkdir usr;cd home/.termux;ln -s /system/bin/sh shell:">fix termux quick crash with &quot;updateonly&quot; versions</a> by long click this link.</li>
  60. <li>both devices: launch termux and acquire wakelocks. uweb to checke option &quot;Use termux&quot; in UI configuration page for long time tranferring. Uweb itself does not hold any wakelock thus may have issues for huge data transmission.</li>
  61. <li>source device: uweb to visit <a href="file:///data/data/com.termux/files/">termux folder</a> by long click, then long click &quot;usr&quot; folder to send to network.</li>
  62. <li>target device: uweb to visit <a href="file:///data/data/com.termux/files/">termux folder</a> by long click, then long click &quot;right arrow&quot; button to receive from network.</li>
  63. </ul>
  64. <h5 id="using-ssh-to-copy">Using ssh to copy</h5>
  65. <ul>
  66. <li>target device: install termux app, then run &quot;apt install openssh&quot; inside the termux.</li>
  67. <li>source device: Send the &quot;~/.ssh&quot; folder with uweb browser to the network.</li>
  68. <li>target device: Uweb to visit &quot;file://data/data/com.termux/files/home/&quot; to reach the folder, then receive the data sent by the above source device.</li>
  69. <li>source device: Run &quot;sshd&quot;.</li>
  70. <li>target device: Run the command &quot;scp -P 8022 -r [source ip]:.. ..&quot;</li>
  71. </ul>
  72. <h4 id="tips">Tips</h4>
  73. <p>File system navigation:<br>
  74. 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 &quot;v&quot; to launch uweb file manager on the current working directory, long click any file link to share.</p>
  75. </div>
  76. <p>Last Modified: 22 August 2024<br>
  77. add more download sites<br>
  78. <pre></pre>
  79. </p>
  80. <script id='jsgiscus'
  81. src='https://giscus.app/client.js'
  82. data-repo="torappinfo/uweb"
  83. data-repo-id="MDEwOlJlcG9zaXRvcnkzMDIyMDU3MjE="
  84. data-category="Announcements"
  85. data-category-id="DIC_kwDOEgNLGc4CQjsh"
  86. data-mapping="title"
  87. data-strict="0"
  88. data-reactions-enabled="1"
  89. data-emit-metadata="0"
  90. data-input-position="top"
  91. data-theme="light"
  92. data-lang="en"
  93. data-loading="lazy"
  94. crossorigin="anonymous" async>
  95. </script>
  96. <footer class="site-footer">
  97. <div class="container">
  98. &copy; 2018-2024 Richard H. Cao
  99. </div>
  100. </footer>
  101. <!-- This document is licensed under the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is available at <https://www.gnu.org/licenses/>. -->
  102. </body>
  103. </html>