tombulled / case

String case conversion, identification and parsing
MIT License
0 stars 0 forks source link

case

String case conversion, identification, parsing and creation

Styles

Style Example
lower foo bar
upper FOO BAR
title Foo Bar
sentence Foo bar
snake foo_bar
helter Foo_Bar
macro FOO_BAR
kebab foo-bar
train Foo-Bar
cobol FOO-BAR
flat foobar
flush FOOBAR
pascal FooBar
camel fooBar
dot foo.bar
path foo/bar

Usage

>>> import case

Conversion

>>> case.snake('alphaBRAVOCharlie')
'alpha_bravo_charlie'

Identification

>>> case.identify('FooBar')
[Case(style='pascal')]