@form8ion/github-workflows-core
v5.0.0
Published
core functionality for form8ion plugins that manage github workflows
Downloads
1,774
Readme
github-workflows-core
core functionality for form8ion plugins that manage github workflows
Table of Contents
Usage
Installation
$ npm install @form8ion/github-workflows-core --save-prod
Example
Import
import {
scaffoldCheckoutStep,
scaffoldNodeSetupStep,
scaffoldDependencyInstallationStep,
scaffoldVerificationStep
} from '@form8ion/github-workflows-core';
Execute
(async () => {
scaffoldCheckoutStep();
scaffoldNodeSetupStep({versionDeterminedBy: 'nvmrc'});
scaffoldDependencyInstallationStep();
scaffoldVerificationStep();
})();
API
scaffoldCheckoutStep
Scaffolder to define the details for a step to check out the project in a GitHub workflow
scaffoldNodeSetupStep
Scaffolder to define the details for a step to set up a node.js environment in a GitHub workflow
Takes a single options object as an argument, containing:
versionDeterminedBy
string (required)
Source of node version for use in the configured step. Valid options are nvmrc
or matrix
scaffoldDependencyInstallationStep
Scaffolder to define the details for a step to install dependencies in a GitHub workflow
scaffoldVerificationStep
Scaffolder to define the details for a step to execute verification
Contributing
Dependencies
$ nvm install
$ npm install
Verification
$ npm test