<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xmlns:tt="http://teletype.in/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:media="http://search.yahoo.com/mrss/"><channel><title>Termux guide</title><generator>teletype.in</generator><description><![CDATA[Интересное о термукс]]></description><image><url>https://img1.teletype.in/files/88/d6/88d601ac-6876-483f-b4f2-efa7a630b45b.png</url><title>Termux guide</title><link>https://teletype.in/@termuxq</link></image><link>https://teletype.in/@termuxq?utm_source=teletype&amp;utm_medium=feed_rss&amp;utm_campaign=termuxq</link><atom:link rel="self" type="application/rss+xml" href="https://teletype.in/rss/termuxq?offset=0"></atom:link><atom:link rel="next" type="application/rss+xml" href="https://teletype.in/rss/termuxq?offset=10"></atom:link><atom:link rel="search" type="application/opensearchdescription+xml" title="Teletype" href="https://teletype.in/opensearch.xml"></atom:link><pubDate>Fri, 23 Oct 2026 22:04:21 GMT</pubDate><lastBuildDate>Fri, 23 Oct 2026 22:04:21 GMT</lastBuildDate><item><guid isPermaLink="true">https://teletype.in/@termuxq/dV9gFx2DkqO</guid><link>https://teletype.in/@termuxq/dV9gFx2DkqO?utm_source=teletype&amp;utm_medium=feed_rss&amp;utm_campaign=termuxq</link><comments>https://teletype.in/@termuxq/dV9gFx2DkqO?utm_source=teletype&amp;utm_medium=feed_rss&amp;utm_campaign=termuxq#comments</comments><dc:creator>termuxq</dc:creator><title>Необычные скрипты на термукс</title><pubDate>Tue, 28 Jan 2025 15:01:34 GMT</pubDate><description><![CDATA[Скрипт для автоматической смены обоев
Использование API для скачивания случайных обоев и их установки на устройство:]]></description><content:encoded><![CDATA[
  <p id="W7nq"><strong>Скрипт для автоматической смены обоев<br />Использование API для скачивания случайных обоев и их установки на устройство:</strong></p>
  <p id="y8b1">Сперва даем доступ к файлам устройства и устанавливаем api</p>
  <pre id="1qFD" data-lang="shell">termux-setup-storage
pkg install termux-api</pre>
  <p id="ChOH">Сам скрипт:</p>
  <pre id="JGRI" data-lang="bash">wget -O ~/wallpaper.jpg &quot;https://picsum.photos/1080/1920&quot;
termux-wallpaper -f ~/wallpaper.jpg</pre>
  <p id="CYT8"></p>
  <p id="owcq"><strong>Умный будильник<br />Скрипт, который будет воспроизводить музыку, если погода утром хорошая:</strong></p>
  <pre id="rzdF" data-lang="bash">#!/bin/bash
smart_alarm() {
    WEATHER=$(curl -s &quot;http://wttr.in/?format=%C&quot;)
    if [[ &quot;$WEATHER&quot; =~ &quot;Clear&quot; || &quot;$WEATHER&quot; =~ &quot;Переменная облачность&quot; ]]; then
        termux-media-player play /path/to/music.mp3
    else
        termux-tts-speak &quot;Доброе утро! Погода сегодня отличная. $WEATHER. Хорошего дня!&quot;
    fi
}</pre>
  <p id="opGF"></p>
  <p id="E03q"><strong>Создание резервных копий в облако</strong></p>
  <pre id="UmyU" data-lang="bash">#!/bin/bash
backup_to_cloud() {
    BACKUP_FILE=&quot;~/backup_$(date +%F).tar.gz&quot;
    tar -czf &quot;$BACKUP_FILE&quot; /important/files
    termux-ftp-upload -h ftp://your_ftp_server -u username -p password &quot;$BACKUP_FILE&quot;
}</pre>
  <p id="SKLl"></p>
  <p id="3uN3"><strong>Интерактивный помощник<br />Скрипт, который принимает голосовые команды и выполняет соответствующие действия:</strong></p>
  <pre id="cp5B" data-lang="bash">#!/bin/bash
interactive_assistant() {
    termux-tts-speak &quot;Чем я могу вам помочь?&quot;
    INPUT=$(termux-speech-to-text)
    case &quot;$INPUT&quot; in
        &quot;проверить email&quot;)
            termux-notification -t &quot;Email&quot; -c &quot;У вас 5 новых электронных писем.&quot;
            ;;
        &quot;воспроизводить музыку&quot;)
            termux-media-player play /path/to/music.mp3
            ;;
        &quot;обновление погоды&quot;)
            WEATHER=$(curl -s &quot;http://wttr.in/?format=%C+%t&quot;)
            termux-tts-speak &quot;Текущая погода такова $WEATHER&quot;
            ;;
        *)
            termux-tts-speak &quot;Извините, я этого не понял.&quot;
            ;;
    esac
}</pre>
  <p id="o7or"></p>
  <p id="l3jI"><strong>Скрипт для мониторинга производительности устройства<br />Постоянное отслеживание температуры процессора и уведомление, если она превышает определенный порог:</strong></p>
  <pre id="IUFp" data-lang="bash">#!/bin/bash
