[add]basex action
This commit is contained in:
parent
43f178f053
commit
8b96370e90
5 changed files with 68 additions and 17 deletions
33
.gitea/actions/install-basex/action.yaml
Normal file
33
.gitea/actions/install-basex/action.yaml
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
name: 'Install BaseX'
|
||||||
|
description: 'Install BaseX on a GitHub Actions runner, assumes Java already installed'
|
||||||
|
inputs:
|
||||||
|
basex-version:
|
||||||
|
description: 'The version of BaseX to install (e.g., 11.7)'
|
||||||
|
required: true
|
||||||
|
default: '11.7'
|
||||||
|
runs:
|
||||||
|
using: 'composite'
|
||||||
|
steps:
|
||||||
|
- name: Download BaseX
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
BASEX_VERSION="${{ inputs.basex-version }}"
|
||||||
|
BASEX_CLEAN_VERSION="${BASEX_VERSION//./}"
|
||||||
|
wget https://files.basex.org/releases/$BASEX_VERSION/BaseX$BASEX_CLEAN_VERSION.zip -O BaseX.zip
|
||||||
|
|
||||||
|
- name: Unzip BaseX
|
||||||
|
shell: "bash"
|
||||||
|
run: |
|
||||||
|
unzip BaseX.zip -d $HOME
|
||||||
|
rm BaseX.zip
|
||||||
|
|
||||||
|
- name: Add BaseX to PATH
|
||||||
|
shell: "bash"
|
||||||
|
run: |
|
||||||
|
echo "BASEX_ROOT=$HOME/basex" >> $GITHUB_ENV
|
||||||
|
echo "PATH=$PATH:$HOME/basex/bin" >> $GITHUB_ENV
|
||||||
|
|
||||||
|
- name: Verify BaseX installation
|
||||||
|
shell: "bash"
|
||||||
|
run: |
|
||||||
|
basex -v"
|
0
.gitea/actions/install-basex/install-basex.sh
Normal file
0
.gitea/actions/install-basex/install-basex.sh
Normal file
33
.gitea/workflows/test-basex.yaml
Normal file
33
.gitea/workflows/test-basex.yaml
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
name: Test BaseX Installation
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
pull_request:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
paths:
|
||||||
|
- ".gitea/workflows/trigger/release"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
test-basex:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Set up Java
|
||||||
|
uses: actions/setup-java@v4
|
||||||
|
with:
|
||||||
|
distribution: "temurin"
|
||||||
|
java-version: "17"
|
||||||
|
|
||||||
|
- name: Install BaseX
|
||||||
|
uses: ./.github/actions/install-basex
|
||||||
|
with:
|
||||||
|
basex-version: '11.7' # Specify the BaseX version here
|
||||||
|
|
||||||
|
- name: Run BaseX command
|
||||||
|
run: |
|
||||||
|
basex --version
|
|
@ -4,4 +4,5 @@ c
|
||||||
Xyxh
|
Xyxh
|
||||||
4456
|
4456
|
||||||
9.7.4 xyxz01x
|
9.7.4 xyxz01x
|
||||||
ab
|
ab
|
||||||
|
iiii
|
|
@ -1,16 +0,0 @@
|
||||||
|
|
||||||
import module namespace build = 'urn:quodatum:build1' at 'build.xqm';
|
|
||||||
declare variable $base:= file:parent(db:system()/globaloptions/dbpath/string());
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
"
|
|
||||||
copy..
|
|
||||||
",
|
|
||||||
file:copy(
|
|
||||||
"dist/pdfbox-3.0.4.fat.jar"=>trace("Source: "),
|
|
||||||
file:resolve-path("lib/custom",$base)=>trace("Dest: ")
|
|
||||||
),
|
|
||||||
file:list(file:resolve-path("lib/custom",$base)),
|
|
||||||
"
|
|
||||||
"
|
|
Loading…
Add table
Reference in a new issue