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
12 changes: 3 additions & 9 deletions .github/workflows/pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,20 +26,14 @@ jobs:
- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version-file: go.mod
- run: go vet ./...
- run: go test ./...
- run: go run ./cmd/palette -check
- run: go run ./cmd/mark -check
- run: go run ./cmd/shots -check
- run: go run ./cmd/screens -check
# What a developer runs, with the Task go.mod pins.
- run: go tool task check
# The screens' images are not in git: screens.json names the release that holds them, and
# the page serves them from screens/img.
- if: github.ref == 'refs/heads/main' && hashFiles('screens/screens.json') != ''
env:
GH_TOKEN: ${{ github.token }}
run: |
mkdir -p screens/img
gh release download "$(jq -r .tag screens/screens.json)" --repo "${{ github.repository }}" --pattern screens.tar.gz --output - | tar -xz -C screens/img
run: go tool task screens:download
- if: github.ref == 'refs/heads/main'
uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
with:
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
.task/
screens/img/
12 changes: 8 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,16 @@ through protanopia, deuteranopia or tritanopia, with every pair the palette is h
| `assets/mark.png` | `logos/`: the stack of disks, cut from the mark as it was drawn (1024 px on a clear ground): the tile on the brand's navy (512, 256; the touch icon at 180, the favicon at 64 and 32) for a dark ground, and clear (512, 256) for a light one. Each is the drawing reduced; a size it would have to enlarge fails |

```
task # palette and mark: check, and write dist/ and logos/
task report # every pair, its contrast or its distance in each view
task preview # http://127.0.0.1:4330/
task check # what CI runs: fails on a pair below its floor, or a stale dist/ or logos/
go tool task # palette and mark: check, and write dist/ and logos/
go tool task report # every pair, its contrast or its distance in each view
go tool task preview # http://127.0.0.1:4330/
go tool task check # what CI runs: fails on a pair below its floor, or a stale dist/ or logos/
```

