Skip to content

Commit

Permalink
versioning done right
Browse files Browse the repository at this point in the history
  • Loading branch information
wroscoe committed Nov 4, 2018
1 parent 328273b commit 6890a7c
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 17 deletions.
3 changes: 2 additions & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
include donkeycar/templates/*
recursive-include donkeycar/parts/web_controller/templates/ *
include VERSION
recursive-include donkeycar/parts/web_controller/templates/ *
1 change: 0 additions & 1 deletion VERSION

This file was deleted.

13 changes: 6 additions & 7 deletions donkeycar/__init__.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
import os

# Print version being used.
package_path = os.path.dirname(os.path.dirname(__file__))
version_path = os.path.join(package_path, 'VERSION')
with open(version_path, 'r') as f:
version = f.read()
print('using donkey version: {} ...'.format(version))
import pkg_resources # part of setuptools
import sys

__version__ = pkg_resources.require("donkeycar")[0].version
print('using donkey version: {} ...'.format(__version__))



import sys
current_module = sys.modules[__name__]


Expand Down
9 changes: 1 addition & 8 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,12 @@

import os

# Print version being used.
package_path = os.path.dirname(__file__)
version_path = os.path.join(package_path, 'VERSION')
with open(version_path, 'r') as f:
version = f.read()


with open("README.md", "r") as fh:
long_description = fh.read()


setup(name='donkeycar',
version=version,
version='2.5.2',
description='Self driving library for python.',
long_description=long_description,
long_description_content_type="text/markdown",
Expand Down

0 comments on commit 6890a7c

Please sign in to comment.