Skip to content
This repository has been archived by the owner on Nov 13, 2020. It is now read-only.

mheap/github-action-auto-compile-node

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This project is archived. I use and recommend JasonEtco/build-and-tag-action instead as it reimplements this action, and adds automatic release retagging


Auto Compile Node

This action will take any Node.js action, compile and package it in to a single file so that it can be executed using the node12 runtime in GitHub Actions.

It is intended to be triggered when a release is published, and will update the tag of the release when it finishes running.

The action:

  • Runs npm install
  • Compiles the code using ncc
  • Rewrites action.yml, setting the runtime to node12 and the main entry to index.dist.js
  • Commits these changes and updates the tag to point at the new commit

At this point, any consumers may point at the tag and their actions will run much faster than pointing at master

Usage

name: Auto-Compile
on: 
  release:
    types: [published]
jobs:
  compile:
    runs-on: ubuntu-16.04
    steps:
      - name: Checkout
        uses: actions/checkout@v2
      - name: Automatically build action
        uses: mheap/github-action-auto-compile-node@master
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Options

- uses: mheap/github-action-auto-compile-node@master
  with:
    # Define a custom entrypoint for your action. Defaults to "index.js"
    main: lib/index.js

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published