Skip to content

Flag '-output-dir' printed both with one and two hyphens #12

Description

@urban-adeininger

I'm running this command:

$ hedgerules deploy
error: output-dir is required (set in config file or via --output-dir)

The error text mentions flag --output-dir (two hyphens)

However, the online help prints out --output-dir (one hyphen only)

$ hedgerules deploy -h
Usage of deploy:
  -config string
        path to config file (default "hedgerules.toml")
  -debug-headers
        inject debug headers into viewer-response function
  -dry-run
        parse and validate only, print plan
  -headers-kvs-name string
        CloudFront KVS name for headers
  -max-retries int
        max AWS throttle retries (default 10, 0 disables retries) (default -1)
  -output-dir string
        Hugo build output directory
  -redirects-kvs-name string
        CloudFront KVS name for redirects
  -region string
        AWS region override
  -request-function-name string
        CloudFront Function name for viewer-request
  -response-function-name string
        CloudFront Function name for viewer-response

ToDo: the number of hypens needed should be handled consistently across all execution paths of the program.

The same applies to flag --redirects-kvs-name, maybe other flags are affected, too.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions