Help
cancel
Showing results for 
Search instead for 
Did you mean: 
Copilot Lvl 2
Message 1 of 5

Nested workflows in GitHub actions

I have some pretty big workflows (5) that share around 70% of the code.

Is it possible to reuse part of the common code of the workflows and reduce the code duplication?

4 Replies
Pilot Lvl 1
Message 2 of 5

Re: Nested workflows in GitHub actions

Pilot Lvl 2
Message 3 of 5

Re: Nested workflows in GitHub actions

Anchors are not supported in Actions; nothing changed since https://github.community/t5/GitHub-Actions/Support-for-YAML-anchors/m-p/30336#M406 (tried few days ago out of curiosity).

Pilot Lvl 1
Message 4 of 5

Re: Nested workflows in GitHub actions

You are right! I am quite surprised by this since yaml anchors are such an important feature to simplify job description. Is there any official word from github on this atm?

Copilot Lvl 3
Message 5 of 5

Re: Nested workflows in GitHub actions

Or maybe there should be option to create Action template using yml synatx and then import the same templates based on the use-case.