]> thyrsus.com Git - coverity-submit.git/commitdiff
Update for Coverity's simplified submission procedure.
authorEric S. Raymond <esr@thyrsus.com>
Wed, 5 Sep 2012 13:47:34 +0000 (09:47 -0400)
committerEric S. Raymond <esr@thyrsus.com>
Wed, 5 Sep 2012 13:47:34 +0000 (09:47 -0400)
NEWS
coverity-submit
coverity-submit.xml

diff --git a/NEWS b/NEWS
index ac0312dea4f2d96f67d6c06c57f4ea31f0cbe2c2..fc9c52ccf5a158d420a41bb1484e3b9603baaf0e 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,8 @@
                        NEWS file for coverty-submit
 
+1.2 @ 2012-09-05
+    Changed to support Coverity's new direct-upload feature.
+
 1.0 @ 2012-05-14
     Initial release.
 
index 7871adde230c6e4a50abf6cf760574e0a148e601..a00372bd7e7bcb13c4dd4dfd6d8452f3c953416c 100755 (executable)
@@ -6,7 +6,7 @@
 #
 import os, sys, ConfigParser, getopt
 
-version="1.1"
+version="1.2"
 
 if __name__ == '__main__':
     name = email = project = password = url = None
@@ -56,18 +56,6 @@ if __name__ == '__main__':
         email = config.get("ALL", "email")
     else:
         die("Every project requires an email option.")
-    if config.has_option(project, "upload"):
-        upload = config.get(project, "upload")
-    elif config.has_option("ALL", "upload"):
-        upload = config.get("ALL", "upload")
-    else:
-        die("Every project requires an upload option.")
-    if config.has_option(project, "advertise"):
-        advertise = config.get(project, "advertise")
-    elif config.has_option("ALL", "advertise"):
-        advertise = config.get("ALL", "advertise")
-    else:
-        die("Every project requires an advertise option.")
     if config.has_option(project, "prebuild"):
         prebuild = config.get(project, "prebuild")
     else:
@@ -80,10 +68,6 @@ if __name__ == '__main__':
         postbuild = config.get(project, "postbuild")
     else:
         postbuild = None
-    if "%s" not in upload:
-        die("The upload option must contain a %s to plug a tarball name into.")
-    if "%s" not in advertise:
-        die("The advertise option must contain a %s to plug a tarball name into.")
 
     def do_or_die(cmd):
         print(cmd)
@@ -122,14 +106,13 @@ if __name__ == '__main__':
     tarball = "%s-scan.tgz" % project
     do_or_die("mv cov-int /tmp; (cd /tmp; tar -czf %s README cov-int; rm -fr cov-int)" % tarball)
 
-    print("Uploading to where it's publicly visible...")
-    do_or_die(upload % ("/tmp/" + tarball))
-    url = (advertise % tarball)
-
     print("Posting the analysis request...")
-    do_or_die('''curl --data \
-     "project=%(project)s&password=%(password)s&email=%(email)s&url=%(url)s" \
-     http://scan5.coverity.com/cgi-bin/submit_build.py
+    do_or_die('''curl \
+    --form file=@/tmp/%(tarball)s \
+    --form project=%(project)s \
+    --form password=%(password)s \
+    --form email=%(email)s \
+     http://scan5.coverity.com/cgi-bin/upload.py
     ''' % globals())
 
     print("Done. You'll get mail at %s." % email)
index 29c24f6a524468b96b1ebdbf41f084e1e7b49dea..f1ebfde0a742d373971d0bf021583524f02e99ed 100644 (file)
@@ -30,9 +30,8 @@
 the demonstration Coverity server into a one-step operation.  It
 automates the sequence of (a) running cov-build locally, (b) bundling
 the results into a tarball with a properly formatted README, (c)
-uploading the result to a public drop area of your choice, and (d)
-submitting an analysis request to the server, and (e) retrieving the 
-request status.</para>
+submitting a tarball and analysis request to the server, and (d)
+retrieving the request status.</para>
 
 </refsect1>
 <refsect1><title>CONFIGURATION</title>
@@ -47,8 +46,6 @@ name: Eric S. Raymond
 userid: esr
 email: esr@thyrsus.com
 tools: /usr/local/coverity/bin
-upload: scp %s esr@login.ibiblio.org:/public/html/catb/esr
-advertise: http://catb.org/~esr/%s
 
 [gpsd]
 password: XXXXXX
@@ -72,21 +69,16 @@ or specify different addresses per-project.</para>
 'tools' option to tell <application>coverity-submit</application>
 where to find it.</para>
 
-<para>The 'upload' and 'advertise' option are required.  They tell
-<application>coverity-submit</application> how to ship your tarball to
-a public drop area where the Coverity server can see it, and the URL
-the Coverity server can use to fetch it.  Each of these options must
-contain the string '%s' indicating where the generated name of the
-tarball should be spliced in. Note that, like 'email', there can also
-be specified in a per-project entry in case you want to have separate
-per-project drop areas.</para>
-
 <para>This configuration describes two different (real) projects, one
 with an scons-based build and one with an autotools-based build. For
 each project you must specifty the Coverity build password and the
 local build command to pass to cov-build. You may optionally specify
 local prebuild and postbuild commands.</para>
 
+<para>The <option>build</option> and <option>advertise</option>
+options of versions 1.1 annd previously are no longer needed, as
+Coverity has changed its submission form to support direct upload of
+the results tarball.</para>
 </refsect1>
 <refsect1><title>OPERATION</title>
 
@@ -108,8 +100,7 @@ which project profile to use, it then performs the following steps:</para>
 <step><para>The project's local build command.</para></step>
 <step><para>The project's local postbuild command, if specified.</para></step>
 <step><para>Generating a README and bundling it into a tarball with the scan results.</para></step>
-<step><para>Copying the tarball to the upload location.</para></step>
-<step><para>Sending an analysis job request to the Coverity server.</para></step>
+<step><para>Sending the tarball and an analysis job request to the Coverity server.</para></step>
 </procedure>
 
 <para>The script will report the result of the job request by dumping the