mirror of
https://github.com/hauler-dev/hauler.git
synced 2026-02-14 09:59:50 +00:00
* added env variables for haulerDir/tempDir
* updated hauler directory for the install script
* cleanup/fixes for install script
* updated variables based on feedback
* revert "updated variables based on feedback"
* reverts commit 54f7a4d695
* minor restructure to root flags
* updated logic to include haulerdir flag
* cleaned up/formatted new logic
* more cleanup and formatting
20 lines
511 B
Go
20 lines
511 B
Go
package flags
|
|
|
|
import (
|
|
"github.com/spf13/cobra"
|
|
"hauler.dev/go/hauler/pkg/consts"
|
|
)
|
|
|
|
type SaveOpts struct {
|
|
*StoreRootOpts
|
|
FileName string
|
|
Platform string
|
|
}
|
|
|
|
func (o *SaveOpts) AddFlags(cmd *cobra.Command) {
|
|
f := cmd.Flags()
|
|
|
|
f.StringVarP(&o.FileName, "filename", "f", consts.DefaultHaulArchiveName, "(Optional) Specify the name of outputted archive")
|
|
f.StringVarP(&o.Platform, "platform", "p", "", "(Optional) Specify the platform for runtime imports... i.e. linux/amd64 (unspecified implies all)")
|
|
}
|