Skip to main content
Join the official 2019 Python Developers SurveyStart the survey!

Converts Greek beta code to Greek characters and vice versa

Project description

Beta Code Converter for Python

Overview

Converts Greek beta code to Greek characters and vice versa.

Installation

pip install beta_code

Usage

import beta_code

beta_code.greek_to_beta_code('χαῖρε ὦ κόσμε')
# => 'xai=re w)= ko/sme'

beta_code.beta_code_to_greek('mh=nin a)/eide qea\\ *phlhi+a/dew *)axilh=os')
# => 'μῆνιν ἄειδε θεὰ Πηληϊάδεω Ἀχιλῆος'

Tests

python -m unittest tests/test_beta_code.py

In Python 2

cd tests/ && python -m unittest test_beta_code

Updating JSON

git subtree pull --prefix beta_code/vendor/beta-code-json/ https://github.com/zfletch/beta-code-json master --squash

In the case of a merge conflict:

git checkout --theirs vendor/beta-code-json/
git add vendor/beta-code-json
git commit

Publishing

  • Install dependencies:
python3 -m pip install --user --upgrade setuptools wheel
python3 -m pip install --user --upgrade twine
  • Bump version in setup.py
  • Commit and push to GitHub
  • On GitHub, create a new release
  • Run python3 setup.py sdist bdist_wheel
  • Run twine upload dist/*

Notes

For the mappings between beta code and Unicode, see https://github.com/zfletch/beta-code-json.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for beta-code, version 0.0.4
Filename, size File type Python version Upload date Hashes
Filename, size beta_code-0.0.4-py3-none-any.whl (8.1 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size beta_code-0.0.4.tar.gz (6.7 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page