Skip to content

form8ion/github-actions-node-ci

Repository files navigation

github-actions-node-ci

CI scaffolder for JavaScript projects on GitHub Actions

Node CI Workflow Status Codecov SLSA Level 2

Table of Contents

Usage

MIT license npm Try @form8ion/github-actions-node-ci on RunKit node

Installation

$ npm install @form8ion/github-actions-node-ci --save-prod

Example

Import

import {scaffold, lift, test} from '@form8ion/github-actions-node-ci';

Execute

(async () => {
  await scaffold({
    projectRoot: process.cwd(),
    vcs: {
      owner: 'repo-owner',
      name: 'repo-name'
    },
    runner: 'hosted-runner-name'    // optional. uses `ubuntu-latest` if not provided
  });

  await test({projectRoot: process.cwd()});

  await lift({
    projectRoot: process.cwd(),
    results: {branchesToVerify: ['foo', 'bar']},
    vcs: {owner: 'repo-owner', name: 'repo-name'},
    runner: 'hosted-runner-name'    // optional. uses `ubuntu-latest` if not provided
  });
})();

Contributing

PRs Welcome Conventional Commits Commitizen friendly semantic-release Renovate

Dependencies

$ nvm install
$ npm install

Verification

$ npm test