Source

smart-notify / setup.py

# -*- coding: utf-8 -*-
#----------------------------------------------------------------------------#
# setup.py
# Lars Yencken <lars.yencken@gmail.com>
# vim: ts=4 sw=4 sts=4 et tw=78:
# Tue Apr  8 16:35:12 2008
#
#----------------------------------------------------------------------------#

"Setup script for smartNotify module."

#----------------------------------------------------------------------------#

import os
from distutils.core import setup

def get_hg_version():
    version = None
    if os.system('which hg >/dev/null 2>/dev/null') == 0:
        version = os.popen('hg id -n 2>/dev/null').read().strip()
    return version or 'unknown'

#----------------------------------------------------------------------------#

setup(
        name='smartNotify',
        version='0.1.%s' % get_hg_version(),
        py_modules=['smartNotify'],
        scripts=['smartNotify.py']
    )