From d1d6fb3dce7c168075584fdef18a1a2bbf8a842c Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Sun, 28 Dec 2014 15:05:49 +0100 Subject: Use Qt resources for the window icon. --- setup.py | 23 +++++++---------------- 1 file changed, 7 insertions(+), 16 deletions(-) (limited to 'setup.py') diff --git a/setup.py b/setup.py index 77b9fe983..5217488e1 100755 --- a/setup.py +++ b/setup.py @@ -23,25 +23,16 @@ import os import os.path -import glob -import shutil from scripts import setupcommon as common import setuptools -BASEDIR = os.path.dirname(os.path.realpath(__file__)) - - -icon_path = os.path.join('qutebrowser', 'icons') try: - shutil.rmtree(icon_path) -except OSError: - pass -os.mkdir(icon_path) -for fn in glob.glob('icons/*.png'): - shutil.copy(fn, icon_path) + BASEDIR = os.path.dirname(os.path.realpath(__file__)) +except NameError: + BASEDIR = None try: @@ -54,10 +45,10 @@ try: test_suite='qutebrowser.test', zip_safe=True, install_requires=['pypeg2', 'jinja2', 'pygments'], - data_files=[('icons', glob.glob('icons/*'))], **common.setupdata ) finally: - path = os.path.join(BASEDIR, 'qutebrowser', 'git-commit-id') - if os.path.exists(path): - os.remove(path) + if BASEDIR is not None: + path = os.path.join(BASEDIR, 'qutebrowser', 'git-commit-id') + if os.path.exists(path): + os.remove(path) -- cgit v1.2.3-54-g00ecf