Skip to content

Commit

Permalink
update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
nsheff committed Jan 9, 2025
1 parent f008db5 commit 33d4851
Showing 1 changed file with 12 additions and 24 deletions.
36 changes: 12 additions & 24 deletions bindings/python/README.md
Original file line number Diff line number Diff line change
@@ -1,35 +1,23 @@
# gtars

This is a python wrapper around the `gtars` crate. It provides an easy interface for using `gtars` in python. It is currently in early development, and as such, it does not have a lot of functionality yet, but new tools are being worked on right now.
This is a Python package that wraps the `gtars` crate so you can call gtars code from Python.

## Installation
Documentation for Python bindings is hosted at: https://docs.bedbase.org/gtars/

You can get `gtars` from PyPI:
## Brief instructions

```bash
pip install gtars
```

## Usage

Import the package, and use the tools:
```python
import gtars as gt

gt.prune_universe(...)
```
## Developer docs

To build for development:
To install the development version, you'll have to build it locally. Build Python bindings like this:

```bash
```console
cd bindings/python
maturin build --release
maturin build --interpreter 3.11 --release
```

Then install the local wheel that was just built:

```
version=`grep '^version =' Cargo.toml | cut -d '"' -f 2`
pip install --force-reinstall target/wheels/gtars-${version}-cp312-cp312-manylinux_2_38_x86_64.whl
```
```console
gtars_version=`grep '^version =' Cargo.toml | cut -d '"' -f 2`
python_version=$(python --version | awk '{print $2}' | cut -d '.' -f1-2 | tr -d '.')
wheel_path=$(find target/wheels/gtars-${gtars_version}-cp${python_version}-cp${python_version}-*.whl)
pip install --force-reinstall ${wheel_path}
```

0 comments on commit 33d4851

Please sign in to comment.