Skip to content

Commit 31d5cfb

Browse files
committed
Update helpers.
1 parent df4abd8 commit 31d5cfb

File tree

6 files changed

+15
-10
lines changed

6 files changed

+15
-10
lines changed

Makefile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,22 +12,26 @@ default: help
1212
include tools/Makefile
1313

1414

15-
#version := $(shell sh -c "egrep -oe '__version__\s+=\s+(.*)' ./pyprometheus/__init__.py | sed 's/ //g' | sed \"s/'//g\" | sed 's/__version__=//g'")
15+
version := $(shell sh -c "egrep -oe '__version__\s+=\s+(.*)' ./pyprometheus/__init__.py | sed 's/ //g' | sed \"s/'//g\" | sed 's/__version__=//g'")
1616

17-
version := $(shell sh -c "$(DOCKER_RUN_COMMAND) 'python setup.py --version'")
17+
#version := $(shell sh -c "$(DOCKER_RUN_COMMAND) 'python setup.py --version'")
1818
clean-pyc:
1919
find . -name '*.pyc' -exec rm -f {} +
2020
find . -name '*.pyo' -exec rm -f {} +
2121
find . -name '*~' -exec rm -f {} +
22+
find . -name "__pycache__" -exec rm -rf {} +
2223

2324
help:
2425
@echo "Available commands:"
2526
@sed -n '/^[a-zA-Z0-9_.]*:/s/:.*//p' <Makefile | sort
2627

2728

29+
release:
30+
git tag -f v$(version) && git push origin v$(version)
31+
2832
publish: clean-pyc
2933
@echo "Create release $(version) and upload to pypi"
30-
git tag -f v$(version) && git push --tags
34+
3135
$(DOCKER_RUN_COMMAND) "python setup.py sdist bdist_wheel"
3236
$(DOCKER_RUN_COMMAND) 'for d in dist/* ; do twine register "$$d"; done;'
3337
$(DOCKER_RUN_COMMAND) "twine upload dist/*"

pyprometheus/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
__license__ = "BSD, see LICENSE for more details"
2020

21-
__version__ = '0.0.1'
21+
__version__ = '0.0.2'
2222

2323
__version_info__ = list(map(int, __version__.split('.')))
2424

pyprometheus/registry.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
"""
1313

1414

15+
1516
class BaseRegistry(object):
1617
"""Link with metrics collectors
1718
"""

setup.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,8 @@
2424
version = str(ast.literal_eval(_version_re.search(
2525
f.read().decode('utf-8')).groups()[0]))
2626

27-
2827
install_require = []
29-
tests_require = [x.strip() for x in open("tests_requirements.txt").readlines() if x.strip()]
28+
tests_require = [x.strip() for x in open("tests_requirements.txt").readlines() if (x.strip() and not x.strip().startswith('#'))]
3029

3130

3231
def read_description():
@@ -60,7 +59,7 @@ def run_tests(self):
6059
author='Alexandr Lispython',
6160
author_email='[email protected]',
6261
url='https://github.com/Lispython/pyprometheus',
63-
description='Prometheus python client (unofficial)',
62+
description='Prometheus python client and instrumentation library',
6463
long_description=read_description(),
6564
packages=find_packages(exclude=("tests", "tests.*",)),
6665
zip_safe=False,

tools/Dockerfile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,15 +24,16 @@ RUN echo 'eval "$(pyenv init -)"' >> ~/.bash_profile
2424

2525
RUN exec $SHELL
2626

27-
RUN pyenv install 3.2 && \
27+
RUN pyenv install 2.7 && \
28+
pyenv install 3.2 && \
2829
pyenv install 3.3.0 && \
2930
pyenv install 3.4.0 && \
3031
pyenv install 3.5.0 && \
3132
pyenv install 3.6.0 && \
3233
pyenv install 3.7-dev && \
3334
pyenv install pypy-4.0.1
3435

35-
RUN pyenv local 3.2 3.3.0 3.4.0 3.5.0 3.6.0 3.7-dev pypy-4.0.1
36+
# RUN pyenv local 2.7 3.2 3.3.0 3.4.0 3.5.0 3.6.0 3.7-dev pypy-4.0.1
3637

3738
RUN pip install -U pip setuptools wheel==0.30.0a0 pyparsing==2.1.10 twine
3839
RUN pip install -U plop gprof2dot ipython

tox.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@ envlist = py27#, py33, py34, py35
1010
deps = -rtests_requirements.txt
1111

1212
commands =
13-
pyenv local
13+
pyenv local 2.7 3.2 3.3.0 3.4.0 3.5.0 3.6.0 3.7-dev pypy-4.0.1
1414
#pip install -e .[tests]
1515
uwsgi --pyrun setup.py --pyargv test --sharedarea=100 --enable-threads

0 commit comments

Comments
 (0)