gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [taler-merchant-frontend-examples] branch master updated: p


From: gnunet
Subject: [GNUnet-SVN] [taler-merchant-frontend-examples] branch master updated: python tutorial compiles
Date: Wed, 22 Feb 2017 14:47:14 +0100

This is an automated email from the git hooks/post-receive script.

marcello pushed a commit to branch master
in repository merchant-frontend-examples.

The following commit(s) were added to refs/heads/master by this push:
     new 74423fa  python tutorial compiles
74423fa is described below

commit 74423fa10229a3f806d64880b4ba058f8194ae59
Author: Marcello Stanisci <address@hidden>
AuthorDate: Wed Feb 22 14:47:16 2017 +0100

    python tutorial compiles
---
 Makefile                                           |  12 +++++++-----
 common/README                                      |   3 +++
 {graphics => common/graphics}/arch.dot             |   0
 common/graphics/arch.jpg                           | Bin 0 -> 25358 bytes
 common/graphics/arch.pdf                           | Bin 0 -> 17287 bytes
 common/graphics/arch.png                           | Bin 0 -> 39710 bytes
 graphics/arch.dot => common/graphics/arch_nobo.dot |   3 ---
 common/graphics/arch_nobo.jpg                      | Bin 0 -> 20577 bytes
 common/graphics/arch_nobo.pdf                      | Bin 0 -> 16896 bytes
 php/doc/Makefile                                   |  12 +++++++-----
 python/{tutorial => example}/templates/index.html  |   0
 python/{tutorial => example}/tutorial.py           |   6 +++---
 12 files changed, 20 insertions(+), 16 deletions(-)

diff --git a/Makefile b/Makefile
index d3a8693..9b62776 100644
--- a/Makefile
+++ b/Makefile
@@ -2,14 +2,16 @@
 
 .PHONY: graphics
 
-SUBDIRS := php
+SUBDIRS := php/doc python/doc
 
 all: $(SUBDIRS)
 
 $(SUBDIRS): graphics
-       cp -t $@/doc graphics/arch.png
-       cd $@/doc/; texi2pdf tutorial.texi
-       cd $@/doc/; zip samples.zip ../*.$@
+       cp -t $@ common/graphics/arch.png
+       $(MAKE) -C $@
 
 graphics:
-       cd graphics; dot -Tpng arch.dot > arch.png
+       cd common/graphics; dot -Tpdf arch.dot > arch.pdf
+       cd common/graphics; dot -Tpdf arch_nobo.dot > arch_nobo.pdf
+       cd common/graphics; dot -Tjpg arch.dot > arch.jpg
+       cd common/graphics; dot -Tjpg arch_nobo.dot > arch_nobo.jpg
diff --git a/common/README b/common/README
new file mode 100644
index 0000000..37bfe95
--- /dev/null
+++ b/common/README
@@ -0,0 +1,3 @@
+This directory contains all those parts that are
+common to any tutorial regardless of the language,
+like graphics and introductory chapters.
diff --git a/graphics/arch.dot b/common/graphics/arch.dot
similarity index 100%
copy from graphics/arch.dot
copy to common/graphics/arch.dot
diff --git a/common/graphics/arch.jpg b/common/graphics/arch.jpg
new file mode 100644
index 0000000..9df1d9e
Binary files /dev/null and b/common/graphics/arch.jpg differ
diff --git a/common/graphics/arch.pdf b/common/graphics/arch.pdf
new file mode 100644
index 0000000..3e00793
Binary files /dev/null and b/common/graphics/arch.pdf differ
diff --git a/common/graphics/arch.png b/common/graphics/arch.png
new file mode 100644
index 0000000..a2d40cc
Binary files /dev/null and b/common/graphics/arch.png differ
diff --git a/graphics/arch.dot b/common/graphics/arch_nobo.dot
similarity index 83%
rename from graphics/arch.dot
rename to common/graphics/arch_nobo.dot
index 6c4e323..751ddbb 100644
--- a/graphics/arch.dot
+++ b/common/graphics/arch_nobo.dot
@@ -4,7 +4,6 @@ digraph G {
   admin[label="Shop admin"];
   subgraph cluster_0 {
     Frontend;
-    Backoffice;
     Backend;
     DBMS;
     label="Shop server";
@@ -14,9 +13,7 @@ digraph G {
     label="Exchange";
   }
   user->Frontend;
-  admin->Backoffice;
   Frontend->Backend;
-  Backoffice->Backend;
   Backend->DBMS;
   Backend->Exchange;
 }
diff --git a/common/graphics/arch_nobo.jpg b/common/graphics/arch_nobo.jpg
new file mode 100644
index 0000000..7825485
Binary files /dev/null and b/common/graphics/arch_nobo.jpg differ
diff --git a/common/graphics/arch_nobo.pdf b/common/graphics/arch_nobo.pdf
new file mode 100644
index 0000000..c75304e
Binary files /dev/null and b/common/graphics/arch_nobo.pdf differ
diff --git a/php/doc/Makefile b/php/doc/Makefile
index 56e08cd..bffea9a 100644
--- a/php/doc/Makefile
+++ b/php/doc/Makefile
@@ -2,16 +2,18 @@ all: tutorial.pdf tutorial.html
 
 tutorial.pdf: arch.pdf tutorial.texi
        texi2pdf tutorial.texi
+
 tutorial.html: arch.jpg tutorial.texi
        texi2html tutorial.texi
-arch.pdf: arch.dot
-       dot -Tpdf arch.dot > arch.pdf
-arch.jpg: arch.dot
-       dot -Tjpg arch.dot > arch.jpg
+
+arch.pdf:
+       cp ../../common/graphics/arch.pdf .
+
+arch.jpg:
+       cp ../../common/graphics/arch.jpg .
 
 clean:
        rm -f arch.jpg arch.pdf tutorial.html tutorial.pdf
 
-
 info_TEXINFOS = tutorial.texi
 manual_TEXINFOS = version.texi
diff --git a/python/tutorial/templates/index.html 
b/python/example/templates/index.html
similarity index 100%
rename from python/tutorial/templates/index.html
rename to python/example/templates/index.html
diff --git a/python/tutorial/tutorial.py b/python/example/tutorial.py
similarity index 95%
rename from python/tutorial/tutorial.py
rename to python/example/tutorial.py
index 7d6bbff..c1c2fa9 100644
--- a/python/tutorial/tutorial.py
+++ b/python/example/tutorial.py
@@ -39,12 +39,12 @@ def index():
 @app.route("/donate")
 def donate():
    response = flask.Response(status=402)
-   response.headers["X-Taler-Contract-Url"] = "/generate-contract"
+   response.headers["X-Taler-Contract-Url"] = "/generate-proposal"
    return response
 
 
address@hidden("/generate-contract")
-def generate_contract():
address@hidden("/generate-proposal")
+def generate_proposal():
     DONATION = amounts.string_to_amount("0.1:%s" % CURRENCY) 
     MAX_FEE = amounts.string_to_amount("0.05:%s" % CURRENCY) 
     order = dict(

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]