schedulingunit

package
Version: v0.0.0-...-e560ebb Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2021 License: BSD-3-Clause Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AddSchedulingUnitCmd = &subcommands.Command{
	UsageLine: "schedulingunit",
	ShortDesc: "Add SchedulingUnit",
	LongDesc:  cmdhelp.AddSchedulingUnitLongDesc,
	CommandRun: func() subcommands.CommandRun {
		c := &addSchedulingUnit{
			pools: []string{},
			duts:  []string{},
			tags:  []string{},
		}
		c.authFlags.Register(&c.Flags, site.DefaultAuthOptions)
		c.envFlags.Register(&c.Flags)
		c.commonFlags.Register(&c.Flags)

		c.Flags.StringVar(&c.newSpecsFile, "f", "", cmdhelp.SchedulingUnitFileText)

		c.Flags.StringVar(&c.name, "name", "", "name of the SchedulingUnit")
		c.Flags.Var(utils.CSVString(&c.pools), "pools", "comma separated pools")
		c.Flags.Var(utils.CSVString(&c.duts), "duts", "comma separated DUTs")
		c.Flags.Var(utils.CSVString(&c.tags), "tags", "comma separated tags.")
		c.Flags.StringVar(&c.schedulingUnitType, "type", "all", "Type of SchedulingUnit. "+cmdhelp.SchedulingUnitTypesHelpText)
		c.Flags.StringVar(&c.description, "desc", "", "description for the SchedulingUnit")
		return c
	},
}

AddSchedulingUnitCmd add SchedulingUnit to the system.

View Source
var DeleteSchedulingUnitCmd = &subcommands.Command{
	UsageLine: "schedulingunit",
	ShortDesc: "Delete SchedulingUnit",
	LongDesc: `Delete SchedulingUnit.

Example:
shivas delete schedulingunit {SchedulingUnit Name}
Deletes the given SchedulingUnit. Multi-deletion in not supported.`,
	CommandRun: func() subcommands.CommandRun {
		c := &deleteSchedulingUnit{}
		c.authFlags.Register(&c.Flags, site.DefaultAuthOptions)
		c.envFlags.Register(&c.Flags)
		return c
	},
}

DeleteSchedulingUnitCmd delete SchedulingUnit by given name.

View Source
var GetSchedulingUnitCmd = &subcommands.Command{
	UsageLine: "schedulingunit ...",
	ShortDesc: "Get SchedulingUnit details by filters",
	LongDesc: `Get SchedulingUnit details by filters.

Example:

shivas get schedulingunit {name1} {name2}

shivas get schedulingunit -dut dut1

shivas get schedulingunit

Gets the SchedulingUnit and prints the output in the user-specified format.`,
	CommandRun: func() subcommands.CommandRun {
		c := &getSchedulingUnit{}
		c.authFlags.Register(&c.Flags, site.DefaultAuthOptions)
		c.envFlags.Register(&c.Flags)
		c.commonFlags.Register(&c.Flags)
		c.outputFlags.Register(&c.Flags)

		c.Flags.IntVar(&c.pageSize, "n", 0, cmdhelp.ListPageSizeDesc)
		c.Flags.BoolVar(&c.keysOnly, "keys", false, cmdhelp.KeysOnlyText)

		c.Flags.Var(flag.StringSlice(&c.types), "type", "Name(s) of a type to filter by. Can be specified multiple times."+cmdhelp.SchedulingUnitTypesHelpText)
		c.Flags.Var(flag.StringSlice(&c.duts), "duts", "Name(s) of a dut to filter by. Can be specified multiple times.")
		c.Flags.Var(flag.StringSlice(&c.pools), "pools", "Name(s) of a pool to filter by. Can be specified multiple times.")
		c.Flags.Var(flag.StringSlice(&c.tags), "tag", "Name(s) of a tag to filter by. Can be specified multiple times.")
		return c
	},
}

GetSchedulingUnitCmd get chrome platform by given name.

View Source
var UpdateSchedulingUnitCmd = &subcommands.Command{
	UsageLine: "SchedulingUnit [Options...]",
	ShortDesc: "Update a SchedulingUnit",
	LongDesc:  cmdhelp.UpdateSchedulingUnitLongDesc,
	CommandRun: func() subcommands.CommandRun {
		c := &updateSchedulingUnit{
			pools:       []string{},
			duts:        []string{},
			tags:        []string{},
			removePools: []string{},
			removeDuts:  []string{},
			removeTags:  []string{},
		}
		c.authFlags.Register(&c.Flags, site.DefaultAuthOptions)
		c.envFlags.Register(&c.Flags)
		c.commonFlags.Register(&c.Flags)

		c.Flags.StringVar(&c.newSpecsFile, "f", "", cmdhelp.SchedulingUnitUpdateFileText)

		c.Flags.StringVar(&c.name, "name", "", "name of the SchedulingUnit")
		c.Flags.Var(utils.CSVString(&c.pools), "pools", "append/clear comma separated pools. "+cmdhelp.ClearFieldHelpText)
		c.Flags.Var(utils.CSVString(&c.duts), "duts", "append/clear comma separated DUTs. "+cmdhelp.ClearFieldHelpText)
		c.Flags.Var(utils.CSVString(&c.tags), "tags", "append/clear comma separated tags. "+cmdhelp.ClearFieldHelpText)
		c.Flags.Var(utils.CSVString(&c.removePools), "pools-to-remove", "remove comma separated pools.")
		c.Flags.Var(utils.CSVString(&c.removeDuts), "duts-to-remove", "remove comma separated DUTs.")
		c.Flags.Var(utils.CSVString(&c.removeTags), "tags-to-remove", "remove comma separated tags.")
		c.Flags.StringVar(&c.schedulingUnitType, "type", "", "Type of SchedulingUnit. "+cmdhelp.SchedulingUnitTypesHelpText)
		c.Flags.StringVar(&c.description, "desc", "", "description for the SchedulingUnit")
		return c
	},
}

UpdateSchedulingUnitCmd Update SchedulingUnit by given name.

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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