Skip to main content

rebrand

Refactor your software using programming language independent string replacement.

Helps by renaming directories, filenames and file contents in a case-preserving manner.

rebrand demo

How does it work

Imagine we want to rename a library called SomeThing to AnotherName.

It will first normalize "SomeThing" to ["some", "thing"] and "AnotherName" to ["another", "name"], and build patterns on this.

Then, when matching and replacing, it will memorize the casing pattern and separator on e.g. "Some-thing" to replace it with the same convention, like so: "Another-name".

This works for:

  • filenames
  • directories
  • file contents

Binaries are just copied, and warnings are currently shown for png and jpg files containing logo or icon.

Installation

pip install rebrand

Usage

rebrand <OLD> <NEW> <LOCATION> (optional: <DESTINATION>)
# e.g. rebrand ancient modern .

TODO:

  • Implement radically faster matching
  • More options (such as disabling image warnings, verbosity, ignore patterns)
  • Switch from fire back to argparse

Download files

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

Source Distribution

rebrand-0.0.12.tar.gz (4.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

rebrand-0.0.12-py2.py3-none-any.whl (5.4 kB view details)

Uploaded Python 2Python 3

File details

Details for the file rebrand-0.0.12.tar.gz.

File metadata

  • Download URL: rebrand-0.0.12.tar.gz
  • Upload date:
  • Size: 4.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.18.4 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.7.0a0

File hashes

Hashes for rebrand-0.0.12.tar.gz
Algorithm Hash digest
SHA256 4b9884796f1962ca10ba0e18ac0394efee9d03588c4d7315fc3ef6cdd2721f7b
MD5 8cef7d54051c04001230d54d18a39bfe
BLAKE2b-256 e9008008fd2e6b2066589059584ccd584ea625dd593e5d841e79aad135d409f5

See more details on using hashes here.

File details

Details for the file rebrand-0.0.12-py2.py3-none-any.whl.

File metadata

  • Download URL: rebrand-0.0.12-py2.py3-none-any.whl
  • Upload date:
  • Size: 5.4 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.18.4 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.7.0a0

File hashes

Hashes for rebrand-0.0.12-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 60d7455600f35927d739e14e488172cb4e22fd9f964593d2ed058c98975fda49
MD5 3b5c0225537be815a574c692a93deef6
BLAKE2b-256 595bc47f3df51cfdb1e27048f107ee6e64ed4f19645dae2edd8104980f4996f7

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.0.12 This release

2 files

0.0.6

2 files

0.0.4

2 files

0.0.1

2 files

Supported by

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