Task is a tool in `go.mod`, so `go tool task` is the version CI runs. `task check` also fails on a
workflow step that is not one task (`go tool taskgate`) and on a package install that skips Socket
Firewall (`go tool sfw check`), from [go-tools](https://github.com/spin-stack/go-tools).

## What holds the palette

`cmd/palette` checks every pair that carries meaning, in both modes, before it writes anything:
Expand Down
11 changes: 10 additions & 1 deletion Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,20 @@ tasks:
- python3 -m http.server 4330 --bind 127.0.0.1

check:
desc: Fail if a pair is below its floor, dist/ or logos/ is not what the sources make, or shots/ lacks a screenshot it lists.
desc: What CI runs - fail if a pair is below its floor, dist/ or logos/ is not what the sources make, shots/ lacks a screenshot it lists, a workflow step is not one task, or an install skips Socket Firewall.
cmds:
- go tool taskgate
- go tool sfw check
- go vet ./...
- go test ./...
- go run ./cmd/palette -check
- go run ./cmd/mark -check
- go run ./cmd/shots -check
- go run ./cmd/screens -check

screens:download:
desc: Unpack the screens' images into screens/img from the release screens/screens.json names - they are not in git, and the published page serves them from there.
cmds:
- mkdir -p screens/img
# GITHUB_REPOSITORY is set in CI; outside it, this repository.
- gh release download "$(jq -r .tag screens/screens.json)" --repo "${GITHUB_REPOSITORY:-spin-stack/brand}" --pattern screens.tar.gz --output - | tar -xz -C screens/img
139 changes: 139 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,142 @@ require (
github.com/BurntSushi/toml v1.5.0
golang.org/x/image v0.30.0
)

require (
cel.dev/expr v0.25.2 // indirect
charm.land/bubbles/v2 v2.1.1 // indirect
charm.land/bubbletea/v2 v2.0.8 // indirect
charm.land/lipgloss/v2 v2.0.6 // indirect
cloud.google.com/go v0.123.0 // indirect
cloud.google.com/go/auth v0.23.1 // indirect
cloud.google.com/go/auth/oauth2adapt v0.2.8 // indirect
cloud.google.com/go/compute/metadata v0.9.0 // indirect
cloud.google.com/go/iam v1.13.0 // indirect
cloud.google.com/go/monitoring v1.30.0 // indirect
cloud.google.com/go/storage v1.64.0 // indirect
github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.35.0 // indirect
github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.59.0 // indirect
github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.59.0 // indirect
github.com/Ladicle/tabwriter v1.0.0 // indirect
github.com/Masterminds/semver/v3 v3.5.0 // indirect
github.com/alecthomas/chroma/v2 v2.27.0 // indirect
github.com/atotto/clipboard v0.1.4 // indirect
github.com/aws/aws-sdk-go-v2 v1.43.4 // indirect
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.7.16 // indirect
github.com/aws/aws-sdk-go-v2/config v1.32.35 // indirect
github.com/aws/aws-sdk-go-v2/credentials v1.19.34 // indirect
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.35 // indirect
github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.35 // indirect
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.35 // indirect
github.com/aws/aws-sdk-go-v2/internal/v4a v1.4.36 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.15 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.9.28 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.35 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.19.36 // indirect
github.com/aws/aws-sdk-go-v2/service/s3 v1.106.5 // indirect
github.com/aws/aws-sdk-go-v2/service/signin v1.5.4 // indirect
github.com/aws/aws-sdk-go-v2/service/sso v1.33.4 // indirect
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.38.4 // indirect
github.com/aws/aws-sdk-go-v2/service/sts v1.45.4 // indirect
github.com/aws/smithy-go v1.27.6 // indirect
github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/chainguard-dev/git-urls v1.0.2 // indirect
github.com/charmbracelet/colorprofile v0.4.3 // indirect
github.com/charmbracelet/ultraviolet v0.0.0-20260811164956-006e29f97886 // indirect
github.com/charmbracelet/x/ansi v0.11.8 // indirect
github.com/charmbracelet/x/term v0.2.2 // indirect
github.com/charmbracelet/x/termios v0.1.1 // indirect
github.com/charmbracelet/x/windows v0.2.2 // indirect
github.com/clipperhouse/displaywidth v0.11.0 // indirect
github.com/clipperhouse/uax29/v2 v2.7.0 // indirect
github.com/cncf/xds/go v0.0.0-20260202195803-dba9d589def2 // indirect
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
github.com/dlclark/regexp2/v2 v2.7.1 // indirect
github.com/docker/cli v29.7.2+incompatible // indirect
github.com/docker/docker-credential-helpers v0.9.3 // indirect
github.com/dominikbraun/graph v0.23.0 // indirect
github.com/dustin/go-humanize v1.0.1 // indirect
github.com/elliotchance/orderedmap/v3 v3.1.1 // indirect
github.com/envoyproxy/go-control-plane/envoy v1.39.0 // indirect
github.com/envoyproxy/protoc-gen-validate v1.3.3 // indirect
github.com/fatih/color v1.19.0 // indirect
github.com/felixge/httpsnoop v1.1.0 // indirect
github.com/fsnotify/fsnotify v1.10.1 // indirect
github.com/go-jose/go-jose/v4 v4.1.4 // indirect
github.com/go-logr/logr v1.4.4 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-task/slim-sprig/v3 v3.0.0 // indirect
github.com/go-task/task/v3 v3.53.1 // indirect
github.com/go-task/template v0.2.0 // indirect
github.com/google/go-containerregistry v0.22.1 // indirect
github.com/google/s2a-go v0.1.9 // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/googleapis/enterprise-certificate-proxy v0.3.20 // indirect
github.com/googleapis/gax-go/v2 v2.23.0 // indirect
github.com/hashicorp/aws-sdk-go-base/v2 v2.0.0-beta.74 // indirect
github.com/hashicorp/go-cleanhttp v0.5.2 // indirect
github.com/hashicorp/go-getter v1.8.8 // indirect
github.com/hashicorp/go-version v1.9.0 // indirect
github.com/joho/godotenv v1.5.1 // indirect
github.com/klauspost/compress v1.19.2 // indirect
github.com/klauspost/cpuid/v2 v2.4.0 // indirect
github.com/klauspost/pgzip v1.2.6 // indirect
github.com/lucasb-eyer/go-colorful v1.4.1 // indirect
github.com/mattn/go-colorable v0.1.15 // indirect
github.com/mattn/go-isatty v0.0.24 // indirect
github.com/mattn/go-runewidth v0.0.27 // indirect
github.com/mitchellh/go-homedir v1.1.0 // indirect
github.com/mitchellh/hashstructure/v2 v2.0.2 // indirect
github.com/muesli/cancelreader v0.2.2 // indirect
github.com/opencontainers/go-digest v1.0.0 // indirect
github.com/opencontainers/image-spec v1.1.1 // indirect
github.com/pierrec/lz4/v4 v4.1.27 // indirect
github.com/planetscale/vtprotobuf v0.6.1-0.20240319094008-0393e58bdf10 // indirect
github.com/puzpuzpuz/xsync/v4 v4.5.0 // indirect
github.com/rivo/uniseg v0.4.7 // indirect
github.com/sajari/fuzzy v1.0.0 // indirect
github.com/sirupsen/logrus v1.9.4 // indirect
github.com/spf13/pflag v1.0.10 // indirect
github.com/spiffe/go-spiffe/v2 v2.8.1 // indirect
github.com/spin-stack/go-tools v0.0.0-20261024185510-dfcf2c10f30b // indirect
github.com/stretchr/objx v0.5.3 // indirect
github.com/stretchr/testify v1.12.1 // indirect
github.com/u-root/u-root v0.16.0 // indirect
github.com/u-root/uio v0.0.0-20240224005618-d2acac8f3701 // indirect
github.com/ulikunitz/xz v0.5.16 // indirect
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e // indirect
github.com/zeebo/xxh3 v1.1.0 // indirect
go.opentelemetry.io/auto/sdk v1.2.1 // indirect
go.opentelemetry.io/contrib/detectors/gcp v1.45.0 // indirect
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.70.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.70.0 // indirect
go.opentelemetry.io/otel v1.45.0 // indirect
go.opentelemetry.io/otel/metric v1.45.0 // indirect
go.opentelemetry.io/otel/sdk v1.45.0 // indirect
go.opentelemetry.io/otel/sdk/metric v1.45.0 // indirect
go.opentelemetry.io/otel/trace v1.45.0 // indirect
go.yaml.in/yaml/v3 v3.0.5 // indirect
golang.org/x/crypto v0.58.0 // indirect
golang.org/x/net v0.61.0 // indirect
golang.org/x/oauth2 v0.36.0 // indirect
golang.org/x/sync v0.24.0 // indirect
golang.org/x/sys v0.49.0 // indirect
golang.org/x/term v0.47.0 // indirect
golang.org/x/text v0.43.0 // indirect
golang.org/x/time v0.15.0 // indirect
google.golang.org/api v0.293.0 // indirect
google.golang.org/genproto v0.0.0-20260724162435-b2f20204f0df // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20260724162435-b2f20204f0df // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20260807164820-c8921c73eeea // indirect
google.golang.org/grpc v1.83.0 // indirect
google.golang.org/protobuf v1.36.12 // indirect
mvdan.cc/sh/moreinterp v0.0.0-20260817215856-d6550df7ed8d // indirect
mvdan.cc/sh/v3 v3.13.2-0.20260817215856-d6550df7ed8d // indirect
)

tool (
github.com/go-task/task/v3/cmd/task
github.com/spin-stack/go-tools/cmd/sfw
github.com/spin-stack/go-tools/cmd/taskgate
)
Loading
Loading