Replies: 6 comments
-
I fully support this proposal. Adding the ability to use variables within the working-directory field in the defaults section of GitHub Actions workflows would significantly enhance their flexibility and reusability. Currently, we can't dynamically set the working directory using variables, which leads to redundancy and less maintainable workflows. Implementing this feature would be particularly beneficial for users who manage multiple directories or environments, allowing for a more dynamic and adaptable workflow setup. This enhancement would undoubtedly improve the overall efficiency of GitHub Actions. |
Beta Was this translation helpful? Give feedback.
-
This fix is highly needed. |
Beta Was this translation helpful? Give feedback.
-
🕒 Discussion Activity Reminder 🕒 This Discussion has been labeled as dormant by an automated system for having no activity in the last 60 days. Please consider one the following actions: 1️⃣ Close as Out of Date: If the topic is no longer relevant, close the Discussion as 2️⃣ Provide More Information: Share additional details or context — or let the community know if you've found a solution on your own. 3️⃣ Mark a Reply as Answer: If your question has been answered by a reply, mark the most helpful reply as the solution. Note: This dormant notification will only apply to Discussions with the Thank you for helping bring this Discussion to a resolution! 💬 |
Beta Was this translation helpful? Give feedback.
-
According to the docs for contexts availability,
So yes currently it's impossible to use any contexts in the top-level |
Beta Was this translation helpful? Give feedback.
-
🕒 Discussion Activity Reminder 🕒 This Discussion has been labeled as dormant by an automated system for having no activity in the last 60 days. Please consider one the following actions: 1️⃣ Close as Out of Date: If the topic is no longer relevant, close the Discussion as 2️⃣ Provide More Information: Share additional details or context — or let the community know if you've found a solution on your own. 3️⃣ Mark a Reply as Answer: If your question has been answered by a reply, mark the most helpful reply as the solution. Note: This dormant notification will only apply to Discussions with the Thank you for helping bring this Discussion to a resolution! 💬 |
Beta Was this translation helpful? Give feedback.
-
Is there an intention to work on this feature? |
Beta Was this translation helpful? Give feedback.
-
Select Topic Area
General
Body
I would like to propose an enhancement to the GitHub Actions workflow syntax that enables variable replacement within the working-directory field under the defaults section. Specifically, the ability to use a variable like ${{ var_dir_name }} within the path would significantly enhance the flexibility and reusability of workflows.
Currently, the following does not work:
Currently, setting a dynamic working directory using variables is not supported directly in the defaults section. Implementing this feature would streamline workflows where the working directory needs to be dynamically set based on the context or environment, reducing redundancy and making the workflows more maintainable.
This feature would benefit users who manage multiple directories or environments and require a more dynamic and adaptable workflow setup.
Beta Was this translation helpful? Give feedback.
All reactions