What is the purpose of the $GITHUB_PATH environment file?
Select an answer to reveal the explanation.
Short Explanation and Infographic
GITHUB_PATH is the tool install shortcut — write a directory path to it and all later steps can find that directory's executables.
Full explanation below image
Full Explanation
$GITHUB_PATH works like $GITHUB_ENV but specifically for prepending directories to the PATH environment variable. Write 'echo "/custom/bin" >> $GITHUB_PATH' in a step, and subsequent steps will have '/custom/bin' prepended to their PATH, making executables there directly callable. This is how tool installation actions (like setup-node, setup-python) make the installed tools available globally in the job. The PATH to the workflow YAML file is not what this variable does. Working directory is set with 'working-directory:'. GITHUB_WORKSPACE is the checked-out repo path.