Confused by : ${{ env.OPTIONS }} #27126
-
I’m trying to learn Github Actions using a repo with a TOC Generator action. It’s uses a set of Options:
Those Options are explained in the toc-generator documentation; but where and how do i define or supply the env.VALUES?! (myrepo/settings/environments?) Also the action documentation though extensive doesn’t explain this to me! Any help would be appreciated. |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments
-
The Environment variables - GitHub Docs//docs.github.com/en/actions/reference/environment-variables |
Beta Was this translation helpful? Give feedback.
-
Tnx setting directly in workflow.yml makes more sense to me "
But ‘writing to a special file’ doesn’t make sense to me; even after reading the linked GitHub Doc. I know I can set secrets and environment options on each repo, but I’m not sure where env.TOC_TITLE should point to!? |
Beta Was this translation helpful? Give feedback.
-
for instance when I look at : github.comtechnote-space/toc-generator/blob/e0f463cec3ba22c686e5af432516bddc0c094dc4/.github/workflows/toc.yml
This file has been truncated. show original I see many ${{ env.somestyff) references and I’m trying to understand where to put those values! |
Beta Was this translation helpful? Give feedback.
-
Drallas:
You only need that if you want to generate a value dynamically while your workflow is running. In that case see Setting an environment variable. Otherwise you should be able to just use static values like this:
In the example you linked it looks like the |
Beta Was this translation helpful? Give feedback.
-
I’m a bit new to this but i’m starting to see it. I found an interesting series about GitHub Actions including the env part on Dev.to to get me started. Tnx again for your help! |
Beta Was this translation helpful? Give feedback.
You only need that if you want to generate a value dynamically while your workflow is running. In that case see Setting an environment variable.
Otherwise you should be able to just use static values like this:
In the example you linked it looks like the
technote-space/load-config-action
creates the environment variables.