args

package
v0.0.0-...-6e8f4b0 Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Parse

func Parse(args []string, usage func()) (saveType, itemType string, code int)

Parse will process an argument slice of the form: <favorite|upvoted> <submissions|comments> If the arguments do not conform to the above format, then the usage function will be used to print instructions to the screen, and code 2 will be returned. If one of the arguments is -h or -help, then the usage instructions will be printed, and code 0 will be returned. Otherwise, the correct save type and item type will be returned, along with code -1.

Types

This section is empty.

Jump to

Keyboard shortcuts

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