Skip to main content

Localizable.strings reader and writer

Project description

Localizablestrings

A simple reader and writer for Localizable.strings files as used by Xcode projects.

Installation

pip install localizablestrings

Usage

from localizablestrings import StringsFile, Translation

sf = StringsFile('/path/to/Localizable.strings')

for translation in sf:
    print(f'Key = {translation.key}\nValue = {translation.value}\nComment = {translation.comment}')

if sf.get_translation('spam') is None:
    new_translation = Translation(key='spam', value='eggs', comment='Needs more bacon')
    sf.add_translation(new_translation)

sf.write()

Project details


Download files

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

Source Distribution

localizablestrings-1.2.tar.gz (1.9 kB view details)

Uploaded Source

Built Distribution

localizablestrings-1.2-py3-none-any.whl (3.2 kB view details)

Uploaded Python 3

File details

Details for the file localizablestrings-1.2.tar.gz.

File metadata

  • Download URL: localizablestrings-1.2.tar.gz
  • Upload date:
  • Size: 1.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.0

File hashes

Hashes for localizablestrings-1.2.tar.gz
Algorithm Hash digest
SHA256 37ab16d94c65b5d9a9dedd36b9b0be31884213b18f418a46a0f3ebfb4b6882cd
MD5 48b08617fe77ad260e2c2cea692be39e
BLAKE2b-256 f15ef6280fd1367d962dbd7069d65a2380b2031cc1b898f20ec50b351f1b8276

See more details on using hashes here.

File details

Details for the file localizablestrings-1.2-py3-none-any.whl.

File metadata

  • Download URL: localizablestrings-1.2-py3-none-any.whl
  • Upload date:
  • Size: 3.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.0

File hashes

Hashes for localizablestrings-1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 d82ebca969b0033432d7766b46559a854f8040b7ea19d6461ba68f86df467998
MD5 77a4ce1aadd20c4e78878461bf56a075
BLAKE2b-256 8cff2d0655b9e994121e150925291a6c7e87282f5384f7282195216d670fb70f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page