mirror of
https://github.com/ggml-org/whisper.cpp.git
synced 2026-08-12 22:31:22 +04:00
This commit updates the include path to whisper.h and also ensures that this is only built on pushes to master.
51 lines
1.2 KiB
YAML
51 lines
1.2 KiB
YAML
name: Examples Tests
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
paths:
|
|
- examples/addon.node/**
|
|
- include/whisper.h
|
|
pull_request:
|
|
paths:
|
|
- examples/addon.node/**
|
|
- include/whisper.h
|
|
|
|
jobs:
|
|
addon_node-ubuntu-22:
|
|
runs-on: ubuntu-22.04
|
|
strategy:
|
|
matrix:
|
|
node-version: [ 16.x, 18.x ]
|
|
steps:
|
|
- name: Clone
|
|
uses: actions/checkout@v6
|
|
|
|
- name: Dependencies
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install build-essential git
|
|
sudo apt-get install cmake
|
|
sudo apt-get install libsdl2-dev
|
|
|
|
- name: Use Node.js ${{ matrix.node-version }}
|
|
uses: actions/setup-node@v6
|
|
with:
|
|
node-version: ${{ matrix.node-version }}
|
|
cache: 'npm'
|
|
|
|
- name: Install package.json dependencies
|
|
working-directory: ./examples/addon.node
|
|
run: npm install
|
|
|
|
- name: Compile addon.node
|
|
run: npx cmake-js compile -T addon.node -B Release
|
|
|
|
- name: Download test model
|
|
run: |
|
|
bash ./models/download-ggml-model.sh base.en
|
|
- name: Test
|
|
run: |
|
|
cd examples/addon.node
|
|
npm run test
|