[git] GPGME - branch, ben/docs/2018-03, updated. gpgme-1.10.0-79-gf29bda8

by Ben McGinnes cvs at cvs.gnupg.org
Tue Mar 13 05:04:36 CET 2018


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GnuPG Made Easy".

The branch, ben/docs/2018-03 has been updated
       via  f29bda8d7146b4bc0bf73d6e613131545ff86b73 (commit)
      from  c27a7a3f994dad0eccee890185582f4350fbf233 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit f29bda8d7146b4bc0bf73d6e613131545ff86b73
Author: Ben McGinnes <ben at adversary.org>
Date:   Tue Mar 13 15:03:11 2018 +1100

    doc: python bindings howto
    
    * Signatures have changed as a result of the recent update from Justus.
    * Sample code updated.
    * Text to follow later.

diff --git a/lang/python/docs/GPGMEpythonHOWTOen.org b/lang/python/docs/GPGMEpythonHOWTOen.org
index 40d2814..5d259a6 100644
--- a/lang/python/docs/GPGMEpythonHOWTOen.org
+++ b/lang/python/docs/GPGMEpythonHOWTOen.org
@@ -503,13 +503,13 @@
    #+begin_src python
      import gpg
 
-     text = """Declaration of ... something.
+     text = b"""Declaration of ... something.
 
      """
 
      c = gpg.Context()
      c.armor = True
-     signed = c.sign(text, mode=mode.NORMAL)
+     signed = c.sign(text, mode=0)
 
      afile = open("/path/to/statement.txt.asc", "w")
      for i in range(len(signed[0].splitlines())):
@@ -527,8 +527,7 @@
      """
 
      c = gpg.Context()
-     c.armor = True
-     signed = c.sign(text, mode=mode.CLEAR)
+     signed = c.sign(text, mode=2)
 
      afile = open("/path/to/statement.txt.asc", "w")
      for i in range(len(signed[0].splitlines())):
@@ -547,7 +546,7 @@
 
      c = gpg.Context()
      c.armor = True
-     signed = c.sign(text, mode=mode.DETACH)
+     signed = c.sign(text, mode=1)
 
      afile = open("/path/to/statement.txt.asc", "w")
      for i in range(len(signed[0].splitlines())):
@@ -566,7 +565,7 @@
 
      c = gpg.Context()
      c.armor = True
-     signed = c.sign(text, mode=mode.DETACH)
+     signed = c.sign(text, mode=1)
 
      afile = open("/path/to/statement.txt.sig", "wb")
      afile.write(signed[0])

-----------------------------------------------------------------------

Summary of changes:
 lang/python/docs/GPGMEpythonHOWTOen.org | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)


hooks/post-receive
-- 
GnuPG Made Easy
http://git.gnupg.org




More information about the Gnupg-commits mailing list