mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Add version number to base directory in source tarball. Also fix generation of sources for the qt 5 betas
This commit is contained in:
parent
6ebbe5852e
commit
d5f8e89ed3
@ -268,10 +268,10 @@ class Sdist(Command):
|
|||||||
os.makedirs(self.d(self.DEST))
|
os.makedirs(self.d(self.DEST))
|
||||||
tdir = tempfile.mkdtemp()
|
tdir = tempfile.mkdtemp()
|
||||||
atexit.register(shutil.rmtree, tdir)
|
atexit.register(shutil.rmtree, tdir)
|
||||||
tdir = self.j(tdir, 'calibre')
|
tdir = self.j(tdir, 'calibre-%s' % __version__)
|
||||||
self.info('\tRunning git export...')
|
self.info('\tRunning git export...')
|
||||||
os.mkdir(tdir)
|
os.mkdir(tdir)
|
||||||
subprocess.check_call('git archive master | tar -x -C ' + tdir, shell=True)
|
subprocess.check_call('git archive HEAD | tar -x -C ' + tdir, shell=True)
|
||||||
for x in open('.gitignore').readlines():
|
for x in open('.gitignore').readlines():
|
||||||
if not x.startswith('resources/'):
|
if not x.startswith('resources/'):
|
||||||
continue
|
continue
|
||||||
@ -306,7 +306,7 @@ class Sdist(Command):
|
|||||||
|
|
||||||
self.info('\tCreating tarfile...')
|
self.info('\tCreating tarfile...')
|
||||||
dest = self.DEST.rpartition('.')[0]
|
dest = self.DEST.rpartition('.')[0]
|
||||||
subprocess.check_call(['tar', '-cf', self.a(dest), 'calibre'], cwd=self.d(tdir))
|
subprocess.check_call(['tar', '-cf', self.a(dest), 'calibre-%s' % __version__], cwd=self.d(tdir))
|
||||||
self.info('\tCompressing tarfile...')
|
self.info('\tCompressing tarfile...')
|
||||||
if os.path.exists(self.a(self.DEST)):
|
if os.path.exists(self.a(self.DEST)):
|
||||||
os.remove(self.a(self.DEST))
|
os.remove(self.a(self.DEST))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user