Skip to content

Commit

Permalink
Published by publish-to-git
Browse files Browse the repository at this point in the history
7173b16e30990773e20185a5e4141716ea1e80cf (HEAD -> refs/heads/master) Bump
  • Loading branch information
Rush committed Jan 19, 2025
0 parents commit 06279dc
Show file tree
Hide file tree
Showing 105 changed files with 39,379 additions and 0 deletions.
1 change: 1 addition & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ColumnLimit: 100
38 changes: 38 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
name: ci
on:
push:
# branches: [ master ]
pull_request:
branches: [ master ]
jobs:
ci:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
node-version: [18.x, 20.x, 22.x]
os: [ubuntu-latest, windows-latest, macos-latest]
steps:
- uses: actions/checkout@v4
with:
submodules: true
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- if: runner.os == 'Linux'
run: sudo apt-get install -y build-essential libgl1-mesa-dri libglapi-mesa
libglew-dev libglu1-mesa-dev libosmesa6
libxi-dev mesa-utils pkg-config
- run: npm ci
env:
npm_config_build_from_source: true
# npm_config_build_from_source is used to force npm post install scripts to build native modules from source instead of downloading prebuilt binaries.
- run: npm run build --if-present
- if: runner.os == 'Linux'
run: xvfb-run glxinfo
- if: runner.os == 'Linux'
run: xvfb-run npm test
- if: runner.os != 'Linux'
run: npm test
65 changes: 65 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: Prebuild, Create Release, Publish

on:
push:
tags:
- 'v*'

jobs:
build:
strategy:
matrix:
node-version: [22.x]
os: [ubuntu-latest, windows-latest, macos-latest]
target: ["18.0.0", "20.0.0", "22.0.0"]
runs-on: ${{ matrix.os }}
permissions:
id-token: write
contents: write
attestations: write
steps:
- uses: actions/checkout@v4
with:
submodules: true
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- if: runner.os == 'Linux'
run: sudo apt-get install -y build-essential libgl1-mesa-dri libglapi-mesa
libglew-dev libglu1-mesa-dev libosmesa6
libxi-dev mesa-utils pkg-config
- run: npm ci --ignore-scripts
- name: Prebuild and Publish
shell: bash
run: node ./node_modules/prebuild/bin.js -t ${{ matrix.target }} --strip --include-regex "\.(node|dll)$" -u ${{ secrets.GITHUB_TOKEN }} --verbose
- name: Prebuild and Publish (musl)
if: runner.os == 'Linux'
shell: bash
run: node ./node_modules/prebuild/bin.js --libc=musl -t ${{ matrix.target }} --strip -u ${{ secrets.GITHUB_TOKEN }} --verbose
- name: Attest
uses: actions/attest-build-provenance@v1
with:
subject-path: 'prebuilds/*.tar.gz'

publish:
name: Publish to NPM
needs:
- build
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- uses: actions/checkout@v4
with:
submodules: true
- uses: actions/setup-node@v4
with:
node-version: '22.x'
registry-url: 'https://registry.npmjs.org'
cache: 'npm'
- run: npm ci --ignore-scripts
- run: npm publish --provenance --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
Empty file added .gitmodules
Empty file.
66 changes: 66 additions & 0 deletions LICENSES
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
This document lists all the licenses used in this headless-gl repository:

- Part I - node-webgl and headless-gl distributed under BSD license
- Part II - ANGLE is distributed under a modified BSD license

------------------------------------------------------------------------------
Part I - node-webgl and headless-gl distributed under BSD license

node-webgl Copyright (c) 2011-2015, Mikael Bourges-Sevenier
headless-gl Copyright (c) 2013-2015 Mikola Lysenko
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

------------------------------------------------------------------------------

Copyright (C) 2002-2015 The ANGLE Project Authors.
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:

Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.

Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following
disclaimer in the documentation and/or other materials provided
with the distribution.

Neither the name of TransGaming Inc., Google Inc., 3DLabs Inc.
Ltd., nor the names of their contributors may be used to endorse
or promote products derived from this software without specific
prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
Loading

0 comments on commit 06279dc

Please sign in to comment.