osh
osh is an OCaml website, providing an API to generate SVG shields.
Installation
osh
can be installed with opam:
opam install osh
If you don't have opam
, you can install it following the how to install opam guide.
If you can't or don't want to use opam
, consult the opam file for build instructions.
Quickstart
$ curl https://osh.ocamlpro.com/badge\?label\=build\&color\=green\&status\=passing > badge.svg
$ cat badge.svg
<svg width="88.600000" height="20.000000" viewBox="0 0 886.000000 200" xmlns="http://www.w3.org/2000/svg" role="img" aria-label="build: passing">
<title>build: passing</title>
<g>
<rect fill="#2A2A2A" width="368.000000" height="200"/>
<rect fill="#3C1" x="368.000000" width="518.000000" height="200"/>
</g>
<g aria-hidden="true" fill="#fff" text-anchor="start" font-family="Verdana,DejaVu Sans,sans-serif" font-size="110">
<text x="60.000000" y="148" textLength="268.000000" fill="#000" opacity="0.1">build</text>
<text x="50.000000" y="138" textLength="268.000000">build</text>
<text x="423.000000" y="148" textLength="418.000000" fill="#000" opacity="0.1">passing</text>
<text x="413.000000" y="138" textLength="418.000000">passing</text>
</g>
</svg>
For more, have a look at the example folder, at the documentation or at the test suite.
About