feat: v2.0 — card UI, AI agents (Claude/DeepSeek), collapsible commands

Major update:
- Card-based session layout with colored group indicators
- AI agent: Claude API, DeepSeek API, local keyword search
- Collapsible command panel — more space for agent
- macOS build script (build_mac.sh)
- Updated README with Windows/macOS install instructions
- Config persistence in pca_config.json

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Андрей Бобырев
2026-05-20 22:49:02 +03:00
parent 466239a879
commit f6753fa2f6
5 changed files with 889 additions and 400 deletions

View File

@@ -1 +1,84 @@
# ssh-manage
# PCA SSH — Private Control Administration
SSH-клиент с карточным интерфейсом, AI-агентами и автосохранением сессий.
## Возможности
- **Карточный интерфейс** — группы с цветными индикаторами, красивые карточки подключений
- **AI-агент** — подсказки команд через Claude API, DeepSeek API или локальную базу
- **400+ команд** — для Linux (Ubuntu/Debian/CentOS) и Keenetic (NDMS CLI)
- **Группы сессий** — организация подключений по группам с drag & drop
- **Автосохранение** — все подключения сохраняются автоматически
- **Вкладки** — несколько SSH-сессий одновременно
- **Скрываемая панель команд** — больше места для AI-агента
- **Тёмная тема** — Catppuccin Mocha
## Установка
### Windows — быстрый запуск (без сборки)
```
1. Установи Python 3.10+ с https://python.org/downloads/
(отметь "Add Python to PATH")
2. Скачай репозиторий
3. Запусти install.bat
```
### Windows — собрать .exe
```
1. Установи Python 3.10+
2. Запусти build.bat
3. Готовый файл: dist\PCA_SSH.exe
```
Или полная установка с иконкой и копированием на рабочий стол:
```
powershell -ExecutionPolicy Bypass -File full_install.ps1
```
### macOS — быстрый запуск
```bash
# Установи Python если нет
brew install python3
# Установи зависимости
pip3 install paramiko
# Запусти
python3 ssh_manager.py
```
### macOS — собрать .app
```bash
chmod +x build_mac.sh
./build_mac.sh
# Готовый файл: dist/PCA_SSH
```
## AI-агент
Встроенный агент помогает подобрать команды. Три режима:
| Провайдер | Описание | API-ключ |
|-----------|----------|----------|
| Локальный | База из 400+ команд, поиск по ключевым словам | Не нужен |
| Claude | Умный ассистент от Anthropic | [console.anthropic.com](https://console.anthropic.com) |
| DeepSeek | Альтернативный AI-провайдер | [platform.deepseek.com](https://platform.deepseek.com) |
Настройка: кнопка ⚙ в панели агента.
## Файлы
| Файл | Описание |
|------|----------|
| `sessions.json` | Сохранённые SSH-сессии (рядом с .exe) |
| `pca_config.json` | Настройки AI-агента и интерфейса |
## Ссылки
- [GitHub](https://github.com/nickolay-frolov)
- [Telegram](https://t.me/lot_andrey)
- [Boosty](https://boosty.to/lot_andrey)

View File

@@ -1,23 +1,32 @@
@echo off
echo === KU SSH Manager — Build ===
echo === PCA SSH v2.0 — Build for Windows ===
where python >nul 2>&1
if errorlevel 1 (
echo Python not found! Install from https://python.org/downloads/
echo Check "Add Python to PATH" during install!
pause
exit /b 1
)
echo Installing dependencies...
pip install paramiko pyinstaller
pip install paramiko pillow pyinstaller
echo Building .exe...
pyinstaller --onefile --noconsole --name "KU SSH Manager" ^
--add-data "sessions.json;." ^
--icon NONE ^
ssh_manager.py
echo Generating icon...
python gen_icon.py
echo Building PCA_SSH.exe...
if exist pca_ssh.ico (
pyinstaller --onefile --noconsole --name "PCA_SSH" --icon=pca_ssh.ico ssh_manager.py
) else (
pyinstaller --onefile --noconsole --name "PCA_SSH" ssh_manager.py
)
echo.
echo Done! EXE: dist\KU SSH Manager.exe
echo Copy it anywhere — sessions.json saves next to .exe
if exist dist\PCA_SSH.exe (
echo DONE! EXE: dist\PCA_SSH.exe
echo Copy it anywhere — sessions.json and pca_config.json save next to .exe
) else (
echo BUILD FAILED
)
pause

32
build_mac.sh Executable file
View File

@@ -0,0 +1,32 @@
#!/bin/bash
echo "=== PCA SSH v2.0 — Build for macOS ==="
# Check Python
if ! command -v python3 &>/dev/null; then
echo "Python3 not found!"
echo "Install: brew install python3"
echo "Or: https://python.org/downloads/"
exit 1
fi
echo "Installing dependencies..."
pip3 install paramiko pillow pyinstaller
echo "Generating icon..."
python3 gen_icon.py
echo "Building PCA_SSH.app..."
if [ -f pca_ssh.icns ]; then
python3 -m PyInstaller --onefile --windowed --name "PCA_SSH" --icon=pca_ssh.icns ssh_manager.py
else
python3 -m PyInstaller --onefile --windowed --name "PCA_SSH" ssh_manager.py
fi
if [ -f dist/PCA_SSH ]; then
echo ""
echo "DONE! App: dist/PCA_SSH"
echo "Copy to /Applications or run directly"
echo "sessions.json and pca_config.json save next to executable"
else
echo "BUILD FAILED"
fi

View File

@@ -1,5 +1,5 @@
@echo off
echo === KU SSH Manager — Install and Run ===
echo === PCA SSH v2.0 — Install and Run ===
where python >nul 2>&1
if errorlevel 1 (
@@ -13,5 +13,5 @@ if errorlevel 1 (
echo Installing dependencies...
pip install paramiko
echo Starting SSH Manager...
echo Starting PCA SSH...
python ssh_manager.py

File diff suppressed because it is too large Load Diff