Metadata-Version: 2.4
Name: pybitchat
Version: 0.1.2
Summary: A Python implementation of the BitChat decentralized, peer-to-peer, encrypted chat application over BLE.
Project-URL: Homepage, https://github.com/o-murphy/py-bitchat
Project-URL: Bug Reports, https://github.com/o-murphy/pybitchat/issues
Project-URL: Source, https://github.com/o-murphy/pybitchat
Author: Kağan IŞILDAK, Dmytro Yaroshenko
License-File: LICENSE
Keywords: BLE,BLE-mesh,IRC-vibes,bitchat,chat-application,p2p-chat
Classifier: Intended Audience :: Developers
Classifier: Natural Language :: English
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.9
Requires-Dist: aioconsole>=0.8.1
Requires-Dist: bleak>=0.22.3
Requires-Dist: cryptography>=44.0.0
Requires-Dist: lz4>=4.3.3
Requires-Dist: pybloom-live>=4.0.0
Description-Content-Type: text/markdown

# BitChat Python

A Python implementation of the BitChat decentralized, peer-to-peer, encrypted chat application over BLE.

*This project is a fork of [bitchat-python](https://github.com/kaganisildak/bitchat-python). This fork contains improvements that possibly not yet merged to original project.*

*This project is a rewrite of the [original Rust-based `bitchat-terminal`](https://github.com/ShilohEye/bitchat-terminal).*

## Table of contents
* [Installation](#installation)
* [Usage](#usage)
  * [Simple start](#simple-start)
  * [CLI startup options](#cli-startup-args)
  * [BitChat Commands](#bitchat-commands)
* [Clone, Develop and Build](#clone-develop-and-build)
  * [Setup environment](#clone-and-setup-editable-environment-using-uv)
  * [Build](#build-sdist-and-wheel)

## Installation
With pip
```shell
pip install pybitchat
```

With [`uv` package and project manager](https://docs.astral.sh/uv/)
```Shell
uv tool install pybitchat
```

With [`pipx` standalone python apps panager](https://github.com/pypa/pipx)
```Shell
pipx install pybitchat
```


## Usage

### Simple start
Installed with `pip`, `uv tool`, `pipx` 
```Shell
bitchat-python
```

With `uvx` command
> [!NOTE]
> This will only work once the project is published to the PyPI index.
```Shell
uvx bitchat-python
```

### CLI startup options
```shell
  -h, --help     show this help message and exit
  -d, --debug    enable BASIC debug (connection info)
  -v, --verbose  enable FULL debug (verbose output)
  -u, --usage    show usage info
  -V, --version  show program`s version number and exit
  --log [LOG]    log file path. If no path is provided, logs to 'bitchat.log'. If --log is omitted, no logging occurs.
```

### BitChat Commands

This section details the various commands available within BitChat.
```shell
General Commands

* `/help`               : Show this help menu
* `/h`                  : Alias for /help
* `/me`                 : Get your Nickname and peer_id
* `/name <name>`        : Change your nickname
* `/status`             : Show connection info
* `/clear`              : Clear the screen
* `/exit`               : Quit BitChat
*  `/q`                 : Alias for /exit


Navigation Commands

* `1-9`                 : Quick switch to conversation
* `/list`               : Show all conversations
* `/switch`             : Interactive conversation switcher
* `/public`             : Go to public chat


Messaging Commands

(Type normally to send in current mode)

* `/dm <name>`          : Start private conversation
* `/dm <name> <msg>`    : Send quick private message
* `/reply`              : Reply to last private message


Channel Commands

* `/j #channel`               : Join or create a channel
* `/j #channel <password>`    : Join with password
* `/leave`                    : Leave current channel
* `/pass <pwd>`               : Set channel password (owner only)
* `/transfer @user`           : Transfer ownership (owner only)


Discovery Commands

* `/channels`                 : List all discovered channels
* `/online`                   : Show who`s online
* `/w`                        : Alias for /online


Privacy & Security Commands

* `/block @user`       : Block a user
* `/block`             : List blocked users
* `/unblock @user`     : Unblock a user
```


## Clone, Develop and Build
> [!TIP]  
> [`uv` package and project manager](https://docs.astral.sh/uv/) usage recommended for this step

### Clone and setup editable environment using `uv`
```Shell
git clone https://github.com/o-murphy/pybitchat.git
cd bitchat-python
uv sync --dev
.venv/bin/activate
```

### Type checking with
```Shell
uv run mypy 
```

### Linting and Formatting
Lint
```Shell
uv run ruff check
```

Format
```Shell
uv run ruff format
```

### Build sdist and wheel
```Shell
uv build
```




[//]: # (Old README.md content)
[//]: # (pip install bleak>=0.22.3 cryptography>=44.0.0 lz4>=4.3.3 aioconsole>=0.8.1 pybloom-live>=4.0.0)