Skip to content

Merge pull request #105 from belsman/chore/add-version-number-to-vcl-… #88

Merge pull request #105 from belsman/chore/add-version-number-to-vcl-…

Merge pull request #105 from belsman/chore/add-version-number-to-vcl-… #88

Workflow file for this run

name: Build
on:
push:
branches:
- master
- dev
jobs:
build:
runs-on: ubuntu-latest
environment: github-pages
strategy:
matrix:
node-version: [20.x]
steps:
- uses: actions/checkout@v1
- name: Extract branch name
shell: bash
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})"
id: extract_branch
- name: Cache node modules
uses: actions/cache@v1
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Node ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: install and build
env:
GIT_BRANCH: ${{ steps.extract_branch.outputs.branch }}
run: |
npm ci
npm run demo automatedRun
- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: docgen/vcl.github.io/dist
- name: Extract version
id: extract_version
uses: Saionaro/extract-package-version@v1.1.1
with:
path: packages/vcl
- name: Create Release
id: create_release
uses: actions/create-release@latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.extract_version.outputs.version }}
release_name: Release ${{ steps.extract_version.outputs.version }}
draft: false
prerelease: false