Replies: 19 comments 17 replies
-
Hi @HavenDV - we don't have any immediately plans here. Can you tell me a little more about how you envision using arrays? I'd love to understand your use case a little bit better. |
Beta Was this translation helpful? Give feedback.
-
Another good usecase is self hosted runners + reusable workflows. I want to pass the "run-on" to the reusable workflow and in case of self-hosted I have to pass at least 2 items. Not having a list type makes this task a bit tricky. |
Beta Was this translation helpful? Give feedback.
-
another use case we found while configuring cypress was the matrix parameter for on how many instances this is supposed to run
|
Beta Was this translation helpful? Give feedback.
-
In my case, I need comma-separated values dynamically from the Manual triggering workflow. So here is my solution
|
Beta Was this translation helpful? Give feedback.
-
I have an dumb but solvable solution case You can input arrays that use double and single quotes: workflow_call:
inputs:
runs-on:
default: "['ubuntu-latest']"
required: false
type: string then use strategy:
matrix:
os: ${{ fromJson(inputs.runs-on) }}
runs-on: ${{ matrix.os }}
That'll work, but this should be a problem that GitHub needs to solve.🤨 |
Beta Was this translation helpful? Give feedback.
-
Hi @ethomson |
Beta Was this translation helpful? Give feedback.
-
I was looking for this in the docs. Guess it's still not an option, so I'm either going to have to run the called workflow |
Beta Was this translation helpful? Give feedback.
-
My usecase is a bit different I have a custom action which will delete the current folder after the jobs runs, this is because we are using a persistent instance as a runner. I would love to be able to add an input that will be an array of directories, that array will be defined by the workflow where I'm calling this action from and used inside the action to delete the desired folders. |
Beta Was this translation helpful? Give feedback.
-
Today, I have an Atlas Operator re-useable workflow that takes in a handful of inputs. It updates the appropriate manifests via Kustomize based on said inputs, but given the general nature of workflows, we can only make one deployment update per workflow run. What would be ideal is if I could define this I realize this is where I may be in the wrong place.. so please redirect me if so Now, I realize I can (and am actively working on such) pass an array of said |
Beta Was this translation helpful? Give feedback.
-
@ethomson It has been a year and a half since the ticket was created, and the community has provided incredibly valuable feedback. We're eager to know if there have been any developments in this regard, or if there are any plans to extend support for list-type (perhaps even dictionary-type) inputs. |
Beta Was this translation helpful? Give feedback.
-
Hi. Any update on this? This discussion has plenty of good use cases, and the workarounds are all pretty clunky. Would be great to get this feature properly supported. |
Beta Was this translation helpful? Give feedback.
-
+1 for array as an input. My use case is also passing multiple args to docker build as mentioned above. There are workarounds but they are errorprone and hacky. |
Beta Was this translation helpful? Give feedback.
-
Any update on getting this feature supported? I implemented an "array type" via the workarounds shared here, but it's not perfect by any means. Using a combination of the existing string type and the
|
Beta Was this translation helpful? Give feedback.
-
The |
Beta Was this translation helpful? Give feedback.
-
+1 for arrays as input parameters . we are building reusable workflows for our platform users and without this feature we are losing the readability and usability of the re-usable workflow. the goal is to pass n strings as input to a task inside a job that prepares an artifact and upload to github artefacts. |
Beta Was this translation helpful? Give feedback.
-
Will be any work on this @ethomson? I think this will make reusable workflows way better. I suggest the following syntax:
|
Beta Was this translation helpful? Give feedback.
-
💬 Your Product Feedback Has Been Submitted 🎉 Thank you for taking the time to share your insights with us! Your feedback is invaluable as we build a better GitHub experience for all our users. Here's what you can expect moving forward ⏩
Where to look to see what's shipping 👀
What you can do in the meantime 💻
As a member of the GitHub community, your participation is essential. While we can't promise that every suggestion will be implemented, we want to emphasize that your feedback is instrumental in guiding our decisions and priorities. Thank you once again for your contribution to making GitHub even better! We're grateful for your ongoing support and collaboration in shaping the future of our platform. ⭐ |
Beta Was this translation helpful? Give feedback.
-
Hello! Sorry Actions product has been quiet here, this is cool feedback and the use case makes sense. We are currently reviewing re-usability all up in Actions (this + composite Action feedback + yaml anchor feedback) to work out how we get all these things right and move forward in a way that works for y'all. I will ensure that we include this in what we are thinking as one of the items. Thank you for all engaging over such a long period and please keep sharing your feedback, we do read the comments and what your use cases our help us build a better product <3 |
Beta Was this translation helpful? Give feedback.
-
I agree that it would be great to define the input type as string, list, etc. A workaround while waiting for GitHub to update the functionality. Instead of a one-liner list... inputs:
my_paramater: "['value1', 'value2', 'value3']" ... the end-user can use the greater than character inputs:
my_paramater: >
"['value1',
'value2',
'value3']" |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Is there any plan to support arrays for reusable workflow? I mean this - https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#onworkflow_callinputsinput_idtype
Beta Was this translation helpful? Give feedback.
All reactions