Skip to main content

Converts PascalCase or snake_case strings to camelCase.

Project description

camelCasing Package

This package converts Pascal Case and snake_case strings into its camelCase equivalent.

Basic Use

Its functionality can be used in at least two ways:

(1) Individually:

# recode a single string
to_camel_case(s='TheQuickBrownFox', user_acronyms=None)

or (2) in list comprehensions:

# get camelCase replacements for an arbitrary dataframe
[to_camel_case(s=s, user_acronyms=None) for s in df.columns]

User Defined Acronyms

One of the tricky problems facing camel case text generation is the problem of acronyms. This package allows for user defined acronyms that the program should look for and account for when creating its camelCase equivalent.

Consider the following example:

s7 = 'UefiDbx_UefiDbxKeyStatus'
assert to_camel_case(s7, ['WMI', 'FRU', 'SKU', 'UEFI']) == 'UEFIDbxUEFIDbxKeyStatus', 'failed'

This functionality lets you have control over the acronyms that you want to keep and maintain.

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

camelcasing-0.0.1.tar.gz (3.6 kB view details)

Uploaded Source

Built Distribution

camelcasing-0.0.1-py3-none-any.whl (3.9 kB view details)

Uploaded Python 3

File details

Details for the file camelcasing-0.0.1.tar.gz.

File metadata

  • Download URL: camelcasing-0.0.1.tar.gz
  • Upload date:
  • Size: 3.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.12

File hashes

Hashes for camelcasing-0.0.1.tar.gz
Algorithm Hash digest
SHA256 f8d6442ede4f0bdb397792875b362095aab58b594fcf9242f70ef0e6282fc631
MD5 937403a4313d3440cb3e749f4bbda4f0
BLAKE2b-256 2a6e1c65a40e0360702458f7883a3e231c90a0fb725e37e279c61a87995790fd

See more details on using hashes here.

File details

Details for the file camelcasing-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: camelcasing-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.12

File hashes

Hashes for camelcasing-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 fa8087b620b579b1deb8342279227a58593c7dad44557cb4cd43eb9a3aed6a72
MD5 4f4ceb72ac10433db25cdf3070347bbb
BLAKE2b-256 c654aab073116b3b559dada1770c7cd0081ac25f766b463384692661b1ec36a4

See more details on using hashes here.

Supported by

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