Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add outputList template function #4255

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

halostatue
Copy link
Collaborator

Resolves #4253

@halostatue
Copy link
Collaborator Author

halostatue commented Feb 4, 2025

This is mostly a proof of concept, but if the limitations list … | toStrings is acceptable, then I think we're OK. Otherwise, we'll need to essentially implement toStrings internally to outputList.

I’m also not particularly fond of the name. However, I have been able to run the template in #4253 successfully:

$ go run . execute-template \
  '{{- $opts := dict
        "show-help" true
        "ordered" true
        "no-limit" true
        "header" "Choose a movie poison"
        "options" (list "cyanide" "arsenic" "iocaine powder") 
  -}}{{ includeTemplate "multichoice.tmpl" $opts }}'
["arsenic","iocaine powder"]

@halostatue halostatue force-pushed the output-list-template-function branch from d47255a to ce88aac Compare February 4, 2025 01:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

outputList template function
1 participant