cmd

package
v1.0.9 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2023 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Copyright © 2023 Hritik Pihal <hritikpihal51299@gmail.com>

add command is used after family-tree to add a new person and store it. It is also used to add a new relation and store it. The format goes like family-tree add <sub-Command> <name>

This command specifies the type of relation between two given person. The syntax goes like <Person1> as <Relation> of <Person2>.

This command is used to connect two different person with a relation. It uses subcommands such as "as" and "of" to specify relation and direction of the relation.

This command is used to count the number of relatives with the specified relation of a person. The format for the command is family-tree count <relation> of <person>

This command is used to get all the relatives with the specified relation for a person. The syntax for the command is as follows family-tree get <relation> of <Person>

This command is used to declare the direction of the relation defined between two people. It is subcommand for commands like connect and get. The syntax for the command is family-tree <pre-command> ... <relation> of <Person>

This command is used to create a new person entity. It is the subcommand for add command. The format for this command id family-tree add person <personName> -g <male/female>

This command is used to create a new relation entity. It is the subcommand for add command. The format for this command id family-tree add relation <personName> -g <male/female>

This is the root command for family-tree CLI

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

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

This section is empty.

Jump to

Keyboard shortcuts

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