app

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	Config  *config.AppConfig
	Fetcher *subscription.Fetcher
	Engine  *core.Engine
}

App manages command workflows

func New

func New() (*App, error)

New creates a new initialized App

func (*App) RunCleanIP

func (a *App) RunCleanIP(ctx context.Context, count int) error

RunCleanIP scans Cloudflare clean IPs

func (*App) RunConnect

func (a *App) RunConnect(ctx context.Context, opts ConnectOptions) error

RunConnect handles automatic or filtered fast-pass connection or manual config link

func (*App) RunDisconnect

func (a *App) RunDisconnect() error

RunDisconnect stops any active session and restores proxy/DNS

func (*App) RunList

func (a *App) RunList(ctx context.Context, country, protocol string, systemProxy bool) error

RunList displays the interactive server selection TUI

func (*App) RunStatus

func (a *App) RunStatus() error

RunStatus prints current session status

func (*App) RunTest

func (a *App) RunTest(ctx context.Context, batchSize int, country, protocol string) error

RunTest benchmarks servers and prints the leaderboard

type ConnectOptions

type ConnectOptions struct {
	Country         string
	Protocol        string
	Mode            string
	FastPass        bool
	BatchSize       int
	UseCacheOnly    bool
	ManualURI       string
	PreselectedNode *model.ProxyNode
}

ConnectOptions contains flags for the connect command

Jump to

Keyboard shortcuts

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