msg

package
v0.0.0-...-dbe350a Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2025 License: MIT Imports: 38 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ARCHIVE_FLAT  = "flat"
	ARCHIVE_YEAR  = "year"
	ARCHIVE_MONTH = "month"
)

Variables

Functions

This section is empty.

Types

type Archive

type Archive struct {
	MultiFileStrategy *types.MultiFileStrategy `opt:"-m" action:"ParseMFS" complete:"CompleteMFS" desc:"Multi-file strategy."`
	Type              string                   `opt:"type" action:"ParseArchiveType" metavar:"flat|year|month" complete:"CompleteType" desc:"Archiving scheme."`
}

func (Archive) Aliases

func (Archive) Aliases() []string

func (Archive) CompleteMFS

func (Archive) CompleteMFS(arg string) []string

func (*Archive) CompleteType

func (*Archive) CompleteType(arg string) []string

func (Archive) Context

func (Archive) Context() commands.CommandContext

func (Archive) Description

func (Archive) Description() string

func (Archive) Execute

func (a Archive) Execute(args []string) error

func (*Archive) ParseArchiveType

func (a *Archive) ParseArchiveType(arg string) error

func (*Archive) ParseMFS

func (a *Archive) ParseMFS(arg string) error

type Bounce

type Bounce struct {
	Account string   `opt:"-A" complete:"CompleteAccount" desc:"Account from which to re-send the message."`
	To      []string `opt:"..." required:"true" complete:"CompleteTo" desc:"Recipient from address book."`
}

func (Bounce) Aliases

func (Bounce) Aliases() []string

func (*Bounce) CompleteAccount

func (*Bounce) CompleteAccount(arg string) []string

func (*Bounce) CompleteTo

func (*Bounce) CompleteTo(arg string) []string

func (Bounce) Context

func (Bounce) Context() commands.CommandContext

func (Bounce) Description

func (Bounce) Description() string

func (Bounce) Execute

func (b Bounce) Execute(args []string) error

type Copy

type Copy struct {
	CreateFolders     bool                     `opt:"-p" desc:"Create folder if it does not exist."`
	Decrypt           bool                     `opt:"-d" desc:"Decrypt the message before copying."`
	Account           string                   `opt:"-a" complete:"CompleteAccount" desc:"Copy to the specified account."`
	MultiFileStrategy *types.MultiFileStrategy `opt:"-m" action:"ParseMFS" complete:"CompleteMFS" desc:"Multi-file strategy."`
	Folder            string                   `opt:"folder" complete:"CompleteFolder" desc:"Target folder."`
}

func (Copy) Aliases

func (Copy) Aliases() []string

func (Copy) CallBack

func (c Copy) CallBack(msg types.WorkerMessage, uids []models.UID, store *lib.MessageStore)

func (*Copy) CompleteAccount

func (*Copy) CompleteAccount(arg string) []string

func (*Copy) CompleteFolder

func (c *Copy) CompleteFolder(arg string) []string

func (Copy) CompleteMFS

func (Copy) CompleteMFS(arg string) []string

func (Copy) Context

func (Copy) Context() commands.CommandContext

func (Copy) Description

func (Copy) Description() string

func (Copy) Execute

func (c Copy) Execute(args []string) error

func (*Copy) ParseMFS

func (c *Copy) ParseMFS(arg string) error

type Delete

type Delete struct {
	MultiFileStrategy *types.MultiFileStrategy `opt:"-m" action:"ParseMFS" complete:"CompleteMFS" desc:"Multi-file strategy."`
}

func (Delete) Aliases

func (Delete) Aliases() []string

func (Delete) CompleteMFS

func (Delete) CompleteMFS(arg string) []string

func (Delete) Context

func (Delete) Context() commands.CommandContext

func (Delete) Description

func (Delete) Description() string

func (Delete) Execute

func (d Delete) Execute(args []string) error

func (*Delete) ParseMFS

func (d *Delete) ParseMFS(arg string) error

type Envelope

