github-script
SKILL.md
GitHub Action Script Best Practices
This skill provides guidelines for writing JavaScript files that run using the GitHub Action actions/github-script@v8.
Important Notes
- This action provides
@actions/coreand@actions/githubpackages globally - Do not add import or require for
@actions/core - Reference documentation:
Best Practices
- Use
core.info,core.warning,core.errorfor logging, notconsole.logorconsole.error - Use
core.setOutputto set action outputs - Use
core.exportVariableto set environment variables for subsequent steps - Use
core.getInputto get action inputs, withrequired: truefor mandatory inputs - Use
core.setFailedto mark the action as failed with an error message