From c0e85b7e33a4bc21ac3a46a2ab69fd96bad85c5d Mon Sep 17 00:00:00 2001 From: HitBlast Date: Sun, 31 Mar 2024 21:57:48 +0600 Subject: [PATCH] added CLI docs and removed `tobijoy` (bijoy kinda sucks) --- README.md | 13 +++++++++++++ avro/cli.py | 6 ------ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 3d2cdf3..f8696a3 100644 --- a/README.md +++ b/README.md @@ -83,6 +83,19 @@ Finally, you can reverse unicode Bengali to English as well (newly added). reversed_text = avro.reverse('আমার সোনার বাংলা।') ``` +--- + +or, you can use the command line interface (CLI) to interact with the package: + +```bash +# Parsing some text. +$ avro parse "tumi onek bhalO!" +$ avro parse --bijoy "amio kharap na, taina?" # (bijoy keyboard format) + +# Reversing. +$ avro reverse "তাই তো!" +``` +
## 🛠️ Contributing diff --git a/avro/cli.py b/avro/cli.py index 04e0c2c..14ca79d 100644 --- a/avro/cli.py +++ b/avro/cli.py @@ -29,12 +29,6 @@ def cli(): def _parse(text: str, bijoy: bool = False): click.echo((avro.parse(text) if not bijoy else avro.parse(text, bijoy=True))) - # usage: avro tobijoy - @cli.command('tobijoy', help='Convert a given text to Bijoy Keyboard format.') - @click.argument('text') - def _tobijoy(text: str): - click.echo(avro.to_bijoy(text)) - # usage: avro reverse @cli.command('reverse', help='Reverse a given text to English.') @click.argument('text')