type Envelope struct {
	Header bool   `opt:"-h" desc:"Show all header fields."`
	Format string `opt:"-s" default:"%-20.20s: %s" desc:"Format specifier."`
}

func (Envelope) Aliases

func (Envelope) Aliases() []string

func (Envelope) Context

func (Envelope) Context() commands.CommandContext

func (Envelope) Description

func (Envelope) Description() string

func (Envelope) Execute

func (e Envelope) Execute(args []string) error

type FlagMsg

type FlagMsg struct {
	Toggle    bool         `opt:"-t" desc:"Toggle between set and unset."`
	Answered  bool         `opt:"-a" aliases:"flag,unflag" desc:"Set/unset the answered flag."`
	Forwarded bool         `opt:"-f" aliases:"flag,unflag" desc:"Set/unset the forwarded flag."`
	Flag      models.Flags `opt:"-x" aliases:"flag,unflag" action:"ParseFlag" complete:"CompleteFlag" desc:"Flag name."`
	FlagName  string
}

func (FlagMsg) Aliases

func (FlagMsg) Aliases() []string

func (*FlagMsg) CompleteFlag

func (*FlagMsg) CompleteFlag(arg string) []string

func (FlagMsg) Context

func (FlagMsg) Context() commands.CommandContext

func (FlagMsg) Description

func (FlagMsg) Description() string

func (FlagMsg) Execute

func (f FlagMsg) Execute(args []string) error

If this was called as 'flag' or 'unflag', without the toggle (-t) option, then it will flag the corresponding messages with the given flag. If the toggle option was given, it will individually toggle the given flag for the corresponding messages.

If this was called as 'read' or 'unread', it has the same effect as 'flag' or 'unflag', respectively, but the 'Seen' flag is affected.

func (*FlagMsg) ParseFlag

func (f *FlagMsg) ParseFlag(arg string) error

type Fold

type Fold struct {
	All    bool `opt:"-a" desc:"Fold/unfold all threads."`
	Toggle bool `opt:"-t" desc:"Toggle between folded/unfolded."`
}

func (Fold) Aliases

func (Fold) Aliases() []string

func (Fold) Context

func (Fold) Context() commands.CommandContext

func (Fold) Description

func (Fold) Description() string

func (Fold) Execute

func (f Fold) Execute(args []string) error

type Mark

type Mark struct {
	All         bool `opt:"-a" aliases:"mark,unmark" desc:"Mark all messages in current folder."`
	Toggle      bool `opt:"-t" aliases:"mark,unmark" desc:"Toggle the marked state."`
	Visual      bool `opt:"-v" aliases:"mark,unmark" desc:"Enter / leave visual mark mode."`
	VisualClear bool `opt:"-V" aliases:"mark,unmark" desc:"Same as -v but does not clear existing selection."`
	Thread      bool `opt:"-T" aliases:"mark,unmark" desc:"Mark all messages from the selected thread."`
}

func (Mark) Aliases

func (Mark) Aliases() []string

func (Mark) Context

func (Mark) Context() commands.CommandContext

func (Mark) Description

func (Mark) Description() string

func (Mark) Execute

func (m Mark) Execute(args []string) error

type ModifyLabels

type ModifyLabels struct {
	Labels []string `opt:"..." metavar:"[+-]<label>" complete:"CompleteLabels" desc:"Message label."`
}

func (ModifyLabels) Aliases

func (ModifyLabels) Aliases() []string

func (*ModifyLabels) CompleteLabels

func (*ModifyLabels) CompleteLabels(arg string) []string

func (ModifyLabels) Context

func (ModifyLabels) Description

func (ModifyLabels) Description() string

func (ModifyLabels) Execute

func (m ModifyLabels) Execute(args []string) error

type Move

type Move struct {
	CreateFolders     bool                     `opt:"-p" desc:"Create missing folders if required."`
	Account           string                   `opt:"-a" complete:"CompleteAccount" desc:"Move to specified account."`
	MultiFileStrategy *types.MultiFileStrategy `opt:"-m" action:"ParseMFS" complete:"CompleteMFS" desc:"Multi-file strategy."`
	Folder            string                   `opt:"folder" complete:"CompleteFolder" desc:"Target folder."`
}

