Skip to content

Commit

Permalink
Changed version to 1.6.0
Browse files Browse the repository at this point in the history
setup.py now reads version from silfont/__init__.py
  • Loading branch information
DavidRaymond committed Jul 25, 2022
1 parent fd82053 commit 10bbd30
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 7 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Changelog

## [1.5.1.dev0] - Placeholder for next release
## [1.6.0] - 2022-07-25 Maintenance Release - general updates

General updates over the last two years, adding new scripts and updating existing in response to new
needs or to adjust for changes to third-party software.

### Added

Expand All @@ -18,6 +21,7 @@

### Changed

Multiple changes!

### Removed

Expand Down
2 changes: 1 addition & 1 deletion lib/silfont/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
__url__ = 'http://github.com/silnrsi/pysilfont'
__copyright__ = 'Copyright (c) 2014-2022 SIL International (http://www.sil.org)'
__license__ = 'Released under the MIT License (http://opensource.org/licenses/MIT)'
__version__ = '1.5.1.dev0'
__version__ = '1.6.0'
16 changes: 11 additions & 5 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
__url__ = 'http://github.com/silnrsi/pysilfont'
__copyright__ = 'Copyright (c) 2014 SIL International (http://www.sil.org)'
__license__ = 'Released under the MIT License (http://opensource.org/licenses/MIT)'
__version__ = '1.5.1.dev0'

import sys, os, importlib

Expand All @@ -14,6 +13,15 @@
print("pysilfont requires setuptools - see installation notes in README.md")
sys.exit(1)

# Read version from __init__.py
version = None
here = os.path.abspath(os.path.dirname(__file__))
init = open(os.path.join(here, "lib", "silfont", "__init__.py"), 'r')
for line in init:
if line.startswith('__version__'):
version = line.split("'")[1]
if version is None: sys.exit("Failed to read __version__ from init.py")

if sys.version_info < (3,6): sys.exit('Sorry, Python < 3.6 is not supported')

warnings = []
Expand All @@ -24,9 +32,7 @@
except ImportError : warnings.append("- Some modules/scripts require the python %s package which is not currently installed" % m)

long_description = "A growing collection of font utilities mainly written in Python designed to help with various aspects of font design and production.\n"
long_description += "Developed and maintained by SIL International's by SIL International's WSTech department (formerly NRSI).\n"
long_description += "Some of these utilities make use of the FontForge Python module."

long_description += "Developed and maintained by SIL International's by SIL International's WSTech department (formerly NRSI)."

# Create entry_points console scripts entry
cscripts = []
Expand All @@ -36,7 +42,7 @@

setup(
name = 'pysilfont',
version = __version__,
version = version,
description = 'Python-based font utilities collection',
long_description = long_description,
maintainer = 'SIL International',
Expand Down

0 comments on commit 10bbd30

Please sign in to comment.