Replies: 15 comments 14 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.
-
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