mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-05 06:50:29 +03:00
New build option: --no-tarball
This commit is contained in:
parent
61dca767f4
commit
d42dd276a0
1 changed files with 14 additions and 10 deletions
|
|
@ -359,6 +359,7 @@ def build_server(app, thisbuild, vcs, build_dir, output_dir, force):
|
||||||
tarball = common.getsrcname(app,thisbuild)
|
tarball = common.getsrcname(app,thisbuild)
|
||||||
try:
|
try:
|
||||||
ftp.get(apkfile, os.path.join(output_dir, apkfile))
|
ftp.get(apkfile, os.path.join(output_dir, apkfile))
|
||||||
|
if not options.notarball:
|
||||||
ftp.get(tarball, os.path.join(output_dir, tarball))
|
ftp.get(tarball, os.path.join(output_dir, tarball))
|
||||||
except:
|
except:
|
||||||
raise BuildException("Build failed for %s:%s - missing output files" % (app['id'], thisbuild['version']), output)
|
raise BuildException("Build failed for %s:%s - missing output files" % (app['id'], thisbuild['version']), output)
|
||||||
|
|
@ -443,6 +444,7 @@ def build_local(app, thisbuild, vcs, build_dir, output_dir, srclib_dir, extlib_d
|
||||||
raise BuildException("Can't build due to " +
|
raise BuildException("Can't build due to " +
|
||||||
str(len(buildprobs)) + " scanned problems")
|
str(len(buildprobs)) + " scanned problems")
|
||||||
|
|
||||||
|
if not options.notarball:
|
||||||
# Build the source tarball right before we build the release...
|
# Build the source tarball right before we build the release...
|
||||||
print "Creating source tarball..."
|
print "Creating source tarball..."
|
||||||
tarname = common.getsrcname(app,thisbuild)
|
tarname = common.getsrcname(app,thisbuild)
|
||||||
|
|
@ -720,7 +722,7 @@ def build_local(app, thisbuild, vcs, build_dir, output_dir, srclib_dir, extlib_d
|
||||||
shutil.copyfile(src, dest)
|
shutil.copyfile(src, dest)
|
||||||
|
|
||||||
# Move the source tarball into the output directory...
|
# Move the source tarball into the output directory...
|
||||||
if output_dir != tmp_dir:
|
if output_dir != tmp_dir and not options.notarball:
|
||||||
shutil.move(os.path.join(tmp_dir, tarname),
|
shutil.move(os.path.join(tmp_dir, tarname),
|
||||||
os.path.join(output_dir, tarname))
|
os.path.join(output_dir, tarname))
|
||||||
|
|
||||||
|
|
@ -792,6 +794,8 @@ def parse_commandline():
|
||||||
help="Reset and create a brand new build server, even if the existing one appears to be ok.")
|
help="Reset and create a brand new build server, even if the existing one appears to be ok.")
|
||||||
parser.add_option("--on-server", dest="onserver", action="store_true", default=False,
|
parser.add_option("--on-server", dest="onserver", action="store_true", default=False,
|
||||||
help="Specify that we're running on the build server")
|
help="Specify that we're running on the build server")
|
||||||
|
parser.add_option("--no-tarball", dest="notarball", action="store_true", default=False,
|
||||||
|
help="Don't create a source tarball, useful when testing a build")
|
||||||
parser.add_option("-f", "--force", action="store_true", default=False,
|
parser.add_option("-f", "--force", action="store_true", default=False,
|
||||||
help="Force build of disabled apps, and carries on regardless of scan problems. Only allowed in test mode.")
|
help="Force build of disabled apps, and carries on regardless of scan problems. Only allowed in test mode.")
|
||||||
parser.add_option("-a", "--all", action="store_true", default=False,
|
parser.add_option("-a", "--all", action="store_true", default=False,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue