Fix crash when using too small text annotation font size #121
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: [ push, pull_request ] | |
jobs: | |
build: | |
name: Build, Upload, Test | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: recursive | |
- name: Install Node | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 18 | |
- name: Cache Node modules | |
id: node-cache | |
uses: actions/cache@v4 | |
with: | |
path: node_modules | |
key: node-modules-${{ hashFiles('package-lock.json') }} | |
- name: Install Node modules | |
if: steps.node-cache.outputs.cache-hit != 'true' | |
run: npm ci | |
- name: Build pdf-worker | |
run: npm run build | |
# Currently necessary for Webpack: https://stackoverflow.com/a/69746937 | |
env: | |
NODE_OPTIONS: --openssl-legacy-provider | |
- name: Upload pre-build ZIP | |
if: | | |
env.ACT != 'true' | |
&& github.repository == 'zotero/pdf-worker' | |
&& github.event_name == 'push' | |
&& (github.ref == 'refs/heads/master' || endsWith(github.ref, '-hotfix') || github.ref == 'refs/heads/gh-actions-ci-test') | |
env: | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
run: | | |
cd build | |
mkdir build-zip | |
zip -r build-zip/$GITHUB_SHA.zip worker.js | |
sudo gem install --no-document dpl dpl-s3 | |
dpl --provider=s3 --bucket=zotero-download --local-dir=build-zip --upload-dir=ci/client-pdf-worker --acl=public-read --skip_cleanup=true | |
- name: Run tests | |
run: npm run test |