Skip to content
Snippets Groups Projects
Commit 97cfa407 authored by Jan Mach's avatar Jan Mach
Browse files

Changed the setup.py script to include and use the actual package version...

Changed the setup.py script to include and use the actual package version directly from Python module in local directory.

This change really simplifies package versioning, because value of only one __version__ variable needs to be updated and it will be used as version identifier of generated Python packages (wheels). Previous commit, that introduced automated package documentation already
 used this approach.
parent 9ea07133
No related branches found
No related tags found
No related merge requests found
#!/usr/bin/python3
# -*- coding: utf-8 -*-
#-------------------------------------------------------------------------------
# This file is part of idea-format package (https://pypi.python.org/pypi/idea-format).
#
# Copyright (c) since 2016, CESNET, z. s. p. o.
# Authors: Pavel Kácha <pavel.kacha@cesnet.cz>
# Jan Mach <jan.mach@cesnet.cz>
# Author: Pavel Kácha <pavel.kacha@cesnet.cz>
# Use of this source is governed by an ISC license, see LICENSE file.
#-------------------------------------------------------------------------------
......@@ -11,23 +12,31 @@
# https://packaging.python.org/distributing/
# http://python-packaging-user-guide.readthedocs.io/distributing/
import sys
import os
# Always prefer setuptools over distutils
from setuptools import setup, find_packages
# To use a consistent encoding
from codecs import open
from os import path
#
# Import local version of typedcols library, so that we can insert correct version
# number into documentation.
#
sys.path.insert(0, os.path.abspath('.'))
import idea
here = path.abspath(path.dirname(__file__))
#-------------------------------------------------------------------------------
here = os.path.abspath(os.path.dirname(__file__))
# Get the long description from the README file
with open(path.join(here, 'README.rst'), encoding='utf-8') as f:
with open(os.path.join(here, 'README.rst'), encoding='utf-8') as f:
long_description = f.read()
setup(
name = 'idea-format',
#version = '0.1.8',
version = idea.__version__,
description = 'Python library for working with IDEA messages.',
long_description = long_description,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment