Commit 9f7aec98 authored by antoine's avatar antoine

script.sh added

parent 5c24168a
Pipeline #502 canceled with stages
This is MetaPost, version 2.00 (TeX Live 2019/Arch Linux) (kpathsea version 6.3.1) 14 JAN 2020 14:18
**meta-elastique.md
(/usr/share/texmf-dist/metapost/base/mpost.mp
(/usr/share/texmf-dist/metapost/base/plain.mp
Preloading the plain mem file, version 1.005) ) (./meta-elastique.md [102])
*end
1 output file written: svg/102.svg
% Bienvennu·e·s!
% Les lignes commençant par le signe `%` ne sont pas prises en compte par metapost.
% Elles peuvent donc servir à mettre des commentaires
% Quelques liens lettrages et signalétique
% Une documentation Metapost
% Des ressources et exemples Metapost% locale cheatsheet →% en ligne http://tex.loria.fr/prod-graph/zoonekynd/metapost/metapost.html et https://melusine.eu.org/syracuse/metapost/mpman/
% en ligne http://tex.loria.fr/prod-graph/zoonekynd/metapost/metapost.html et https://melusine.eu.org/syracuse/metapost/mpman/
outputtemplate := "svg/%c.svg"; outputformat := "svg";
u = 7pt;
ux = 1*u;
uy = 1*u;
sx = 1*u;
sy = 1*u;
rot = 0;
height = 40;
grid = 0;
color pinkrose; pinkrose:= (255/102,153/255,200/255) ;
def beginchar(expr keycode, width)=
beginfig(keycode);
pickup pencircle scaled .2;
draw (0 * ux, 0 * uy) -- (width * ux, 0 * uy) -- (width * ux, height * uy) -- (0 * ux, height * uy) -- cycle scaled 0 withcolor red;
height = 40;
if grid = 1:
defaultscale :=.2;
for i=0 upto width:
draw (i*ux, height*uy) -- (i*ux, 0*uy) withcolor pinkrose;
endfor;
for i=0 upto height:
draw (width*ux, i*uy) -- (0*ux, i*uy) withcolor pinkrose;
endfor;
fi;
pickup pencircle xscaled sx yscaled sy rotated rot;
enddef;
def endchar(expr lenDots)=
if grid = 1:
defaultscale :=.5;
for i=1 upto lenDots:
dotlabels.urt([i]) withcolor blue;
endfor;
fi;
endfig;
enddef;
beginfig(102);
z1 = (0, 50);
z2 = (100, 100);
z3 = (200, 150);
% La commande `draw` permet de dessiner des chemins.
% Ici, on demande à metapost de tracer la ligne droite allant de `z1`à `z2`;
draw z1--z2;
% On peut choisir une couleur autre que le noir.
draw z2--z3 withcolor blue;
% La ligne suivante permet d'afficher nos trois points numérotés.
dotlabels.top(1, 2, 3)
endfig;
end;
URL='http://pads.osp.kitchen/p/meta-elastique/export/txt'
while :
do
curl $URL -o meta-elastique.md & mpost -interraction=batchmode meta-elastique.md
sleep 5
done
<?xml version="1.0"?>
<!-- Created by MetaPost 2.00 on 2020.01.14:1418 -->
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="204.981339" height="159.420364" viewBox="0 0 204.981339 159.420364">
<!-- Original BoundingBox: -2.490677 48.500000 202.490662 159.420364 -->
<path d="M2.000000 109.000000L102.000000 59.000000" style="stroke:rgb(0.000000%,0.000000%,0.000000%); stroke-width: 0.500000;stroke-linecap: round;stroke-linejoin: round;stroke-miterlimit: 10.000000;fill: none;"></path>
<path d="M102.000000 59.000000L202.000000 9.000000" style="stroke:rgb(0.000000%,0.000000%,100.000000%); stroke-width: 0.500000;stroke-linecap: round;stroke-linejoin: round;stroke-miterlimit: 10.000000;fill: none;"></path>
<g transform="translate(-0.490677 106.000000)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
<text font-size="9.962646">1</text>
</g>
<path d="M2.000000 109.000000l0 0" style="stroke:rgb(0.000000%,0.000000%,0.000000%); stroke-width: 3.000000;stroke-linecap: round;stroke-linejoin: round;stroke-miterlimit: 10.000000;fill: none;"></path>
<g transform="translate(99.509323 56.000000)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
<text font-size="9.962646">2</text>
</g>
<path d="M102.000000 59.000000l0 0" style="stroke:rgb(0.000000%,0.000000%,0.000000%); stroke-width: 3.000000;stroke-linecap: round;stroke-linejoin: round;stroke-miterlimit: 10.000000;fill: none;"></path>
<g transform="translate(199.509323 6.000000)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
<text font-size="9.962646">3</text>
</g>
<path d="M202.000000 9.000000l0 0" style="stroke:rgb(0.000000%,0.000000%,0.000000%); stroke-width: 3.000000;stroke-linecap: round;stroke-linejoin: round;stroke-miterlimit: 10.000000;fill: none;"></path>
</svg>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment