diff --git a/docz/docs/03-demos/03-net/08-headless/index.md b/docz/docs/03-demos/03-net/08-headless/index.md index 96cf138..96d5eeb 100644 --- a/docz/docs/03-demos/03-net/08-headless/index.md +++ b/docz/docs/03-demos/03-net/08-headless/index.md @@ -130,13 +130,13 @@ This demo was tested in the following deployments: | Puppeteer | Date | |:----------|:-----------| -| `24.9.0` | 2025-05-21 | -| `23.11.1` | 2025-05-21 | -| `22.15.0` | 2025-05-21 | -| `21.11.0` | 2025-05-21 | -| `20.9.0` | 2025-05-21 | -| `15.5.0` | 2025-05-21 | -| `10.4.0` | 2025-05-21 | +| `24.35.0` | 2026-01-21 | +| `23.11.1` | 2026-01-21 | +| `22.15.0` | 2026-01-21 | +| `21.11.0` | 2026-01-21 | +| `20.9.0` | 2026-01-21 | +| `15.5.0` | 2026-01-21 | +| `10.4.0` | 2026-01-21 | ::: @@ -430,4 +430,4 @@ env OPENSSL_CONF=/dev/null QT_QPA_PLATFORM=phantom ./phantomjs-2.1.1-linux-x86_6 [^1]: See ["Workbook Object"](/docs/csf/book) for more details about the SheetJS workbook object. [^2]: See [`table_to_book` in "HTML" Utilities](/docs/api/utilities/html#create-new-sheet) -[^3]: See [`write` in "Writing Files"](/docs/api/write-options) \ No newline at end of file +[^3]: See [`write` in "Writing Files"](/docs/api/write-options) diff --git a/docz/docs/03-demos/20-cli/03-nexe.md b/docz/docs/03-demos/20-cli/03-nexe.md index 5fc3be9..6136f7c 100644 --- a/docz/docs/03-demos/20-cli/03-nexe.md +++ b/docz/docs/03-demos/20-cli/03-nexe.md @@ -37,7 +37,7 @@ This demo was tested in the following deployments: | Architecture | Version | NodeJS | Source | Date | |:-------------|:---------------|:----------|:----------|:-----------| -| `darwin-x64` | `5.0.0-beta.4` | `14.15.3` | Pre-built | 2025-04-21 | +| `darwin-x64` | `5.0.0-beta.4` | `14.15.3` | Pre-built | 2026-01-21 | | `darwin-arm` | `5.0.0-beta.4` | `22.14.0` | Compiled | 2025-06-18 | | `win11-x64` | `5.0.0-beta.4` | `14.15.3` | Pre-built | 2025-05-07 | | `win11-arm` | `4.0.0-rc.6` | `22.14.0` | Compiled | 2025-02-23 | diff --git a/docz/docs/03-demos/20-cli/05-pkg.md b/docz/docs/03-demos/20-cli/05-pkg.md index b728f89..c2579db 100644 --- a/docz/docs/03-demos/20-cli/05-pkg.md +++ b/docz/docs/03-demos/20-cli/05-pkg.md @@ -37,7 +37,7 @@ This demo was tested in the following deployments: | Architecture | Version | NodeJS | Date | |:-------------|:--------|:---------|:-----------| -| `darwin-x64` | `5.8.1` | `18.5.0` | 2025-04-21 | +| `darwin-x64` | `5.8.1` | `18.5.0` | 2026-01-21 | | `darwin-arm` | `5.8.1` | `18.5.0` | 2025-06-18 | | `win11-x64` | `5.8.1` | `18.5.0` | 2025-05-07 | | `win11-arm` | `5.8.1` | `18.5.0` | 2025-02-23 | diff --git a/docz/docs/03-demos/20-cli/11-nodesea.md b/docz/docs/03-demos/20-cli/11-nodesea.md index afd576d..1c9d81b 100644 --- a/docz/docs/03-demos/20-cli/11-nodesea.md +++ b/docz/docs/03-demos/20-cli/11-nodesea.md @@ -158,7 +158,7 @@ This demo was tested in the following deployments: | Architecture | NodeJS | Date | |:-------------|:----------|:-----------| -| `darwin-x64` | `22.14.0` | 2025-04-21 | +| `darwin-x64` | `24.13.0` | 2026-01-21 | | `darwin-arm` | `24.2.0` | 2025-06-18 | | `win11-x64` | `24.2.0` | 2025-06-17 | | `win11-arm` | `22.14.0` | 2025-02-23 | diff --git a/docz/docs/03-demos/20-cli/12-bunsea.md b/docz/docs/03-demos/20-cli/12-bunsea.md index 27069ca..b4e35d5 100644 --- a/docz/docs/03-demos/20-cli/12-bunsea.md +++ b/docz/docs/03-demos/20-cli/12-bunsea.md @@ -79,7 +79,7 @@ This demo was last tested in the following deployments: | Architecture | BunJS | Date | |:-------------|:---------|:-----------| -| `darwin-x64` | `1.2.10` | 2025-04-21 | +| `darwin-x64` | `1.3.6` | 2026-01-21 | | `darwin-arm` | `1.2.16` | 2025-06-18 | | `win11-x64` | `1.2.13` | 2025-05-07 | | `win11-arm` | `1.2.3` | 2025-02-23 | diff --git a/docz/docs/03-demos/20-cli/13-denosea.md b/docz/docs/03-demos/20-cli/13-denosea.md index 85bf5b9..42a93c1 100644 --- a/docz/docs/03-demos/20-cli/13-denosea.md +++ b/docz/docs/03-demos/20-cli/13-denosea.md @@ -102,7 +102,7 @@ This demo was last tested in the following deployments: | Architecture | Deno | Date | |:-------------|:---------|:-----------| -| `darwin-x64` | `2.2.11` | 2025-04-21 | +| `darwin-x64` | `2.6.5` | 2026-01-21 | | `darwin-arm` | `2.3.6` | 2025-06-18 | | `win11-x64` | `2.3.6` | 2025-06-17 | | `win11-arm` | `2.2.1` | 2025-02-23 | diff --git a/docz/docs/03-demos/20-cli/21-txiki.md b/docz/docs/03-demos/20-cli/21-txiki.md index 4db1c26..87ad091 100644 --- a/docz/docs/03-demos/20-cli/21-txiki.md +++ b/docz/docs/03-demos/20-cli/21-txiki.md @@ -90,12 +90,12 @@ This demo was tested in the following deployments: | Architecture | Version | Commit | Date | |:-------------|:----------|:----------|:-----------| -| `darwin-x64` | `24.12.0` | | 2025-04-19 | +| `darwin-x64` | `24.12.0` | `793dd9d` | 2026-01-21 | | `darwin-arm` | `24.12.0` | `793dd9d` | 2026-01-18 | | `win11-x64` | `24.12.0` | | 2025-04-19 | | `win11-arm` | `24.12.0` | | 2025-04-19 | | `linux-x64` | `24.12.0` | `65e5595` | 2026-01-18 | -| `linux-arm` | `24.12.0` | | 2025-04-19 | +| `linux-arm` | `24.12.0` | `65e5595` | 2026-01-21 | ::: @@ -161,7 +161,7 @@ following commands should be run in the `txiki.js` folder: ```bash rm -rf build cmake -B build -DCMAKE_BUILD_TYPE=Release -DUSE_EXTERNAL_FFI=ON -cmake --build build -j 32 +cmake --build build -j 8 cp build/tjs ../ ``` diff --git a/docz/docs/03-demos/42-engines/01-duktape.md b/docz/docs/03-demos/42-engines/01-duktape.md index 7ec2198..be22466 100644 --- a/docz/docs/03-demos/42-engines/01-duktape.md +++ b/docz/docs/03-demos/42-engines/01-duktape.md @@ -128,7 +128,7 @@ This demo was tested in the following deployments: | Architecture | Version | Date | |:-------------|:--------|:-----------| -| `darwin-x64` | `2.7.0` | 2025-03-31 | +| `darwin-x64` | `2.7.0` | 2026-01-21 | | `darwin-arm` | `2.7.0` | 2025-09-03 | | `win11-x64` | `2.7.0` | 2025-04-28 | | `win11-arm` | `2.7.0` | 2025-02-23 | @@ -405,7 +405,7 @@ This demo was tested in the following deployments: | Architecture | Version | PHP | Date | |:-------------|:--------|:---------|:-----------| -| `darwin-x64` | `2.7.0` | `8.4.2` | 2025-03-31 | +| `darwin-x64` | `2.7.0` | `8.4.11` | 2026-01-21 | | `darwin-arm` | `2.7.0` | `8.4.4` | 2025-02-25 | | `linux-x64` | `2.7.0` | `8.3.6` | 2025-04-21 | | `linux-arm` | `2.7.0` | `8.2.26` | 2025-02-15 | @@ -547,7 +547,7 @@ This demo was tested in the following deployments: | Architecture | Version | Python | Date | |:-------------|:--------|:---------|:-----------| -| `darwin-x64` | `2.7.0` | `3.13.1` | 2025-03-31 | +| `darwin-x64` | `2.7.0` | `3.13.7` | 2026-01-21 | | `darwin-arm` | `2.7.0` | `3.12.3` | 2025-03-30 | | `linux-x64` | `2.7.0` | `3.12.3` | 2025-04-21 | | `linux-arm` | `2.7.0` | `3.11.2` | 2025-02-15 | @@ -1017,7 +1017,7 @@ This demo was tested in the following deployments: | Architecture | Version | Date | |:-------------|:--------|:-----------| -| `darwin-x64` | `2.2.0` | 2025-03-31 | +| `darwin-x64` | `2.2.0` | 2026-02-21 | | `darwin-arm` | `2.2.0` | 2025-03-30 | | `linux-x64` | `2.2.0` | 2025-04-21 | | `linux-arm` | `2.2.0` | 2025-02-15 | @@ -1112,7 +1112,7 @@ This demo was tested in the following deployments: | Architecture | Version | Date | |:-------------|:--------|:-----------| -| `darwin-x64` | `2.2.1` | 2025-03-31 | +| `darwin-x64` | `2.2.1` | 2026-01-21 | | `darwin-arm` | `2.2.1` | 2025-03-31 | | `win11-x64` | `2.2.1` | 2025-04-17 | | `linux-x64` | `2.2.1` | 2026-01-08 | @@ -1181,7 +1181,7 @@ cargo add ducc base64 6) Build and run the app: ```bash -cargo run pres.numbers +cargo run -- pres.numbers ``` If the program succeeded, the CSV contents will be printed to console and the diff --git a/docz/docs/03-demos/42-engines/05-jint.md b/docz/docs/03-demos/42-engines/05-jint.md index 7181dd3..66beecc 100644 --- a/docz/docs/03-demos/42-engines/05-jint.md +++ b/docz/docs/03-demos/42-engines/05-jint.md @@ -163,7 +163,7 @@ This demo was tested in the following deployments: | Architecture | Jint | Date | |:-------------|:--------|:-----------| -| `darwin-x64` | `4.2.1` | 2025-03-31 | +| `darwin-x64` | `4.5.0` | 2026-01-21 | | `darwin-arm` | `4.2.0` | 2025-02-13 | | `win11-x64` | `4.2.2` | 2026-04-28 | | `win11-arm` | `4.2.0` | 2025-02-23 | @@ -248,7 +248,7 @@ dotnet run ```bash dotnet nuget add source https://www.myget.org/F/jint/api/v3/index.json -dotnet add package Jint --version 4.2.2 +dotnet add package Jint --version 4.5.0 ``` To verify Jint is installed, replace `Program.cs` with the following: diff --git a/docz/docs/03-demos/42-engines/06-goja.md b/docz/docs/03-demos/42-engines/06-goja.md index 9eb1a8d..3383a52 100644 --- a/docz/docs/03-demos/42-engines/06-goja.md +++ b/docz/docs/03-demos/42-engines/06-goja.md @@ -105,7 +105,7 @@ This demo was tested in the following deployments: | Architecture | Git Commit | Go version | Date | |:-------------|:-----------|:-----------|:-----------| -| `darwin-x64` | `bcd7cc6` | `1.24.1` | 2025-03-31 | +| `darwin-x64` | `651366f` | `1.25.6` | 2026-01-21 | | `darwin-arm` | `cb187b0` | `1.24.0` | 2025-06-18 | | `win11-x64` | `bcd7cc6` | `1.24.2` | 2025-04-28 | | `win11-arm` | `5ef83b8` | `1.24.0` | 2025-02-23 | diff --git a/docz/docs/03-demos/42-engines/08-quickjs.md b/docz/docs/03-demos/42-engines/08-quickjs.md index 4bb71ca..c6f0c7f 100644 --- a/docz/docs/03-demos/42-engines/08-quickjs.md +++ b/docz/docs/03-demos/42-engines/08-quickjs.md @@ -27,7 +27,7 @@ command-line tool for reading data from files. :::note pass Many QuickJS functions are not documented. The explanation was verified against -commit `0d7aaed`. +commit `f113949`. ::: @@ -263,14 +263,14 @@ This demo was tested in the following deployments: | Architecture | Library | Git Commit | Date | |:-------------|:-----------|:-----------|:-----------| -| `darwin-x64` | QuickJS | `0d7aaed` | 2025-03-31 | +| `darwin-x64` | QuickJS | `f113949` | 2026-01-21 | | `darwin-arm` | QuickJS | `3306254` | 2025-09-03 | | `win11-x64` | QuickJS-NG | `865ba1f` | 2025-04-18 | | `win11-arm` | QuickJS-NG | `865ba1f` | 2025-04-18 | | `linux-x64` | QuickJS | `3306254` | 2025-06-18 | | `linux-arm` | QuickJS | `6e2e68f` | 2025-02-15 | -When the demo was tested, `0d7aaed` was the HEAD commit on the `master` branch. +When the demo was tested, `f113949` was the HEAD commit on the `master` branch. ::: @@ -281,7 +281,7 @@ When the demo was tested, `0d7aaed` was the HEAD commit on the `master` branch. ```bash git clone https://github.com/bellard/quickjs cd quickjs -git checkout 3306254 +git checkout f113949 make cd .. ``` @@ -428,9 +428,9 @@ This demo was tested in the following environments: | Git Commit | Date | |:-----------|:-----------| -| `0d7aaed` | 2025-03-31 | +| `f113949` | 2026-01-21 | -When the demo was tested, `0d7aaed` was the HEAD commit on the `master` branch. +When the demo was tested, `f113949` was the HEAD commit on the `master` branch. ::: @@ -440,7 +440,7 @@ and build the `quickjs` project: ```bash git clone https://github.com/bellard/quickjs cd quickjs -git checkout 0d7aaed +git checkout f113949 make cd .. ``` diff --git a/docz/docs/03-demos/42-engines/15-rb.md b/docz/docs/03-demos/42-engines/15-rb.md index c30c3b2..bfd5eb7 100644 --- a/docz/docs/03-demos/42-engines/15-rb.md +++ b/docz/docs/03-demos/42-engines/15-rb.md @@ -87,7 +87,7 @@ This demo was tested in the following deployments: | Platform | Ruby | ExecJS | Date | |:-------------|:---------|:---------|:-----------| -| `darwin-x64` | `2.6.10` | `2.10.0` | 2025-03-31 | +| `darwin-x64` | `2.6.10` | `2.10.0` | 2026-01-21 | | `darwin-arm` | `2.6.10` | `2.10.0` | 2025-09-03 | | `win11-x64` | `3.3.8` | `2.10.0` | 2025-04-28 | | `win11-arm` | `3.2.3` | `2.10.0` | 2025-02-23 | diff --git a/docz/docs/03-demos/42-engines/21-boa.md b/docz/docs/03-demos/42-engines/21-boa.md index fda5d92..d72e84d 100644 --- a/docz/docs/03-demos/42-engines/21-boa.md +++ b/docz/docs/03-demos/42-engines/21-boa.md @@ -105,7 +105,7 @@ This demo was tested in the following deployments: | Architecture | Boa | Date | |:-------------|:---------|:-----------| -| `darwin-x64` | `0.20.0` | 2025-03-31 | +| `darwin-x64` | `0.20.1` | 2026-01-21 | | `darwin-arm` | `0.20.0` | 2025-09-03 | | `win11-x64` | `0.20.0` | 2025-04-28 | | `win11-arm` | `0.20.0` | 2025-02-23 | diff --git a/docz/docs/03-demos/42-engines/22-perl.md b/docz/docs/03-demos/42-engines/22-perl.md index 7b581db..81ca986 100644 --- a/docz/docs/03-demos/42-engines/22-perl.md +++ b/docz/docs/03-demos/42-engines/22-perl.md @@ -129,7 +129,7 @@ This demo was tested in the following deployments: | Architecture | Version | Date | |:-------------|:--------|:-----------| -| `darwin-x64` | `0.066` | 2025-03-31 | +| `darwin-x64` | `0.066` | 2026-01-21 | | `darwin-arm` | `0.066` | 2025-09-03 | | `win11-x64` | `0.066` | 2026-01-10 | | `win11-arm` | `0.066` | 2026-01-10 | diff --git a/docz/docs/03-demos/42-engines/23-jerryscript.md b/docz/docs/03-demos/42-engines/23-jerryscript.md index f9cb9a1..dcf092d 100644 --- a/docz/docs/03-demos/42-engines/23-jerryscript.md +++ b/docz/docs/03-demos/42-engines/23-jerryscript.md @@ -36,7 +36,7 @@ This demo was tested in the following environments: | Architecture | Commit | Date | |:-------------|:----------|:-----------| -| `darwin-x64` | `5020015` | 2025-03-31 | +| `darwin-x64` | `b706935` | 2026-01-21 | | `darwin-arm` | `355ab24` | 2025-09-03 | | `win11-x64` | `5020015` | 2025-04-23 | | `win11-arm` | `5020015` | 2025-02-23 | @@ -52,7 +52,7 @@ The Windows tests were run in WSL. :::info pass The official JerryScript documentation and examples are out of date. This -explanation was verified against the latest release (commit `5020015`). +explanation was verified against the latest release (commit `b706935`). ::: diff --git a/docz/docs/03-demos/42-engines/26-jurassic.md b/docz/docs/03-demos/42-engines/26-jurassic.md index 6355a94..4927ebc 100644 --- a/docz/docs/03-demos/42-engines/26-jurassic.md +++ b/docz/docs/03-demos/42-engines/26-jurassic.md @@ -176,7 +176,7 @@ This demo was tested in the following deployments: | Architecture | Jurassic | Date | |:-------------|:---------|:-----------| -| `darwin-x64` | `3.2.9` | 2025-03-31 | +| `darwin-x64` | `3.2.9` | 2026-01-21 | | `darwin-arm` | `3.2.9` | 2025-09-03 | | `win11-x64` | `3.2.9` | 2025-04-23 | | `win11-arm` | `3.2.9` | 2025-02-23 | diff --git a/docz/docs/09-miscellany/05-contributing.md b/docz/docs/09-miscellany/05-contributing.md index 9cac5e1..0e20cbc 100644 --- a/docz/docs/09-miscellany/05-contributing.md +++ b/docz/docs/09-miscellany/05-contributing.md @@ -43,7 +43,7 @@ These instructions were tested on the following platforms: |:------------------------------|:-------------|:-----------| | Linux (Ubuntu Linux x64) | `linux-x64` | 2025-07-06 | | Linux (Debian Linux AArch64) | `linux-arm` | 2025-01-14 | -| MacOS 15.3 (x64) | `darwin-x64` | 2025-03-31 | +| MacOS 15.6 (x64) | `darwin-x64` | 2026-01-21 | | MacOS 15.2 (ARM64) | `darwin-arm` | 2025-03-07 | | Windows 11 (x64) + WSL Ubuntu | `win11-x64` | 2025-06-20 | | Windows 11 (ARM) + WSL Ubuntu | `win11-arm` | 2025-02-23 | @@ -303,7 +303,7 @@ browser. *In the `"Get Node.js®"` section:* -1. Select the LTS version (currently `"v22.14.0 (LTS)"`) in the first dropdown +1. Select the LTS version (currently `"v24.13.0 (LTS)"`) in the first dropdown *In the `"Or get a prebuilt Node.js® for"` section:* diff --git a/tests/cli/boxednode.sh b/tests/cli/boxednode.sh index d6c2a96..64bfb88 100755 --- a/tests/cli/boxednode.sh +++ b/tests/cli/boxednode.sh @@ -11,8 +11,6 @@ curl -o xlsx-cli.js https://docs.sheetjs.com/cli/xlsx-cli.js npm i --save https://cdn.sheetjs.com/xlsx-latest/xlsx-latest.tgz exit-on-epipe commander@2 -## NOTE: these steps are for darwin-arm - -npx -y boxednode@2.4.4 -s xlsx-cli.js -t xlsx-cli -n 23.11.0 +npx -y boxednode -s xlsx-cli.js -t xlsx-cli || npx -y boxednode -s xlsx-cli.js -t xlsx-cli -n 23.11.0 ./xlsx-cli pres.numbers diff --git a/tests/cli/nexe.sh b/tests/cli/nexe.sh index 9391ce1..e1e2491 100755 --- a/tests/cli/nexe.sh +++ b/tests/cli/nexe.sh @@ -11,7 +11,20 @@ curl -o xlsx-cli.js https://docs.sheetjs.com/cli/xlsx-cli.js npm i --save https://cdn.sheetjs.com/xlsx-latest/xlsx-latest.tgz exit-on-epipe commander@2 -## npx -y nexe -t 14.15.3 xlsx-cli.js ## does not work on arm64 -npx -y nexe xlsx-cli.js --build --python=$(which python3) --make="-j8" +OS="$(uname -s)" +ARCH="$(uname -m)" +case "$OS" in + Darwin) OS="macos" ;; + Linux) OS="linux" ;; + *) echo "unsupported OS: $OS"; exit 1 ;; +esac + +case "$ARCH" in + x86_64) npx -y nexe -t 14.15.3 xlsx-cli.js ;; + arm64|aarch64) npx -y nexe xlsx-cli.js --build --python=$(which python3) --make="-j8" ;; + *) echo "unsupported architecture: $ARCH"; exit 1 ;; +esac + +# Run the generated binary ./xlsx-cli pres.numbers diff --git a/tests/cli/pkg.sh b/tests/cli/pkg.sh index 4a9dc7a..8d0f93e 100755 --- a/tests/cli/pkg.sh +++ b/tests/cli/pkg.sh @@ -11,8 +11,23 @@ curl -o xlsx-cli.js https://docs.sheetjs.com/cli/xlsx-cli.js npm i --save https://cdn.sheetjs.com/xlsx-latest/xlsx-latest.tgz exit-on-epipe commander@2 -npx -y pkg -t 'node18-win-arm64,node18-linux-arm64,node18-macos-arm64' xlsx-cli.js +OS="$(uname -s)" +ARCH="$(uname -m)" -## NOTE: these steps are for darwin +case "$OS" in + Darwin) OS="macos" ;; + Linux) OS="linux" ;; + *) echo "unsupported OS: $OS"; exit 1 ;; +esac -./xlsx-cli-macos pres.numbers +case "$ARCH" in + x86_64) ARCH="x64" ;; + arm64|aarch64) ARCH="arm64" ;; + *) echo "unsupported arch: $ARCH"; exit 1 ;; +esac + +# Build for the current platform +npx -y pkg -t "node18-win-${ARCH},node18-linux-${ARCH},node18-macos-${ARCH}" xlsx-cli.js + +# Run the appropriate binary based on OS +./xlsx-cli-${OS} pres.numbers diff --git a/tests/cli/txiki.sh b/tests/cli/txiki.sh index 8c0fa1a..8ed3be1 100755 --- a/tests/cli/txiki.sh +++ b/tests/cli/txiki.sh @@ -27,11 +27,34 @@ EOF curl -LO https://cdn.sheetjs.com/xlsx-latest/package/dist/xlsx.full.min.js -## NOTE: these steps are for darwin -curl -LO https://github.com/saghul/txiki.js/releases/download/v24.12.0/txiki-macos.zip -unzip txiki-macos.zip -mv txiki-macos/tjs . -chmod +x tjs +OS="$(uname -s)" + +case "$OS" in + Darwin) + curl -LO https://github.com/saghul/txiki.js/releases/download/v24.12.0/txiki-macos.zip + unzip txiki-macos.zip + mv txiki-macos/tjs . + chmod +x tjs + ;; + + Linux) + echo "Installing txiki.js for Linux" + git clone --recursive https://github.com/saghul/txiki.js --shallow-submodules + cd txiki.js + + make || ( + echo "!!! First build attempt failed, trying with system libffi..." + rm -rf build + cmake -B build -DCMAKE_BUILD_TYPE=Release -DUSE_EXTERNAL_FFI=ON + cmake --build build -j 8 + ) + + cp build/tjs ../ + cd .. + ;; + + *) echo "Unsupported OS: $OS"; exit 1 ;; +esac npx -y esbuild sheet2csv.js --bundle --outfile=bundle.js --platform=neutral diff --git a/tests/engines/duktape-perl.sh b/tests/engines/duktape-perl.sh new file mode 100755 index 0000000..1e5bb3c --- /dev/null +++ b/tests/engines/duktape-perl.sh @@ -0,0 +1,16 @@ +#!/bin/bash +# https://docs.sheetjs.com/docs/demos/engines/duktape#perl-demo + +cd /tmp +rm -rf sheetjs-duk-perl +mkdir sheetjs-duk-perl +cd sheetjs-duk-perl + +curl -LO https://docs.sheetjs.com/duk/SheetJSDuk.pl + +curl -LO https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/xlsx.extendscript.js +curl -LO https://docs.sheetjs.com/pres.xlsx + +perl SheetJSDuk.pl pres.xlsx; echo $? + +npx -y xlsx-cli SheetJSDuk.xlsb \ No newline at end of file diff --git a/tests/engines/duktape-php.sh b/tests/engines/duktape-php.sh new file mode 100755 index 0000000..9c0ddca --- /dev/null +++ b/tests/engines/duktape-php.sh @@ -0,0 +1,36 @@ +#!/bin/bash +# https://docs.sheetjs.com/docs/demos/engines/duktape#php-demo + +cd /tmp +rm -rf sheetjs-duk-php +mkdir sheetjs-duk-php +cd sheetjs-duk-php + +curl -LO https://duktape.org/duktape-2.7.0.tar.xz +tar -xJf duktape-2.7.0.tar.xz +cd duktape-2.7.0 +make -f Makefile.sharedlibrary +cd .. + +OS="$(uname -s)" + +case "$OS" in + Darwin) LIB_NAME="libduktape.207.20700.so" ;; + Linux) LIB_NAME="libduktape.so.207.20700" ;; + *) echo "Unsupported OS: $OS"; exit 1 ;; +esac + +cp "duktape-2.7.0/$LIB_NAME" . + +curl -LO https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/shim.min.js +curl -LO https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/xlsx.full.min.js +curl -LO https://docs.sheetjs.com/pres.numbers + +curl -LO https://docs.sheetjs.com/duk/SheetJSDuk.php + +sed "s#libduktape.207.20700.so#$LIB_NAME#g" SheetJSDuk.php > SheetJSDuk.php.tmp +mv SheetJSDuk.php.tmp SheetJSDuk.php + +php SheetJSDuk.php pres.numbers; echo $? + +npx -y xlsx-cli sheetjsw.xlsb diff --git a/tests/engines/duktape-python.sh b/tests/engines/duktape-python.sh new file mode 100755 index 0000000..a84bb04 --- /dev/null +++ b/tests/engines/duktape-python.sh @@ -0,0 +1,36 @@ +#!/bin/bash +# https://docs.sheetjs.com/docs/demos/engines/duktape#python-demo + +cd /tmp +rm -rf sheetjs-duk-python +mkdir sheetjs-duk-python +cd sheetjs-duk-python + +curl -LO https://duktape.org/duktape-2.7.0.tar.xz +tar -xJf duktape-2.7.0.tar.xz +cd duktape-2.7.0 +make -f Makefile.sharedlibrary +cd .. + +OS="$(uname -s)" + +case "$OS" in + Darwin) LIB_NAME="libduktape.207.20700.so" ;; + Linux) LIB_NAME="libduktape.so.207.20700" ;; + *) echo "Unsupported OS: $OS"; exit 1 ;; +esac + +cp "duktape-2.7.0/$LIB_NAME" . + +curl -LO https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/shim.min.js +curl -LO https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/xlsx.full.min.js +curl -LO https://docs.sheetjs.com/pres.numbers + +curl -LO https://docs.sheetjs.com/duk/SheetJSDuk.py + +sed "s#libduktape.207.20700.so#$LIB_NAME#g" SheetJSDuk.py > SheetJSDuk.py.tmp +mv SheetJSDuk.py.tmp SheetJSDuk.py + +python3 SheetJSDuk.py pres.numbers; echo $? + +npx -y xlsx-cli sheetjsw.xlsb \ No newline at end of file diff --git a/tests/engines/duktape-rust.sh b/tests/engines/duktape-rust.sh new file mode 100755 index 0000000..961d9a7 --- /dev/null +++ b/tests/engines/duktape-rust.sh @@ -0,0 +1,20 @@ +#!/bin/bash +# https://docs.sheetjs.com/docs/demos/engines/duktape#rust-demo + +cd /tmp +rm -rf sheetjs-duk-rs +cargo new sheetjs-duk-rs +cd sheetjs-duk-rs + +curl -L -o src/shim.min.js https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/shim.min.js +curl -L -o src/xlsx.full.min.js https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/xlsx.full.min.js + +curl -LO https://docs.sheetjs.com/pres.numbers + +curl -L -o src/main.rs https://docs.sheetjs.com/duk/main.rs + +cargo add ducc base64 + +cargo run -- pres.numbers; echo $? + +npx -y xlsx-cli sheetjsw.xlsb \ No newline at end of file diff --git a/tests/engines/duktape-zig.sh b/tests/engines/duktape-zig.sh index 17cc795..172bf33 100755 --- a/tests/engines/duktape-zig.sh +++ b/tests/engines/duktape-zig.sh @@ -7,10 +7,12 @@ mkdir -p sheetjs-zig cd sheetjs-zig ## NOTE: these steps are for darwin -case "$(uname -m)" in +ARCH="$(uname -m)" + +case "$ARCH" in arm64) curl -LO https://ziglang.org/download/0.15.2/zig-aarch64-macos-0.15.2.tar.xz ;; x86_64) curl -LO https://ziglang.org/download/0.15.2/zig-x86_64-macos-0.15.2.tar.xz ;; - *) echo "unsupported arch $(uname -m)"; exit 1 ;; + *) echo "unsupported arch $ARCH"; exit 1 ;; esac tar -xzf zig-*.tar.xz diff --git a/tests/engines/jint.sh b/tests/engines/jint.sh new file mode 100755 index 0000000..c793952 --- /dev/null +++ b/tests/engines/jint.sh @@ -0,0 +1,76 @@ +#!/bin/bash +# https://docs.sheetjs.com/docs/demos/engines/jint + +export DOTNET_CLI_TELEMETRY_OPTOUT=1 + +cd /tmp +rm -rf SheetJSJint +mkdir SheetJSJint +cd SheetJSJint + +dotnet new console +dotnet run + +dotnet nuget add source https://www.myget.org/F/jint/api/v3/index.json +dotnet add package Jint --version 4.5.0 + +curl -LO https://cdn.sheetjs.com/xlsx-latest/package/dist/shim.min.js +curl -LO https://cdn.sheetjs.com/xlsx-latest/package/dist/xlsx.full.min.js +curl -LO https://docs.sheetjs.com/pres.xlsx + +cat >Program.cs <SheetJSPuppeteer.ts < console.log("PAGE LOG:", msg.text())); -await page.setViewport({width: 1920, height: 1080}); -await page.goto('https://sheetjs.com/demos/table'); - -/* (2) Load the standalone SheetJS build from the CDN */ -await page.addScriptTag({ url: 'https://cdn.sheetjs.com/xlsx-latest/package/dist/xlsx.full.min.js' }); - -/* (3) Run the snippet in browser and return data */ -const b64 = await page.evaluate(() => { - - /* find first table */ - var table = document.body.getElementsByTagName('table')[0]; - - /* call table_to_book on first table */ - var wb = XLSX.utils.table_to_book(table); - - /* generate XLSB and return binary string */ - return XLSX.write(wb, {type: "base64", bookType: "xlsb"}); -}); -/* (4) write data to file */ -Deno.writeFileSync("SheetJSPuppeteer.xlsb", decodeBase64(b64)); - -await browser.close(); -EOF - -deno run -A --unstable SheetJSPuppeteer.ts -npx -y xlsx-cli SheetJSPuppeteer.xlsb