{"id":21975086,"url":"https://github.com/nwaughachukwuma/github-action-example","last_synced_at":"2025-10-07T07:52:19.568Z","repository":{"id":37077877,"uuid":"382797732","full_name":"nwaughachukwuma/github-action-example","owner":"nwaughachukwuma","description":"First Github Action created from typescript action template","archived":false,"fork":false,"pushed_at":"2023-01-16T18:08:09.000Z","size":339,"stargazers_count":0,"open_issues_count":5,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-17T04:07:07.624Z","etag":null,"topics":["github-actions","github-actions-typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nwaughachukwuma.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":null,"support":null}},"created_at":"2021-07-04T08:08:44.000Z","updated_at":"2023-07-07T04:27:12.000Z","dependencies_parsed_at":"2023-02-10T05:31:33.424Z","dependency_job_id":null,"html_url":"https://github.com/nwaughachukwuma/github-action-example","commit_stats":{"total_commits":1,"total_committers":1,"mean_commits":1.0,"dds":0.0,"last_synced_commit":"4dda674ac09449bfc13ca9f970daf88f532e799d"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":"actions/typescript-action","purl":"pkg:github/nwaughachukwuma/github-action-example","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nwaughachukwuma%2Fgithub-action-example","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nwaughachukwuma%2Fgithub-action-example/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nwaughachukwuma%2Fgithub-action-example/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nwaughachukwuma%2Fgithub-action-example/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nwaughachukwuma","download_url":"https://codeload.github.com/nwaughachukwuma/github-action-example/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nwaughachukwuma%2Fgithub-action-example/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278740821,"owners_count":26037480,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-07T02:00:06.786Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["github-actions","github-actions-typescript"],"created_at":"2024-11-29T15:49:37.737Z","updated_at":"2025-10-07T07:52:19.544Z","avatar_url":"https://github.com/nwaughachukwuma.png","language":"TypeScript","readme":"\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/actions/typescript-action/actions\"\u003e\u003cimg alt=\"typescript-action status\" src=\"https://github.com/actions/typescript-action/workflows/build-test/badge.svg\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n# Create a JavaScript Action using TypeScript\n\nUse this template to bootstrap the creation of a TypeScript action.:rocket:\n\nThis template includes compilation support, tests, a validation workflow, publishing, and versioning guidance.  \n\nIf you are new, there's also a simpler introduction.  See the [Hello World JavaScript Action](https://github.com/actions/hello-world-javascript-action)\n\n## Create an action from this template\n\nClick the `Use this Template` and provide the new repo details for your action\n\n## Code in Main\n\n\u003e First, you'll need to have a reasonably modern version of `node` handy. This won't work with versions older than 9, for instance.\n\nInstall the dependencies  \n```bash\n$ npm install\n```\n\nBuild the typescript and package it for distribution\n```bash\n$ npm run build \u0026\u0026 npm run package\n```\n\nRun the tests :heavy_check_mark:  \n```bash\n$ npm test\n\n PASS  ./index.test.js\n  ✓ throws invalid number (3ms)\n  ✓ wait 500 ms (504ms)\n  ✓ test runs (95ms)\n\n...\n```\n\n## Change action.yml\n\nThe action.yml contains defines the inputs and output for your action.\n\nUpdate the action.yml with your name, description, inputs and outputs for your action.\n\nSee the [documentation](https://help.github.com/en/articles/metadata-syntax-for-github-actions)\n\n## Change the Code\n\nMost toolkit and CI/CD operations involve async operations so the action is run in an async function.\n\n```javascript\nimport * as core from '@actions/core';\n...\n\nasync function run() {\n  try { \n      ...\n  } \n  catch (error) {\n    core.setFailed(error.message);\n  }\n}\n\nrun()\n```\n\nSee the [toolkit documentation](https://github.com/actions/toolkit/blob/master/README.md#packages) for the various packages.\n\n## Publish to a distribution branch\n\nActions are run from GitHub repos so we will checkin the packed dist folder. \n\nThen run [ncc](https://github.com/zeit/ncc) and push the results:\n```bash\n$ npm run package\n$ git add dist\n$ git commit -a -m \"prod dependencies\"\n$ git push origin releases/v1\n```\n\nNote: We recommend using the `--license` option for ncc, which will create a license file for all of the production node modules used in your project.\n\nYour action is now published! :rocket: \n\nSee the [versioning documentation](https://github.com/actions/toolkit/blob/master/docs/action-versioning.md)\n\n## Validate\n\nYou can now validate the action by referencing `./` in a workflow in your repo (see [test.yml](.github/workflows/test.yml))\n\n```yaml\nuses: ./\nwith:\n  milliseconds: 1000\n```\n\nSee the [actions tab](https://github.com/actions/typescript-action/actions) for runs of this action! :rocket:\n\n## Usage:\n\nAfter testing you can [create a v1 tag](https://github.com/actions/toolkit/blob/master/docs/action-versioning.md) to reference the stable and latest V1 action\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnwaughachukwuma%2Fgithub-action-example","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnwaughachukwuma%2Fgithub-action-example","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnwaughachukwuma%2Fgithub-action-example/lists"}