ses-monitor/cli/README.md

52 lines
1.7 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# ses-test
CLI-утилита для пошагового тестирования YAML-сценариев SES.
## Установка
```bash
pip install "ses-test @ git+https://git.totmin.ru/en2zmax/ses-monitor.git#subdirectory=cli"
```
## Сборка исполняемого файла
Можно собрать `ses-test` в один бинарник (~11 MB), не требующий Python на целевой машине.
Сборка производится в чистом виртуальном окружении — чтобы в бинарник не попали лишние системные пакеты (numpy, pillow и др.):
```bash
# 1. Клонируем репозиторий
git clone https://git.totmin.ru/en2zmax/ses-monitor.git
cd ses-monitor
# 2. Чистое окружение
python -m venv /tmp/build
/tmp/build/bin/pip install ./cli pyinstaller
# 3. Сборка
/tmp/build/bin/pyinstaller --onefile --name ses-test \
--paths src/ \
--hidden-import ses_monitor.utils \
--strip \
--exclude-module tkinter \
--exclude-module turtle \
--exclude-module sqlite3 \
--exclude-module curses \
--exclude-module idlelib \
--exclude-module pydoc \
--exclude-module venv \
--exclude-module ensurepip \
--exclude-module unittest \
--exclude-module test \
--exclude-module multiprocessing \
src/ses_monitor/cli.py
```
Готовый бинарник: `dist/ses-test` (~11 MB, Linux) или `dist/ses-test.exe` (Windows — запустить те же команды на Windows).
Для сборки под другую ОС нужна эта ОС — PyInstaller не кросс-компилирует.
## Справка
Основная документация: [README.md](../README.md)