From 326eaa599c6fef139a5d051561a3cae418ab5880 Mon Sep 17 00:00:00 2001 From: Alexandre B A Villares Date: Sun, 3 Nov 2019 00:20:20 -0200 Subject: [PATCH] markdown generator --- 2019/sketch_191102a/sketch_191102a.pyde | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/2019/sketch_191102a/sketch_191102a.pyde b/2019/sketch_191102a/sketch_191102a.pyde index f22c0bf9..7820e14e 100644 --- a/2019/sketch_191102a/sketch_191102a.pyde +++ b/2019/sketch_191102a/sketch_191102a.pyde @@ -68,3 +68,17 @@ def plot(angle): pushMatrix() elif c == "]": popMatrix() + +def settings(): + """ print markdown to add at the sketch-a-day page""" + from os import path + global SKETCH_NAME, OUTPUT + SKETCH_NAME = path.basename(sketchPath()) + OUTPUT = ".png" + println( + """ +![{0}]({2}/{0}/{0}{1}) + +[{0}](https://github.com/villares/sketch-a-day/tree/master/{2}/{0}) [[Py.Processing](https://villares.github.io/como-instalar-o-processing-modo-python/index-EN)] +""".format(SKETCH_NAME, OUTPUT, year()) + )