cmd

package
v0.0.0-...-0d778e4 Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2020 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var NumberToWord = map[int]string{
	1:  "one",
	2:  "two",
	3:  "three",
	4:  "four",
	5:  "five",
	6:  "six",
	7:  "seven",
	8:  "eight",
	9:  "nine",
	10: "ten",
	11: "eleven",
	12: "twelve",
	13: "thirteen",
	14: "fourteen",
	15: "fifteen",
	16: "sixteen",
	17: "seventeen",
	18: "eighteen",
	19: "nineteen",
	20: "twenty",
	30: "thirty",
	40: "forty",
	50: "fifty",
	60: "sixty",
	70: "seventy",
	80: "eighty",
	90: "ninety",
}

NumberToWord contains the english word representing the number

Functions

func ConvertNumToWord

func ConvertNumToWord(n int) (w string)

ConvertNumToWord converts a non-negative integer to its english equivalent

func Execute

func Execute()

Execute adds all child commands to the root command and sets flags appropriately. This is called by main.main(). It only needs to happen once to the rootCmd.

Types

type BlogEntry

type BlogEntry struct {
	ID       string
	Date     time.Time
	Author   string
	Title    string
	Subtitle string
	Tags     []string
}

BlogEntry represents a single post to the blog

type Book

type Book struct {
	Title     string
	Subtitle  string
	Published string
	Authors   []string
	Chapters  []*Chapter
}

Book represents the book getting created

type Chapter

type Chapter struct {
	Number string
	Name   string
	File   string
	Link   string
	Links  []string
}

Chapter represents a chapter in a book

type Config

type Config struct {
	FullName string      `yaml:"fullname"`
	Paths    ConfigPaths `yaml:"paths"`
}

Config contains all configurations required for note to run

type ConfigPaths

type ConfigPaths struct {
	Base    string `yaml:"base"`
	Blog    string `yaml:"blog"`
	Book    string `yaml:"book"`
	Morning string `yaml:"morning"`
	Meeting string `yaml:"meeting"`
}

type Meeting

type Meeting struct {
	Date         time.Time
	Title        string
	Author       string
	Agenda       []string
	Participants []string
}

Meeting is a meet pages entry

type Morning

type Morning struct {
	Date   time.Time
	Author string
}

Morning is a morning pages entry

Jump to

Keyboard shortcuts

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