-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Description
Issue Description
In taskfiles/utils-remote.yaml, the download-and-extract-tar task has a parameter NUM_COMPONENTS_TO_STRIP with a default value of 1. However, due to sprig's default function treating numeric 0 as an empty value, explicitly setting NUM_COMPONENTS_TO_STRIP=0 results in 1 being used instead.
Reference: https://masterminds.github.io/sprig/defaults.html#default
Workaround
Users can specify NUM_COMPONENTS_TO_STRIP="0" (as a string) in the caller to work around this issue.
Potential Solutions
- Change the default value to 0
- Check if the user explicitly specifies the var; only if the var is not specified, default to 1
- Document the behavior and mitigation/expected usage explicitly
Context
Metadata
Metadata
Assignees
Labels
No labels