Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 26 additions & 19 deletions .github/workflows/webpack.yml
Original file line number Diff line number Diff line change
@@ -1,28 +1,35 @@
name: NodeJS with Webpack

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
push:
branches: ["main"]
pull_request:
branches: ["main"]

jobs:
build:
runs-on: ubuntu-latest
build:
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [18.x, 20.x, 22.x]
strategy:
matrix:
node-version: [22.x]

steps:
- uses: actions/checkout@v4
steps:
- uses: actions/checkout@v4

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}

- name: Build
run: |
npm install
npx webpack
- name: Build
run: |
npm install
npx webpack --mode production --output-path ./dist

# Upload the dist folder as an artifact if needed for subsequent jobs or storage
- name: Upload build artifact
uses: actions/upload-artifact@v4
with:
name: typex-extension
path: dist/
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@
venv
node_modules
todo.md

# this should be downloaded from the repo Releases, or built locally
dist
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"license": "MIT",
"private": true,
"scripts": {
"build": "npx webpack"
"build": "npx webpack --mode production --output-path ./dist"
},
"dependencies": {
"buffer": "^6.0.3",
Expand Down