Set Variable
ActionsConvert your variables.json file in .github/variables into environment variables to be used within the scope of a job
v1.0
LatestBy deep-mm
Tags
(2)Are you missing the Azure DevOps Library variable groups in GitHub Actions? If yes, then this action will act as a substitution of Library variable groups in GitHub. [Currently only supports windows and ubuntu agents]
This is a GitHub Action used to convert variables.json files into environment variables.
The format of the file should be:
{
"variables": [
{
"name": "variable1",
"value": "variable1value"
},
{
"name": "variable2",
"value": "variable2value"
}
]
}
- name: Set Variable
uses: deep-mm/set-variables@v1.0
with:
# Name of variable file
variableFileName: 'variables' #Dont write .json here
The variables in your variables.json file will now be converted to environment variables that you can use in the next steps of the same job. Ths scope of variables is only the job and not the entire workflow.
${{ env.variable1 }}
${{ env.variable2 }}
Set Variable is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.