func (Move) Aliases

func (Move) Aliases() []string

func (Move) CallBack

func (m Move) CallBack(
	msg types.WorkerMessage,
	acct *app.AccountView,
	uids []models.UID,
	next *models.MessageInfo,
	marker marker.Marker,
	timeout bool,
)

func (*Move) CompleteAccount

func (*Move) CompleteAccount(arg string) []string

func (*Move) CompleteFolder

func (m *Move) CompleteFolder(arg string) []string

func (Move) CompleteMFS

func (Move) CompleteMFS(arg string) []string

func (Move) Context

func (Move) Context() commands.CommandContext

func (Move) Description

func (Move) Description() string

func (Move) Execute

func (m Move) Execute(args []string) error

func (*Move) ParseMFS

func (m *Move) ParseMFS(arg string) error

type Pipe

type Pipe struct {
	Background bool   `opt:"-b" desc:"Run the command in the background."`
	Silent     bool   `opt:"-s" desc:"Silently close the terminal tab after the command exits."`
	Full       bool   `opt:"-m" desc:"Pipe the full message."`
	Decrypt    bool   `opt:"-d" desc:"Decrypt the full message before piping."`
	Part       bool   `opt:"-p" desc:"Only pipe the selected message part."`
	Command    string `opt:"..."`
}

func (Pipe) Aliases

func (Pipe) Aliases() []string

func (Pipe) Context

func (Pipe) Context() commands.CommandContext

func (Pipe) Description

func (Pipe) Description() string

func (Pipe) Execute

func (p Pipe) Execute(args []string) error

func (Pipe) Run

func (p Pipe) Run(cb func()) error

type Recall

type Recall struct {
	Force      bool `opt:"-f" desc:"Force recall if not in postpone directory."`
	Edit       bool `opt:"-e" desc:"Force [compose].edit-headers = true."`
	NoEdit     bool `opt:"-E" desc:"Force [compose].edit-headers = false."`
	SkipEditor bool `opt:"-s" desc:"Skip the editor and go directly to the review screen."`
}

func (Recall) Aliases

func (Recall) Aliases() []string

func (Recall) Context

func (Recall) Context() commands.CommandContext

func (Recall) Description

func (Recall) Description() string

func (Recall) Execute

func (r Recall) Execute(args []string) error

type ToggleThreadContext

type ToggleThreadContext struct{}

func (ToggleThreadContext) Aliases

func (ToggleThreadContext) Aliases() []string

func (ToggleThreadContext) Context

func (ToggleThreadContext) Description

func (ToggleThreadContext) Description() string

func (ToggleThreadContext) Execute

func (ToggleThreadContext) Execute(args []string) error

type ToggleThreads

type ToggleThreads struct{}

func (ToggleThreads) Aliases

func (ToggleThreads) Aliases() []string

func (ToggleThreads) Context

func (ToggleThreads) Description

func (ToggleThreads) Description() string

func (ToggleThreads) Execute

func (ToggleThreads) Execute(args []string) error

type Unsubscribe

type Unsubscribe struct {
	Edit       bool `opt:"-e" desc:"Force [compose].edit-headers = true."`
	NoEdit     bool `opt:"-E" desc:"Force [compose].edit-headers = false."`
	SkipEditor bool `opt:"-s" desc:"Skip the editor and go directly to the review screen."`
}

Unsubscribe helps people unsubscribe from mailing lists by way of the List-Unsubscribe header.

func (Unsubscribe) Aliases

func (Unsubscribe) Aliases() []string

Aliases returns a list of aliases for the :unsubscribe command

func (Unsubscribe) Context

func (Unsubscribe) Description

func (Unsubscribe) Description() string

func (Unsubscribe) Execute

func (u Unsubscribe) Execute(args []string) error

Execute runs the Unsubscribe command

Jump to

Keyboard shortcuts

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