Skip to content

Commit

Permalink
Allows env and tags flag passing into validate command
Browse files Browse the repository at this point in the history
Signed-off-by: Haroon Sheikh <haroon.sheikh@outlook.com>
Signed-off-by: Haroon Sheikh <haroon.sheikh@sky.uk>
  • Loading branch information
haroon-sheikh committed Mar 25, 2024
1 parent 0fd376c commit cdf1a42
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
13 changes: 8 additions & 5 deletions cmd/validate.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,11 @@ const (

var (
validateCmd = &cobra.Command{
Use: "validate [flags] [args]",
Short: "Check for validation and parse errors",
Long: `Check for validation and parse errors.`,
Example: " gauge validate specs/",
Use: "validate [flags] [args]",
Short: "Check for validation and parse errors",
Long: `Check for validation and parse errors.`,
Example: ` gauge validate specs/
gauge validate --env test specs/`,
Run: func(cmd *cobra.Command, args []string) {
validation.HideSuggestion = hideSuggestion
if err := config.SetProjectRoot(args); err != nil {
Expand All @@ -39,5 +40,7 @@ var (

func init() {
GaugeCmd.AddCommand(validateCmd)
validateCmd.Flags().BoolVarP(&hideSuggestion, "hide-suggestion", "", false, "Prints a step implementation stub for every unimplemented step")
flags := validateCmd.Flags()
flags.BoolVarP(&hideSuggestion, "hide-suggestion", "", false, "Prints a step implementation stub for every unimplemented step")
flags.StringVarP(&environment, environmentName, "e", environmentDefault, "Specifies the environment to use")
}
2 changes: 1 addition & 1 deletion version/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
)

// CurrentGaugeVersion represents the current version of Gauge
var CurrentGaugeVersion = &Version{1, 6, 4}
var CurrentGaugeVersion = &Version{1, 6, 5}

// BuildMetadata represents build information of current release (e.g, nightly build information)
var BuildMetadata = ""
Expand Down

0 comments on commit cdf1a42

Please sign in to comment.