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
5 changes: 4 additions & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
lib/.gitkeep export-ignore
bin/ export-ignore
node_modules/ export-ignore
test/ export-ignore
vendor/ export-ignore
package-lock.json export-ignore
47 changes: 35 additions & 12 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,7 @@ jobs:
runs-on: [ubuntu-latest]

steps:
- uses: actions/setup-node@v4
with:
node-version: 20

- uses: actions/checkout@v4
- uses: actions/checkout@v6
with:
token: ${{ secrets.SAMLTRACER_BUILD_TOKEN }}
ref: ${{ github.head_ref || github.ref_name }}
Expand All @@ -29,17 +25,44 @@ jobs:
# Without fetching, we might miss new tags due to caching in Github Actions
run: git fetch --all

- name: Run build-script
run: bin/build.sh
- uses: actions/setup-node@v6
with:
node-version: 24

- name: Install & build assets
run: |
# Make sure the lock-file is up to date before we run clean-install
npm install --package-lock-only
npm clean-install
npm audit fix

- name: Build custom (minimum) release of highlight.js
run: |
cd node_modules/highlight.js
npm install --package-lock-only
npm clean-install
npm run build
node tools/build.js xml properties http

- name: Copy third-party dependencies to lib/ directory
run: |
cp node_modules/highlight.js/build/highlight.min.js lib/highlight.min.js
cp node_modules/pako/dist/pako_inflate.min.js lib/pako_inflate.min.js

- name: Clean release
run: |
grep export-ignore .gitattributes | cut -d ' ' -f 1 | while IFS= read -r line
do
rm -rf "$line"
done
rm -rf .git
Comment thread
tvdijen marked this conversation as resolved.

# Store the version, stripping any v-prefix
- name: Write release version
- name: Build zip-file
run: |
TAG="${{ github.ref_name }}"
echo "VERSION=${TAG#v}" >> "$GITHUB_ENV"
zip -1 -r /tmp/samltracer.zip *

- name: Save release
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v7
with:
name: release
path: "/tmp/samltracer.zip"
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ jobs:
runs-on: ubuntu-latest

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

- uses: actions/setup-node@v4
- uses: actions/setup-node@v6
with:
node-version: 20
node-version: 26

- name: Install dependencies
run: npm ci
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
lib/*.js
node_modules/
vendor/
composer.lock
2 changes: 1 addition & 1 deletion LICENSE
Comment thread
tvdijen marked this conversation as resolved.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2011-2014, UNINETT AS
Copyright (c) 2011-2026, SimpleSAMLphp
All rights reserved.

Redistribution and use in source and binary forms, with or without
Expand Down
68 changes: 0 additions & 68 deletions bin/build.sh

This file was deleted.

Loading