Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .github/workflows/landingkit-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: landingkit-check

# The landing kit's own rules (a hand-written hero row, a playground link that is
# not btn-try, a fact said twice beside the mantra strip, a fork ribbon with no
# Digital Commons band), read from the BUILT site.

on:
pull_request:
branches: [main]
push:
branches: [main]
workflow_dispatch:

permissions:
contents: read

jobs:
check:
name: the page follows the kit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-go@v7
with:
go-version-file: go.mod
cache: false
- uses: peaceiris/actions-hugo@v3
with:
hugo-version: "0.169.0"
extended: true
- run: hugo --minify --destination ./public
- name: Check
env:
GOWORK: "off"
run: go run github.com/go-fleettools/landingkit/cmd/landingkit check public
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ module github.com/go-plot/go-plot.github.io

go 1.27.4

require github.com/go-fleettools/landingkit v0.22.0
require github.com/go-fleettools/landingkit v0.29.0
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
github.com/go-fleettools/landingkit v0.22.0 h1:e5mGBhudZsulY7Yol+Qntw0j8rZOwLVTlszkbMeKAU0=
github.com/go-fleettools/landingkit v0.22.0/go.mod h1:jSXTO7FVKNXCK1aJjLq7H7x8d8wxDoXe3ncXWGcAKRE=
github.com/go-fleettools/landingkit v0.29.0 h1:DLjwM6jHnfymwN3j3gyuJW3v+dR16YlM05zMPV0QWCY=
github.com/go-fleettools/landingkit v0.29.0/go.mod h1:jSXTO7FVKNXCK1aJjLq7H7x8d8wxDoXe3ncXWGcAKRE=
10 changes: 10 additions & 0 deletions hugo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -79,3 +79,13 @@ disableKinds = ['taxonomy', 'term', 'rss', 'sitemap', '404']
chipBgDark = "rgba(90,174,230,.14)"
chipBorderDark = "rgba(90,174,230,.32)"
chipFgDark = "#a4d2f1"

# The hero's buttons, rendered by landingkit's cta.html in the kit's order.
[[params.cta]]
kind = "docs"
href = "https://go-plot.github.io/docs/"
label = "Read the documentation →"

# The architectures the tests RUN on, read from the library's CI.
[params.mantra]
goarch = ["amd64", "arm64", "riscv64", "loong64", "ppc64le", "s390x"]
11 changes: 5 additions & 6 deletions layouts/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,9 @@
<div class="hero"><div class="wrap">
<div>
<h1 class="head">matplotlib's figures, in pure Go.<br><span class="accent">Tested equal where they can be equal.</span></h1>
<p class="sub">go-plot is the plotting library of the Go scientific stack built on <b>go-ndarray</b>. Its <b>object model and defaults are matplotlib's</b> — figure size, fonts, colour cycle, margins, tick placement and tick labels — so a figure looks the way a matplotlib user expects. It writes <b>SVG and PNG</b>, sets labels with a <b>real TeX math typesetter</b>, and needs no Python and no cgo: one static binary, <code>js/wasm</code> included.</p>
<div class="cta">
<a class="btn btn-primary" href="https://go-plot.github.io/docs/">{{ partial "icons/book.html" . }}Read the documentation →</a>
</div>
<p class="sub">go-plot is the plotting library of the Go scientific stack built on <b>go-ndarray</b>. Its <b>object model and defaults are matplotlib's</b> — figure size, fonts, colour cycle, margins, tick placement and tick labels — so a figure looks the way a matplotlib user expects. It writes <b>SVG and PNG</b>, sets labels with a <b>real TeX math typesetter</b>, and needs no Python and {{ if not (partial "mantra-on.html" $) }}no cgo{{ end }}: one static binary, <code>js/wasm</code> included.</p>
{{/* [[params.cta]] in hugo.toml: the kit renders the row */}}
{{ partial "cta.html" . }}
<div class="trust"><span><b>408</b> axes of ticks, bit for bit</span><span><b>{{ len .Site.Params.checks }}</b> kinds of check against matplotlib</span><span><b>100%</b> test coverage</span></div>
</div>
{{/* go-plot/plot v0.1.0, tools/compare/readme/main.go, verbatim but for
Expand Down Expand Up @@ -85,9 +84,9 @@ <h2>The plotting library notebooks <i>reach for first</i>.</h2>
<div class="card"><div class="ico">🧮</div><h3>Data from go-ndarray</h3><p>Every data argument takes <code>[]float64</code>, other numeric slices, or a <code>*ndarray.Array</code> of any of its thirteen dtypes.</p></div>
<div class="card"><div class="ico">🖼️</div><h3>SVG, PNG, and notebooks</h3><p><code>SaveSVG</code> writes vector paths, <code>SavePNG</code> anti-aliased pixels, and <code>Display</code> hands a notebook kernel both. The SVG inlines under a strict Content-Security-Policy: no script, no style attribute, no external reference, text as outlines.</p></div>
<div class="card"><div class="ico">🥧</div><h3>Pie and donut charts</h3><p><code>Pie</code> is <code>ax.pie</code>: labels, <code>AutoPct</code> percentages, explode, start angle, direction, a legend. <code>Donut</code> draws a ring. Labels from data can skip TeX (<code>PlainText</code>), and thin wedges' labels can be spread apart (<code>SpreadLabels</code>).</p></div>
<div class="card"><div class="ico">📦</div><h3>Pure Go, CGO=0</h3><p>No Python, no C. It builds for the six 64-bit Linux targets, 386, arm, <code>js/wasm</code> and <code>wasip1/wasm</code>.</p></div>
{{ if not (partial "mantra-on.html" $) }}<div class="card"><div class="ico">📦</div><h3>Pure Go, CGO=0</h3><p>No Python, no C. It builds for the six 64-bit Linux targets, 386, arm, <code>js/wasm</code> and <code>wasip1/wasm</code>.</p></div>{{ end }}
<div class="card"><div class="ico">✅</div><h3>100% test coverage</h3><p>Gated in CI on three operating systems, with six architectures.</p></div>
<div class="card"><div class="ico">⚖️</div><h3>BSD-3-Clause</h3><p>Every repository of the organization.</p></div>
{{ if not (partial "mantra-on.html" $) }}<div class="card"><div class="ico">⚖️</div><h3>BSD-3-Clause</h3><p>Every repository of the organization.</p></div>{{ end }}
</div>
</div></section>

Expand Down
Loading