Skip to content

Commit

Permalink
Revert "Transform package management"
Browse files Browse the repository at this point in the history
  • Loading branch information
nficano committed Feb 2, 2024
1 parent ad02e1d commit 8a5765c
Show file tree
Hide file tree
Showing 10 changed files with 2,801 additions and 53 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:

strategy:
matrix:
python: [3.7, 3.8, 3.9, "3.10", "3.11"]
python: [3.7, 3.8, 3.9, "3.10"]

steps:
- name: Checkout repo
Expand Down
2 changes: 2 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
include README.md LICENSE
recursive-include tests *.py
35 changes: 16 additions & 19 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,30 +1,27 @@
deploy-patch: clean version-patch git-push-on-deploy upload clean
deploy-patch: clean bumpversion-patch upload clean

deploy-minor: clean version-minor git-push-on-deploy upload clean
deploy-minor: clean bumpversion-minor upload clean

deploy-major: clean version-major git-push-on-deploy upload clean
deploy-major: clean bumpversion-major upload clean

# Version prior to update
VERSION := ${shell poetry version -s}

version-patch:
poetry version patch

version-minor:
poetry version minor
bumpversion-patch:
bumpversion patch
git push
git push --tags

version-major:
poetry version major
bumpversion-minor:
bumpversion minor
git push
git push --tags

git-push-on-deploy:
git commit -m 'Bump version: $(VERSION) → $(shell poetry version -s)' pyproject.toml
bumpversion-major:
bumpversion major
git push
git tag v${shell poetry version -s}
git push --tags

upload:
poetry build
poetry publish
python setup.py sdist bdist_wheel
twine upload dist/*

help:
@echo "clean - remove all build, test, coverage and Python artifacts"
Expand Down Expand Up @@ -61,4 +58,4 @@ clean-pyc:
find . -name '__pycache__' -exec rm -fr {} +

install: clean
poetry install
python setup.py install
1,047 changes: 1,047 additions & 0 deletions Pipfile.lock

Large diffs are not rendered by default.

26 changes: 14 additions & 12 deletions humps/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,25 @@
"""
Underscore-to-camelCase converter (and vice versa) for strings and dict keys in Python.
"""
import sys

from humps.main import (camelize, decamelize, dekebabize, depascalize,
is_camelcase, is_kebabcase, is_pascalcase,
is_snakecase, kebabize, pascalize)

if sys.version_info >= (3, 8): # pragma: no cover
from importlib.metadata import metadata as _importlib_metadata
else:
from importlib_metadata import metadata as _importlib_metadata # pragma: no cover

__title__ = "pyhumps"
__version__ = _importlib_metadata(__title__)["version"]
__version__ = "3.8.0"
__author__ = "Nick Ficano"
__license__ = "Unlicense License"
__copyright__ = "Copyright 2019 Nick Ficano"

from humps.main import (
camelize,
decamelize,
kebabize,
dekebabize,
pascalize,
depascalize,
is_camelcase,
is_kebabcase,
is_pascalcase,
is_snakecase,
)

__all__ = (
"camelize",
"decamelize",
Expand Down
2 changes: 1 addition & 1 deletion humps/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"""
import re

from collections.abc import Mapping # pylint: disable-msg=E0611
from collections.abc import Mapping

ACRONYM_RE = re.compile(r"([A-Z\d]+)(?=[A-Z\d]|$)")
PASCAL_RE = re.compile(r"([^\-_]+)")
Expand Down
Loading

0 comments on commit 8a5765c

Please sign in to comment.