Skip to content

Commit 03b1cc9

Browse files
committed
fix permissions and uprev
1 parent f0e8ef3 commit 03b1cc9

File tree

3 files changed

+16
-2
lines changed

3 files changed

+16
-2
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,5 @@ dist/
77
.installed.cfg
88
*.egg
99
.idea
10+
build
11+
env

pydf/wkhtmltopdf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import subprocess
33
from tempfile import NamedTemporaryFile
44

5-
__version__ = '0.2'
5+
__version__ = '0.21'
66

77

88
def execute_wk(*args):

setup.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,27 @@
11
import sys
2+
import os
23
from setuptools import setup
4+
from setuptools.command.install import install
35

46
description = 'PDF generation in python using wkhtmltopdf suitable for heroku'
57
long_description = description
68
if 'upload' in sys.argv or 'register' in sys.argv:
79
import pypandoc
810
long_description = pypandoc.convert('README.md', 'rst')
911

12+
13+
class OverrideInstall(install):
14+
def run(self):
15+
install.run(self)
16+
for filepath in self.get_outputs():
17+
if filepath.endswith('pydf/bin/wkhtmltopdf'):
18+
os.chmod(filepath, 0775)
19+
20+
1021
setup(
1122
name='python-pdf',
12-
version='0.2',
23+
cmdclass={'install': OverrideInstall},
24+
version='0.21',
1325
description=description,
1426
long_description=long_description,
1527
author='Samuel Colvin',

0 commit comments

Comments
 (0)