2
0
mirror of https://github.com/fork-maintainers/iceraven-browser synced 2024-11-03 23:15:31 +00:00
iceraven-browser/automation/taskcluster/lib/util.py
Mitchell Hentges 9a50f00054 [fenix] Updates Fenix taskcluster tasks to support beta release (https://github.com/mozilla-mobile/fenix/pull/1893)
* Updates Fenix taskcluster tasks to support beta release

* Throw error if -PversionName isn't set for release builds

* Uses beta secrets for beta

* Improves nightly and beta treeherder symbols
2019-05-06 19:09:29 +02:00

16 lines
504 B
Python

import re
def convert_camel_case_into_kebab_case(string):
# Inspired from https://stackoverflow.com/questions/1175208/elegant-python-function-to-convert-camelcase-to-snake-case # noqa: E501
first_pass = re.sub('(.)([A-Z][a-z]+)', r'\1-\2', string)
return re.sub('([a-z0-9])([A-Z])', r'\1-\2', first_pass).lower()
def lower_case_first_letter(string):
return '{}{}'.format(string[0].lower(), string[1:])
def upper_case_first_letter(string):
return string[0].upper() + string[1:]