agentleFS
GitHubKnown publishergithub/gh-aw/.github/skills/github-script/SKILL.md

github-script

Skill5.3k starsChanged 6 months agoMITView on GitHub

Write robust JavaScript for GitHub Actions github-script steps.

2 other projects use a version of this.

Trending

Quiet since March.thin dataabout the whole repository

Dec 2025: 0 mentionsJan 2026: 0 mentionsFeb 2026: 2 mentionsMar 2026: 1 mentionApr 2026: 0 mentionsMay 2026: 0 mentionsJun 2026: 0 mentionsJul 2026: 0 mentionsAug 2026: 0 mentionsSep 2026: 0 mentionsOct 2026: 0 mentionsNov 2026: 0 mentions
Dec 2025Jun 2026Nov 2026
Mentions a month of the github/gh-aw repository that our weekly crawl found: only 3 in all, so this is a hint, not a trend. There is no adoption data for this file yet.

Most recently taken up by

The file

Show its rules and text

We split this skill into the rules it gives an agent

14 rules. About 0 are common, 0 are distinctive, and 14 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 14

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use these guidelines for JavaScript executed by actions/github-script@v8.

    line 8
  2. Very specific:

    Do not add import or require for @actions/core

    line 13
  3. Very specific:

    Use core.info, core.warning, core.error for logging, not console.log or console.error

    line 20
  4. Very specific:

    Use core.setOutput to set action outputs

    line 21
  5. Very specific:

    Use core.exportVariable to set environment variables for subsequent steps

    line 22
  6. Very specific:

    Use core.getInput to get action inputs, with required: true for mandatory inputs

    line 23
  7. Very specific:

    Use core.setFailed to mark the action as failed with an error message

    line 24
  8. Very specific:

    Use core.summary.* function to write output the step summary file.

    line 28
  9. Very specific:

    Use core.summary.addRaw() to add raw Markdown content (GitHub Flavored Markdown supported)

    line 30
  10. Very specific:

    Make sure to call core.summary.write() to flush pending writes

    line 31
  11. Very specific:

    Avoid any type as much as possible, use specific types or unknown instead

    line 36
  12. Very specific:

    Run make js to run the typescript compiler.

    line 49
  13. Very specific:

    Run make lint-cjs to lint the files.

    line 51
  14. Very specific:

    Run make fmt-cjs after editing to format the file.

    line 53

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

GitHub Action Script Best Practices

Use these guidelines for JavaScript executed by actions/github-script@v8.

Important Notes

Best Practices

  • Use core.info, core.warning, core.error for logging, not console.log or console.error
  • Use core.setOutput to set action outputs
  • Use core.exportVariable to set environment variables for subsequent steps
  • Use core.getInput to get action inputs, with required: true for mandatory inputs
  • Use core.setFailed to mark the action as failed with an error message

Step Summary

Use core.summary.* function to write output the step summary file.

  • Use core.summary.addRaw() to add raw Markdown content (GitHub Flavored Markdown supported)
  • Make sure to call core.summary.write() to flush pending writes
  • Summary function calls can be chained, e.g. core.summary.addRaw(...).addRaw(...).write()

Common Errors

  • Avoid any type as much as possible, use specific types or unknown instead
  • Catch handler: check if error is an instance of Error before accessing message property
catch (error) {
  core.setFailed(error instanceof Error ? error : String(error));
}
  • core.setFailed also calls core.error, so do not call both

Typechecking

Run make js to run the typescript compiler.

Run make lint-cjs to lint the files.

Run make fmt-cjs after editing to format the file.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.