chroma

package
v0.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 18, 2026 License: Apache-2.0 Imports: 5 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package chroma finds the colourways in jane's chroma repository on GitHub: the .css files of its colourways/sources folder, on its main branch.

GitHub's contents API lists the folder as JSON, each file with its name and the address it is downloaded from. The listing is asked at fetch time, so a colourway added to the repository is found with no change here.

GitHub limits an address that sends no token to sixty questions an hour. A fetch asks one.

The repository is public. This package only fetches to the machine it runs on.

The archive holds the same files wherever it is asked, and is asked only by name.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Colourways

type Colourways struct {
	// contains filtered or unexported fields
}

Colourways is the chroma repository's colourways at GitHub.

func New

func New(get web.Web) (*Colourways, error)

New is the colourways asked through get. It refuses no web.

func (*Colourways) ByNameOnly

func (*Colourways) ByNameOnly() bool

ByNameOnly says the archive is asked only when it is named: what it holds does not depend on a place in the sky.

func (*Colourways) Find

func (colours *Colourways) Find(*celestialdata.Near) (
	[]*celestialdata.Product, error)

Find is every .css file GitHub lists in the folder, whatever the circle. A listing of none is an error, since the folder is not the one that was meant. An entry that is not a file, is not a .css file, has no address, or is not one plain file name is passed over.

func (*Colourways) Name

func (colours *Colourways) Name() string

Name is the adapter's name as the command line takes it.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL