Skip to content

Commit 7836f0b

Browse files
Configure Node.js and enhance build artifacts step
Setup Node.js environment and update build process to include building a React app and creating a distribution package.
1 parent 5d8854e commit 7836f0b

File tree

1 file changed

+21
-5
lines changed

1 file changed

+21
-5
lines changed

.github/workflows/generator-generic-ossf-slsa3-publish.yml

Lines changed: 21 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,28 @@ jobs:
1818

1919
steps:
2020
- uses: actions/checkout@v4
21+
22+
- name: Setup Node.js
23+
uses: actions/setup-node@v4
24+
with:
25+
node-version: '20'
26+
cache: 'npm'
2127

22-
- name: Build artifacts
23-
run: |
24-
echo "Building artifacts..."
25-
mkdir -p dist
26-
echo "Sample artifact" > dist/artifact.txt
28+
- name: Build artifactsSetup Node.js and build React app
29+
run: |
30+
# Install Node.js dependencies
31+
npm ci
32+
33+
# Build the Vite application
34+
npm run build
35+
36+
# Create distribution package
37+
cd dist
38+
tar -czf ../log-triage-sandbox.tar.gz *
39+
cd ..
40+
41+
# Move tarball to dist for publishing
42+
mv log-triage-sandbox.tar.gz dist/
2743
2844
- name: Generate hash
2945
shell: bash

0 commit comments

Comments
 (0)