tool

package
v0.0.0-...-238917c Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2024 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

AllAdoptionStages is used to export all the constant values to TS.

View Source
var AllAudienceValues = []Audience{
	Any,
	Chrome,
	ChromeOS,
	Android,
	PEEPSI,
	Skia,
}

AllAudienceValues is used to export all the constant values to TS.

View Source
var AllPhases = []Phase{
	GA,
	Deprecated,
	Preview,
}

AllPhases is used to export all the constant values to TS.

Functions

This section is empty.

Types

type AcceptingCustomers

type AcceptingCustomers string

AcceptingCustomers describes where the tool is in onboarding new users.

const (
	// AcceptingNo customers.
	AcceptingNo AcceptingCustomers = "No"

	// AcceptingSome customers.
	AcceptingSome AcceptingCustomers = "Conditionally"

	// AcceptingAll customers.
	AcceptingAll AcceptingCustomers = "All"
)

type Audience

type Audience string

Audience for the tool, i.e. the group of people that use a tool.

const (
	Any      Audience = "Any"
	Chrome   Audience = "Chrome"
	ChromeOS Audience = "ChromeOS"
	Android  Audience = "Android"
	PEEPSI   Audience = "PEEPSI"
	Skia     Audience = "Skia"
)

All Audiences

type Domain

type Domain string

Domain groups similar tools together.

const (
	Build       Domain = "Build"
	Debugging   Domain = "Debugging"
	Development Domain = "Development"
	Logging     Domain = "Logging"
	Other       Domain = "Other"
	Release     Domain = "Release"
	Security    Domain = "Security"
	Source      Domain = "Source"
	Testing     Domain = "Testing"
)

These are very general and a bit vauge, which is intenional.

type Phase

type Phase string

Phase of development the tool is in.

const (
	// GA is General Availability
	GA Phase = "GA"

	// Deprecated and should not be used.
	Deprecated Phase = "Deprecated"

	// Preview is unstable and not appropriate for GA usage.
	Preview Phase = "Preview"
)

type Tool

type Tool struct {
	// ID is a short, unique, name for this product to use internally, such as
	// for a filename.
	ID string `json:"id"`

	// Domain is a group of similar tooling functionality.
	Domain Domain `json:"domain"`

	// DisplayName of the tool in plain text.
	DisplayName string `json:"display_name"`

	// Description of the tool in plain text.
	Description string `json:"description"`

	// Phase of development that the tool is in.
	Phase Phase `json:"phase"`

	// TeamsID is the ID in the teams database.
	TeamsID string `json:"teams_id"`

	// CodePaths are links to where the code can be found.
	CodePaths []string `json:"code_path"`

	// Audience for the tool. That is, the pillars or groups of people that use
	// this tool.
	Audience []Audience `json:"audience"`

	// AdoptionStage for the tool in onboarding new users.
	AdoptionStage AcceptingCustomers `json:"adoption_stage"`

	// LandingPage URL.
	LandingPage string `json:"landing_page"`

	// Documentation maps a display name to URLs for documentation, FAQs, Getting Stated Guides, etc.
	Documentation map[string]string `json:"docs"`

	// Feedback maps a display name to URLs for providing feedback, such as Buganizer.
	Feedback map[string]string `json:"feedback"`

	// Resources maps a display name to URLs for resources that aren't either
	// Documentation or Feedback. For example, an announce-only email list, a
	// bug template to request a new instance, or a chat group.
	Resources map[string]string `json:"resources"`
}

Tool describes a single tool.

func FromJSON

func FromJSON(jsonBody []byte) (*Tool, []string, error)

FromJSON returns the deserialized JSON of a Tool.

If the JSON did not conform to the schema then a list of schema violations may be returned also.

func LoadAndValidateFromFS

func LoadAndValidateFromFS(fsys fs.FS) ([]*Tool, []string, error)

LoadAndValidateFromFS loads the files from the given FS and also validates them at the same time.

Directories

Path Synopsis
Program to generate JSON Schema definitions for the Tool struct.
Program to generate JSON Schema definitions for the Tool struct.

Jump to

Keyboard shortcuts

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