tutorial

package
v1.0.7 Latest Latest
Warning

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

Go to latest
Published: May 26, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RunTutorial

func RunTutorial(options *TutorialOptions) error

RunTutorial runs the tutorial with the given options

Types

type Tutorial

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

Tutorial represents the tutorial

func NewTutorial

func NewTutorial(options *TutorialOptions) *Tutorial

NewTutorial creates a new tutorial

func (*Tutorial) Run

func (t *Tutorial) Run() error

Run runs the tutorial

type TutorialOptions

type TutorialOptions struct {
	// Interactive enables interactive mode
	Interactive bool

	// SkipAuth skips the authentication section
	SkipAuth bool

	// SkipBasics skips the basics section
	SkipBasics bool

	// SkipAdvanced skips the advanced section
	SkipAdvanced bool

	// Theme sets the color theme
	Theme string

	// NoColor disables color output
	NoColor bool

	// Width sets the width of the tutorial
	Width int

	// Height sets the height of the tutorial
	Height int
}

TutorialOptions contains options for the tutorial

func DefaultTutorialOptions

func DefaultTutorialOptions() *TutorialOptions

DefaultTutorialOptions returns the default tutorial options

type TutorialStep

type TutorialStep struct {
	Title       string
	Description string
	Example     string
	Action      func() error
}

TutorialStep represents a step in the tutorial

Jump to

Keyboard shortcuts

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