docs: update CLI arguments to subcommands

ospab 2026-07-10 03:05:25 +03:00
parent 90810f25f7
commit f0363e5be2
5 changed files with 19 additions and 21 deletions

@ -8,11 +8,11 @@ Starting from version 0.3.1, OSTP uses a modular configuration system based on *
```bash ```bash
# Generate a default configuration file # Generate a default configuration file
./ostp --init server ./ostp init server
./ostp --init client ./ostp init client
# Validate a configuration without running # Validate a configuration without running
./ostp --check --config config.json ./ostp check --config config.json
``` ```
--- ---

@ -8,11 +8,11 @@
```bash ```bash
# Генерация базового конфига # Генерация базового конфига
./ostp --init server ./ostp init server
./ostp --init client ./ostp init client
# Проверка конфигурации на ошибки # Проверка конфигурации на ошибки
./ostp --check --config config.json ./ostp check --config config.json
``` ```
--- ---

@ -71,23 +71,21 @@ irm https://raw.githubusercontent.com/ospab/ostp/master/scripts/install.ps1 | ie
## Быстрый старт ## Быстрый старт
```bash ```bash
# Генерация конфига сервера # Базовая генерация конфигов
./ostp --init server ./ostp init server
./ostp init client
# Генерация конфига клиента # Проверить синтаксис конфига
./ostp --init client ./ostp check
# Проверка конфига
./ostp --check
# Запуск # Запуск
./ostp ./ostp run
# Подключение по ссылке # Подключение по ссылке
./ostp ostp://ACCESS_KEY@server.com:50000 ./ostp connect ostp://ACCESS_KEY@server.com:50000
# Генерация ключей # Сгенерировать 5 ключей доступа
./ostp --generate-key -c 5 ./ostp gk -n 5
``` ```
--- ---

@ -53,8 +53,8 @@ ostp://abc123456789@1.1.1.1:53/?type=dns&domain=t.yourdomain.com&pubkey=f1...4a#
The OSTP GUI and CLI support importing share links: The OSTP GUI and CLI support importing share links:
- **GUI**: Paste into the import field on the Settings screen. - **GUI**: Paste into the import field on the Settings screen.
- **CLI**: `ostp --import "ostp://key@host:port/..."` - **CLI**: `ostp import "ostp://key@host:port/..."`
- **Instant Launch**: `ostp --url "ostp://key@host:port/..."` (Creates a temporary config and runs it). - **Instant Launch**: `ostp connect "ostp://key@host:port/..."` (Creates a temporary config and runs it).
--- ---

@ -51,8 +51,8 @@ ostp://abc123456789@1.1.1.1:53/?type=dns&domain=t.yourdomain.com&pubkey=f1...4a#
## Импорт в клиент ## Импорт в клиент
- **GUI**: Вставьте ссылку в поле импорта на экране настроек. - **GUI**: Вставьте ссылку в поле импорта на экране настроек.
- **CLI**: `ostp --import "ostp://ключ@хост:порт/..."` - **CLI**: `ostp import "ostp://ключ@хост:порт/..."`
- **Быстрый запуск**: `ostp --url "ostp://ключ@хост:порт/..."` (создает временный конфиг и сразу запускает клиент). - **Быстрый запуск**: `ostp connect "ostp://ключ@хост:порт/..."` (создает временный конфиг и сразу запускает клиент).
--- ---