mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
This commit is contained in:
parent
dc09be0385
commit
ac6245404b
@ -29,7 +29,7 @@
|
|||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="label" >
|
<widget class="QLabel" name="label" >
|
||||||
<property name="text" >
|
<property name="text" >
|
||||||
<string><p>Set a regular expression pattern to use when trying to guess ebook metadata from filenames. <p>A <a href="http://docs.python.org/lib/re-syntax.html">reference</a> on the syntax of regular expressions is available.<p>Use the <b>Test</b> functionality below to test you regular expression on a few sample filenames.</string>
|
<string><p>Set a regular expression pattern to use when trying to guess ebook metadata from filenames. <p>A <a href="http://docs.python.org/lib/re-syntax.html">reference</a> on the syntax of regular expressions is available.<p>Use the <b>Test</b> functionality below to test your regular expression on a few sample filenames.</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="textFormat" >
|
<property name="textFormat" >
|
||||||
<enum>Qt::RichText</enum>
|
<enum>Qt::RichText</enum>
|
||||||
|
26
upload.py
26
upload.py
@ -7,6 +7,8 @@ from functools import partial
|
|||||||
#from pyvix.vix import Host, VIX_SERVICEPROVIDER_VMWARE_WORKSTATION
|
#from pyvix.vix import Host, VIX_SERVICEPROVIDER_VMWARE_WORKSTATION
|
||||||
import pysvn
|
import pysvn
|
||||||
|
|
||||||
|
from libprs500 import __version__, __appname__
|
||||||
|
|
||||||
PREFIX = "/var/www/vhosts/kovidgoyal.net/subdomains/libprs500"
|
PREFIX = "/var/www/vhosts/kovidgoyal.net/subdomains/libprs500"
|
||||||
DOWNLOADS = PREFIX+"/httpdocs/downloads"
|
DOWNLOADS = PREFIX+"/httpdocs/downloads"
|
||||||
DOCS = PREFIX+"/httpdocs/apidocs"
|
DOCS = PREFIX+"/httpdocs/apidocs"
|
||||||
@ -18,7 +20,6 @@ check_call = partial(_check_call, shell=True)
|
|||||||
|
|
||||||
|
|
||||||
def tag_release():
|
def tag_release():
|
||||||
from libprs500 import __version__
|
|
||||||
print 'Tagging release'
|
print 'Tagging release'
|
||||||
base = 'https://kovid@svn.kovidgoyal.net/code/libprs500'
|
base = 'https://kovid@svn.kovidgoyal.net/code/libprs500'
|
||||||
tag = base + '/tags/'+__version__
|
tag = base + '/tags/'+__version__
|
||||||
@ -64,17 +65,17 @@ def build_installer(installer, vm, timeout=25):
|
|||||||
|
|
||||||
return os.path.basename(installer)
|
return os.path.basename(installer)
|
||||||
|
|
||||||
|
def installer_name(ext):
|
||||||
|
return 'dist/%s-%s.%s'%(__appname__, __version__, ext)
|
||||||
|
|
||||||
def build_windows():
|
def build_windows():
|
||||||
from libprs500 import __version__
|
installer = installer_name('exe')
|
||||||
installer = 'dist/libprs500-%s.exe'%__version__
|
|
||||||
vm = '/vmware/Windows XP/Windows XP Professional.vmx'
|
vm = '/vmware/Windows XP/Windows XP Professional.vmx'
|
||||||
return build_installer(installer, vm, 20)
|
return build_installer(installer, vm, 20)
|
||||||
|
|
||||||
|
|
||||||
def build_osx():
|
def build_osx():
|
||||||
from libprs500 import __version__
|
installer = installer_name('dmg')
|
||||||
installer = 'dist/libprs500-%s.dmg'%__version__
|
|
||||||
vm = '/vmware/Mac OSX/Mac OSX.vmx'
|
vm = '/vmware/Mac OSX/Mac OSX.vmx'
|
||||||
return build_installer(installer, vm, 20)
|
return build_installer(installer, vm, 20)
|
||||||
|
|
||||||
@ -94,13 +95,14 @@ def upload_demo():
|
|||||||
check_call('cd src/libprs500/ebooks/lrf/txt/demo/ && zip -j /tmp/txt-demo.zip * /tmp/txt2lrf.lrf')
|
check_call('cd src/libprs500/ebooks/lrf/txt/demo/ && zip -j /tmp/txt-demo.zip * /tmp/txt2lrf.lrf')
|
||||||
check_call('''scp /tmp/txt-demo.zip castalia:%s/'''%(DOWNLOADS,))
|
check_call('''scp /tmp/txt-demo.zip castalia:%s/'''%(DOWNLOADS,))
|
||||||
|
|
||||||
def upload_installers(exe, dmg):
|
def upload_installers():
|
||||||
if exe and os.path.exists(os.path.join('dist', exe)):
|
exe, dmg = installer_name('exe'), installer_name('dmg')
|
||||||
|
if exe and os.path.exists(exe):
|
||||||
check_call('''ssh castalia rm -f %s/libprs500\*.exe'''%(DOWNLOADS,))
|
check_call('''ssh castalia rm -f %s/libprs500\*.exe'''%(DOWNLOADS,))
|
||||||
check_call('''scp dist/%s castalia:%s/'''%(exe, DOWNLOADS))
|
check_call('''scp %s castalia:%s/'''%(exe, DOWNLOADS))
|
||||||
check_call('''ssh castalia rm -f %s/libprs500\*.dmg'''%(DOWNLOADS,))
|
check_call('''ssh castalia rm -f %s/libprs500\*.dmg'''%(DOWNLOADS,))
|
||||||
if dmg and os.path.exists(os.path.join('dist', dmg)):
|
if dmg and os.path.exists(dmg):
|
||||||
check_call('''scp dist/%s castalia:%s/'''%(dmg, DOWNLOADS))
|
check_call('''scp %s castalia:%s/'''%(dmg, DOWNLOADS))
|
||||||
check_call('''ssh castalia chmod a+r %s/\*'''%(DOWNLOADS,))
|
check_call('''ssh castalia chmod a+r %s/\*'''%(DOWNLOADS,))
|
||||||
check_call('''ssh castalia /root/bin/update-installer-links %s %s'''%(exe, dmg))
|
check_call('''ssh castalia /root/bin/update-installer-links %s %s'''%(exe, dmg))
|
||||||
|
|
||||||
@ -131,10 +133,10 @@ def main():
|
|||||||
check_call('svn commit -m "Updated translations" src/libprs500/translations')
|
check_call('svn commit -m "Updated translations" src/libprs500/translations')
|
||||||
tag_release()
|
tag_release()
|
||||||
upload_demo()
|
upload_demo()
|
||||||
exe, dmg = build_installers()
|
build_installers()
|
||||||
if upload:
|
if upload:
|
||||||
print 'Uploading installers...'
|
print 'Uploading installers...'
|
||||||
upload_installers(exe, dmg)
|
upload_installers()
|
||||||
print 'Uploading to PyPI'
|
print 'Uploading to PyPI'
|
||||||
check_call('''python setup.py register bdist_egg --exclude-source-files upload''')
|
check_call('''python setup.py register bdist_egg --exclude-source-files upload''')
|
||||||
upload_docs()
|
upload_docs()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user