flags

package
v1.7.1 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2017 License: MIT Imports: 5 Imported by: 1

Documentation

Overview

Package flags defines flag types that can be used with the default flag package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Intlist

func Intlist(name, usage string, min, max int) func() []int

Intlist defines a flag for a comma-separated list of integers. min and max restrict the size of the integer values. Call the returned function after flag.Parse to get the value.

func Monthlist

func Monthlist(name string) func() []time.Month

Monthlist defines a flag for a comma-separated list of months. Valid values are between 1 and 12. Call the returned function after flag.Parse to get the value.

func Weekdaylist

func Weekdaylist(name string) func() []time.Weekday

Weekdaylist defines a flag for a comma-separated list of week days. Valid values are mo, tu, we, th, fr, sa, su. Call the returned function after flag.Parse to get the value.

func Yearlist

func Yearlist(name string) func() []int

Yearlist defines a flag for a comma-separated list of integers. Call the returned function after flag.Parse to get the value.

Types

This section is empty.

Jump to

Keyboard shortcuts

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