diff options
author | Daniil Baturin <daniil@baturin.org> | 2023-05-11 17:21:52 +0100 |
---|---|---|
committer | Daniil Baturin <daniil@baturin.org> | 2023-05-11 17:21:52 +0100 |
commit | c739eb23bb260ebb5ae595633c32a2956974a16a (patch) | |
tree | c7e59bc8f6fe3a32da52c99757d08b64b05cbc81 /python/vyos/util.py | |
parent | c3f957b9bfc7233fe08d4dd65b80abf92097c81b (diff) | |
download | vyos-1x-c739eb23bb260ebb5ae595633c32a2956974a16a.tar.gz vyos-1x-c739eb23bb260ebb5ae595633c32a2956974a16a.zip |
vyos.util: T5195: remove the unused camel case to snake case function
that was replaced with Humps in all sciprts
Diffstat (limited to 'python/vyos/util.py')
-rw-r--r-- | python/vyos/util.py | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/python/vyos/util.py b/python/vyos/util.py index 0593184cc..d5330db13 100644 --- a/python/vyos/util.py +++ b/python/vyos/util.py @@ -1146,13 +1146,6 @@ def sysctl_write(name, value): return True return False -# approach follows a discussion in: -# https://stackoverflow.com/questions/1175208/elegant-python-function-to-convert-camelcase-to-snake-case -def camel_to_snake_case(name: str) -> str: - pattern = r'\d+|[A-Z]?[a-z]+|\W|[A-Z]{2,}(?=[A-Z][a-z]|\d|\W|$)' - words = re.findall(pattern, name) - return '_'.join(map(str.lower, words)) - def load_as_module(name: str, path: str): import importlib.util |