session.go

 1package session
 2
 3import (
 4	tea "github.com/charmbracelet/bubbletea"
 5	appCfg "github.com/charmbracelet/soft-serve/config"
 6	"github.com/gliderlabs/ssh"
 7)
 8
 9// Session is a interface representing a UI session.
10type Session interface {
11	// Send sends a message to the parent Bubble Tea program.
12	Send(tea.Msg)
13	// Config returns the app configuration.
14	Config() *appCfg.Config
15	// PublicKey returns the public key of the user.
16	PublicKey() ssh.PublicKey
17}