monitor_cpu_temperature() {
    while true; do
        TEMP=$(cat /sys/class/thermal/thermal_zone0/temp)
        TEMP_C=$((TEMP / 1000))
        if [[ $TEMP_C -gt 70 ]]; then
            termux-notification -t &quot;Warning&quot; -c &quot;CPU Temperature is $TEMP_C°C&quot;
        fi
        sleep 60
    done
}</pre>
  <p id="F64G"></p>
  <p id="xjbC"><strong>Мини-чат-бот для общения<br />Создание простого чат-бота для ответов на вопросы:</strong></p>
  <pre id="q0I9" data-lang="bash">#!/bin/bash
chatbot() {
    termux-tts-speak &quot;Привет! Спрашивай меня о чем угодно.&quot;
    while true; do
        INPUT=$(termux-speech-to-text)
        case &quot;$INPUT&quot; in
            &quot;who are you&quot;)
                termux-tts-speak &quot;Я ваш ассистент по Термуксу.&quot;
                ;;
            &quot;what time is it&quot;)
                termux-tts-speak &quot;Текущее время равно $(date +%T).&quot;
                ;;
            &quot;exit&quot;)
                termux-tts-speak &quot;До свидания!&quot;
                break
                ;;
            *)
                termux-tts-speak &quot;Я не уверен, как на это ответить.&quot;
                ;;
        esac
    done</pre>
  <p id="Ks9d"></p>
  <p id="Zhxl"><strong>Выбор функции</strong></p>
  <pre id="feww" data-lang="bash">#!/bin/bash
case &quot;$1&quot; in
    wallpaper) change_wallpaper ;;
    alarm) smart_alarm ;;
    backup) backup_to_cloud ;;
    assistant) interactive_assistant ;;
    monitor) monitor_cpu_temperature ;;
    chatbot) chatbot ;;
    *) echo &quot;Usage: $0 {wallpaper|alarm|backup|assistant|monitor|chatbot}&quot; ;;
esac</pre>
  <p id="U6Nl"></p>
  <p id="jCpQ">Как запустить скрипты в Termux</p>
  <p id="zZr1"><strong>Открываем Termux</strong><br />Если Termux не установлен, скачайте его с <a href="true">F-Droid</a>.</p>
  <p id="KcsA"><strong>Создаём файл со скриптом</strong><br />Введите команду:</p>
  <pre id="hymG" data-lang="bash">nano termux_script.sh</pre>
  <p id="DBMS">Затем вставьте в редактор весь код.</p>
  <p id="zSfr"><strong>Сохраняем и выходим</strong></p>
  <ul id="wIUM">
    <li id="qPh9">Нажмите <code>CTRL + X</code>, затем <code>Y</code> и <code>Enter</code>.</li>
  </ul>
  <p id="YQVW">Делаем скрипт исполняемым</p>
  <pre id="gOX8" data-lang="bash">chmod +x termux_script.sh</pre>
  <p id="68Ra"><strong>Запускаем скрипт с нужной функцией</strong><br />Например:</p>
  <pre id="aAtD" data-lang="bash">./termux_script.sh alarm       # Умный будильник
./termux_script.sh backup      # Резервное копирование
./termux_script.sh assistant   # Голосовой помощник
./termux_script.sh monitor     # Мониторинг CPU
./termux_script.sh chatbot     # Чат-бот</pre>
  <h3 id="vbah"><strong>Дополнительно</strong></h3>
  <ul id="C4eO">
    <li id="dJ9J">Если появляется ошибка <code>permission denied</code>, введите:</li>
  </ul>
  <pre id="BNNH" data-lang="bash">termux-setup-storage
chmod +x termux_script.sh</pre>
  <p id="PgEG">Готово! Теперь у вас автоматизированный Termux 😎🚀</p>

]]></content:encoded></item></channel></rss>