Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ExportCmd = &cobra.Command{ Use: "export", Short: "Exports organization and repository variables to CSV", Long: "Exports organization and repository variables to CSV", Run: func(cmd *cobra.Command, args []string) { GetFlagOrViperValue(cmd, map[string]bool{ "source-hostname": false, "source-organization": true, "source-token": true, "search-depth": false, }) ShowConnectionStatus("export") if err := export.ExportVariables(); err != nil { fmt.Printf("failed to export variables: %v\n", err) } return }, }
exportCmd represents the export command
View Source
var SyncCmd = &cobra.Command{ Use: "sync", Short: "Sync organization and repository variables from CSV", Long: "Sync organization and repository variables from CSV", Run: func(cmd *cobra.Command, args []string) { GetFlagOrViperValue(cmd, map[string]bool{ "file": true, "target-hostname": false, "target-organization": true, "target-token": true, }) ShowConnectionStatus("sync") if err := sync.SyncVariables(); err != nil { fmt.Printf("failed to export variables: %v\n", err) } return }, }
Functions ¶
func GetFlagOrViperValue ¶
func ShowConnectionStatus ¶
func ShowConnectionStatus(actionType string)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.