Skip to content

Commit

Permalink
Add version and fix setup.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Kentzo committed Dec 7, 2012
1 parent 93a702c commit 2c7038e
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 7 deletions.
2 changes: 2 additions & 0 deletions power/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ def on_time_remaining_change(self, power_management):
# PowerManagementObserver.register(Observer)
"""
__author__ = '[email protected]'
import pkg_resources
__version__ = pkg_resources.require('power')[0].version

from sys import platform
from power.common import *
Expand Down
6 changes: 4 additions & 2 deletions power/darwin.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,9 +138,11 @@
</function>
</signatures>"""

objc.parseBridgeSupport(IO_POWER_SOURCES_BRIDGESUPPORT,
objc.parseBridgeSupport(
IO_POWER_SOURCES_BRIDGESUPPORT,
globals(),
objc.pathForFramework("/System/Library/Frameworks/IOKit.framework"))
objc.pathForFramework("/System/Library/Frameworks/IOKit.framework")
)


POWER_TYPE_MAP = {
Expand Down
13 changes: 8 additions & 5 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,26 @@


if platform.startswith('darwin'):
REQUIREMENTS.append('pyobjc == 2.3')
REQUIREMENTS.append('pyobjc >= 2.5')


setup(name="Power",
version="1.0",
setup(
name="Power",
version="1.1",
description="Cross-platform system power status information.",
author="Ilya Kulakov",
author_email="[email protected]",
url="https://github.com/Kentzo/Power",
platforms=["Mac OS X 10.6+", "Windows XP+", "Linux 2.6+"],
packages=['power'],
classifiers=[
'Natural Language :: English',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python',
'Programming Language :: Python :: 2',
'Operating System :: MacOS :: MacOS X',
'Operating System :: Microsoft :: Windows',
'Operating System :: POSIX :: Linux',
'License :: OSI Approved :: MIT License',
'Natural Language :: English',
'Topic :: System :: Power (UPS)',
'Topic :: System :: Hardware',
'Topic :: System :: Monitoring'
Expand Down

0 comments on commit 2c7038e

Please sign in to comment.