@kern0x1b/penstock-cli 0.0.0-stage → 26.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/arial-metrics.json +1 -0
- package/dist/licensing.json +17 -0
- package/dist/penstock.js +1445 -0
- package/dist/wrapper/penstockw +68 -0
- package/dist/wrapper/penstockw.cmd +55 -0
- package/package.json +39 -4
- package/README.md +0 -3
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
set -e
|
|
3
|
+
|
|
4
|
+
directory=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
|
|
5
|
+
properties="$directory/penstock/wrapper/penstock-wrapper.properties"
|
|
6
|
+
|
|
7
|
+
property() {
|
|
8
|
+
[ -f "$properties" ] || return 0
|
|
9
|
+
sed -n "s/^$1=//p" "$properties" | tr -d '\r' | head -n 1 | sed 's/[[:space:]]*$//'
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
if ! command -v node >/dev/null 2>&1 || ! command -v npm >/dev/null 2>&1; then
|
|
13
|
+
echo "penstockw needs Node.js 22.22 or later, with npm, on the PATH." >&2
|
|
14
|
+
exit 127
|
|
15
|
+
fi
|
|
16
|
+
|
|
17
|
+
version=$(property version)
|
|
18
|
+
distribution=$(property distribution)
|
|
19
|
+
case "$distribution" in
|
|
20
|
+
./*|../*) distribution="$directory/$distribution" ;;
|
|
21
|
+
esac
|
|
22
|
+
|
|
23
|
+
if [ -z "$version" ] || [ "$version" = latest ]; then
|
|
24
|
+
version=$(npm view @kern0x1b/penstock-cli version 2>/dev/null) || version=
|
|
25
|
+
version=$(printf '%s\n' "$version" | tail -n 1)
|
|
26
|
+
if [ -z "$version" ]; then
|
|
27
|
+
echo "penstockw could not find the latest @kern0x1b/penstock-cli; pin a version in $properties" >&2
|
|
28
|
+
exit 1
|
|
29
|
+
fi
|
|
30
|
+
fi
|
|
31
|
+
|
|
32
|
+
case "$version" in
|
|
33
|
+
''|[!A-Za-z0-9]*|*[!A-Za-z0-9._+-]*)
|
|
34
|
+
echo "penstockw: $version is not a valid version; fix $properties" >&2
|
|
35
|
+
exit 1 ;;
|
|
36
|
+
esac
|
|
37
|
+
case "$distribution" in
|
|
38
|
+
-*)
|
|
39
|
+
echo "penstockw: $distribution is not a valid distribution; fix $properties" >&2
|
|
40
|
+
exit 1 ;;
|
|
41
|
+
esac
|
|
42
|
+
|
|
43
|
+
if [ -z "${PENSTOCK_HOME:-}" ] && [ -z "${HOME:-}" ]; then
|
|
44
|
+
echo "penstockw needs HOME or PENSTOCK_HOME to know where to keep downloads." >&2
|
|
45
|
+
exit 1
|
|
46
|
+
fi
|
|
47
|
+
home=${PENSTOCK_HOME:-$HOME/.penstock}
|
|
48
|
+
dists="$home/wrapper/dists"
|
|
49
|
+
entry="$dists/$version/node_modules/@kern0x1b/penstock-cli/dist/penstock.js"
|
|
50
|
+
|
|
51
|
+
if [ ! -f "$entry" ]; then
|
|
52
|
+
echo "Downloading Penstock $version" >&2
|
|
53
|
+
mkdir -p "$dists"
|
|
54
|
+
staging="$dists/.$version.$$"
|
|
55
|
+
rm -rf "$staging"
|
|
56
|
+
if ! npm install --prefix "$staging" --no-audit --no-fund --no-package-lock --loglevel=error "${distribution:-@kern0x1b/penstock-cli@$version}" >&2; then
|
|
57
|
+
rm -rf "$staging"
|
|
58
|
+
exit 1
|
|
59
|
+
fi
|
|
60
|
+
if [ ! -f "$entry" ]; then
|
|
61
|
+
rm -rf "$dists/$version"
|
|
62
|
+
mv "$staging" "$dists/$version" 2>/dev/null || rm -rf "$staging"
|
|
63
|
+
else
|
|
64
|
+
rm -rf "$staging"
|
|
65
|
+
fi
|
|
66
|
+
fi
|
|
67
|
+
|
|
68
|
+
exec node "$entry" "$@"
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
@echo off
|
|
2
|
+
setlocal
|
|
3
|
+
|
|
4
|
+
set "DIR=%~dp0"
|
|
5
|
+
set "PROPERTIES=%DIR%penstock\wrapper\penstock-wrapper.properties"
|
|
6
|
+
set "VERSION="
|
|
7
|
+
set "DISTRIBUTION="
|
|
8
|
+
if exist "%PROPERTIES%" (
|
|
9
|
+
for /f "usebackq tokens=1,* delims==" %%a in ("%PROPERTIES%") do (
|
|
10
|
+
if "%%a"=="version" set "VERSION=%%b"
|
|
11
|
+
if "%%a"=="distribution" set "DISTRIBUTION=%%b"
|
|
12
|
+
)
|
|
13
|
+
)
|
|
14
|
+
if "%DISTRIBUTION:~0,1%"=="." set "DISTRIBUTION=%DIR%%DISTRIBUTION%"
|
|
15
|
+
|
|
16
|
+
where node >nul 2>nul || goto :nonode
|
|
17
|
+
where npm >nul 2>nul || goto :nonode
|
|
18
|
+
|
|
19
|
+
if "%VERSION%"=="" set "VERSION=latest"
|
|
20
|
+
if "%VERSION%"=="latest" (
|
|
21
|
+
for /f "usebackq delims=" %%v in (`npm view @kern0x1b/penstock-cli version 2^>nul`) do set "VERSION=%%v"
|
|
22
|
+
)
|
|
23
|
+
if "%VERSION%"=="latest" (
|
|
24
|
+
echo penstockw could not find the latest @kern0x1b/penstock-cli; pin a version in %PROPERTIES% 1>&2
|
|
25
|
+
exit /b 1
|
|
26
|
+
)
|
|
27
|
+
|
|
28
|
+
if "%PENSTOCK_HOME%"=="" (set "HOMEDIR=%USERPROFILE%\.penstock") else (set "HOMEDIR=%PENSTOCK_HOME%")
|
|
29
|
+
set "DISTS=%HOMEDIR%\wrapper\dists"
|
|
30
|
+
set "ENTRY=%DISTS%\%VERSION%\node_modules\@kern0x1b\penstock-cli\dist\penstock.js"
|
|
31
|
+
if exist "%ENTRY%" goto :run
|
|
32
|
+
|
|
33
|
+
echo Downloading Penstock %VERSION% 1>&2
|
|
34
|
+
if not exist "%DISTS%" mkdir "%DISTS%"
|
|
35
|
+
set "STAGING=%DISTS%\.%VERSION%.%RANDOM%"
|
|
36
|
+
if "%DISTRIBUTION%"=="" set "DISTRIBUTION=@kern0x1b/penstock-cli@%VERSION%"
|
|
37
|
+
call npm install --prefix "%STAGING%" --no-audit --no-fund --no-package-lock --loglevel=error "%DISTRIBUTION%" 1>&2
|
|
38
|
+
if errorlevel 1 (
|
|
39
|
+
rmdir /s /q "%STAGING%" 2>nul
|
|
40
|
+
exit /b 1
|
|
41
|
+
)
|
|
42
|
+
if exist "%ENTRY%" (
|
|
43
|
+
rmdir /s /q "%STAGING%" 2>nul
|
|
44
|
+
) else (
|
|
45
|
+
if exist "%DISTS%\%VERSION%" rmdir /s /q "%DISTS%\%VERSION%"
|
|
46
|
+
move "%STAGING%" "%DISTS%\%VERSION%" >nul
|
|
47
|
+
)
|
|
48
|
+
|
|
49
|
+
:run
|
|
50
|
+
node "%ENTRY%" %*
|
|
51
|
+
exit /b %errorlevel%
|
|
52
|
+
|
|
53
|
+
:nonode
|
|
54
|
+
echo penstockw needs Node.js 22.22 or later, with npm, on the PATH. 1>&2
|
|
55
|
+
exit /b 127
|
package/package.json
CHANGED
|
@@ -1,6 +1,41 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kern0x1b/penstock-cli",
|
|
3
|
-
"version": "
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "26.10.0",
|
|
4
|
+
"description": "Check, lint, lay out, draw and deploy BPMN diagrams with the configuration the project already has.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"bin": {
|
|
7
|
+
"penstock": "./dist/penstock.js"
|
|
8
|
+
},
|
|
9
|
+
"files": [
|
|
10
|
+
"dist"
|
|
11
|
+
],
|
|
12
|
+
"engines": {
|
|
13
|
+
"node": "^22.22.2 || ^24.15.0 || >=26.0.0"
|
|
14
|
+
},
|
|
15
|
+
"dependencies": {
|
|
16
|
+
"@bpmn-io/dmn-migrate": "0.7.1",
|
|
17
|
+
"@mr_mint/elkjs-libavoid": "^0.5.0",
|
|
18
|
+
"bpmn-js": "18.30.1",
|
|
19
|
+
"bpmn-js-differ": "^3.2.0",
|
|
20
|
+
"bpmn-moddle": "^10.2.0",
|
|
21
|
+
"bpmnlint": "11.14.0",
|
|
22
|
+
"bpmnlint-plugin-camunda-compat": "2.61.0",
|
|
23
|
+
"camunda-bpmn-moddle": "^8.0.1",
|
|
24
|
+
"camunda-dmn-moddle": "^1.3.1",
|
|
25
|
+
"dmn-moddle": "^12.2.1",
|
|
26
|
+
"fflate": "^0.8.3",
|
|
27
|
+
"jsdom": "^30.1.1",
|
|
28
|
+
"saxen": "^11.2.0",
|
|
29
|
+
"webcola": "^3.4.0",
|
|
30
|
+
"yaml": "^2.9.1",
|
|
31
|
+
"zeebe-bpmn-moddle": "^2.0.0"
|
|
32
|
+
},
|
|
33
|
+
"peerDependencies": {
|
|
34
|
+
"puppeteer": "*"
|
|
35
|
+
},
|
|
36
|
+
"peerDependenciesMeta": {
|
|
37
|
+
"puppeteer": {
|
|
38
|
+
"optional": true
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
package/README.md
DELETED