bpmnlint-plugin-camunda-compat 2.35.0 → 2.37.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/README.md
CHANGED
@@ -4,6 +4,13 @@
|
|
4
4
|
|
5
5
|
A [bpmnlint](https://github.com/bpmn-io/bpmnlint) plug-in that checks whether a given BPMN process can be executed with [Camunda](https://camunda.com/).
|
6
6
|
|
7
|
+
## Installation
|
8
|
+
|
9
|
+
To use the plug-in, ensure it is installed is installed in your project, alongside [bpmnlint](https://github.com/bpmn-io/bpmnlint):
|
10
|
+
|
11
|
+
```sh
|
12
|
+
npm install -D bpmnlint bpmnlint-plugin-camunda-compat
|
13
|
+
```
|
7
14
|
|
8
15
|
## Usage
|
9
16
|
|
@@ -21,8 +28,50 @@ Add configuration corresponding to your execution platform and version to your [
|
|
21
28
|
}
|
22
29
|
```
|
23
30
|
|
31
|
+
> [!WARNING]
|
32
|
+
> BPMN diagrams validated must be parsed with the respective [Camunda 7](https://github.com/camunda/camunda-bpmn-moddle) or [Camunda 8](https://github.com/camunda/zeebe-bpmn-moddle) moddle extension.
|
33
|
+
>
|
34
|
+
> See also [command line use](#command-line-use).
|
35
|
+
|
36
|
+
## Dynamic Linter Configuration
|
37
|
+
|
24
38
|
Use [`@camunda/linting`](https://github.com/camunda/linting) to configure the linter dynamically based on the [execution platform and version](https://github.com/camunda/modeler-moddle).
|
25
39
|
|
40
|
+
## Command Line Use
|
41
|
+
|
42
|
+
When using `bpmnlint` via the command line, ensure it picks up the respective [Camunda 7](https://github.com/camunda/camunda-bpmn-moddle) or [Camunda 8](https://github.com/camunda/zeebe-bpmn-moddle) moddle extension.
|
43
|
+
|
44
|
+
For Camunda 8, install the [zeebe-bpmn-moddle extension](https://github.com/camunda/zeebe-bpmn-moddle):
|
45
|
+
|
46
|
+
```
|
47
|
+
npm install bpmnlint zeebe-bpmn-moddle bpmnlint-plugin-camunda-compat
|
48
|
+
```
|
49
|
+
|
50
|
+
Extend your configuration so bpmnlint picks-up the extension when parsing a BPMN diagram:
|
51
|
+
|
52
|
+
```diff
|
53
|
+
--- .bpmnlintrc
|
54
|
+
+++ .bpmnlintrc
|
55
|
+
@@ -1,9 +1,12 @@
|
56
|
+
{
|
57
|
+
"extends": [
|
58
|
+
"bpmnlint:recommended",
|
59
|
+
"plugin:camunda-compat/camunda-cloud-8-7"
|
60
|
+
],
|
61
|
+
"rules": {
|
62
|
+
"camunda-compat/timer": "off"
|
63
|
+
+ },
|
64
|
+
+ "moddleExtensions": {
|
65
|
+
+ "zeebe": "zeebe-bpmn-moddle/resources/zeebe.json"
|
66
|
+
}
|
67
|
+
}
|
68
|
+
```
|
69
|
+
|
70
|
+
Invoke `bpmnlint` from your command line in the usual ways:
|
71
|
+
|
72
|
+
```
|
73
|
+
npx bpmnlint my-diagram.bpmn
|
74
|
+
```
|
26
75
|
|
27
76
|
## Resources
|
28
77
|
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "bpmnlint-plugin-camunda-compat",
|
3
|
-
"version": "2.
|
3
|
+
"version": "2.37.0",
|
4
4
|
"description": "A bpmnlint plug-in for Camunda compatibility",
|
5
5
|
"main": "index.js",
|
6
6
|
"scripts": {
|
@@ -25,7 +25,7 @@
|
|
25
25
|
"license": "MIT",
|
26
26
|
"devDependencies": {
|
27
27
|
"bpmn-moddle": "^9.0.1",
|
28
|
-
"bpmnlint": "^11.
|
28
|
+
"bpmnlint": "^11.6.0",
|
29
29
|
"camunda-bpmn-moddle": "^7.0.1",
|
30
30
|
"chai": "^4.4.1",
|
31
31
|
"eslint": "^9.20.1",
|
@@ -36,7 +36,9 @@ module.exports = skipInNonExecutableProcess(function() {
|
|
36
36
|
}
|
37
37
|
|
38
38
|
if (isFeelProperty([ propertyName, propertyValue ])) {
|
39
|
-
const lintErrors = lintExpression(propertyValue.substring(1)
|
39
|
+
const lintErrors = lintExpression(propertyValue.substring(1), {
|
40
|
+
parserDialect: 'camunda'
|
41
|
+
});
|
40
42
|
|
41
43
|
// syntax error
|
42
44
|
if (lintErrors.find(({ type }) => type === 'Syntax Error')) {
|
@@ -1,7 +1,5 @@
|
|
1
1
|
const { is } = require('bpmnlint-utils');
|
2
2
|
|
3
|
-
const { annotateRule } = require('../helper');
|
4
|
-
|
5
3
|
const { skipInNonExecutableProcess } = require('../utils/rule');
|
6
4
|
|
7
5
|
module.exports = skipInNonExecutableProcess(function() {
|
@@ -16,7 +14,12 @@ module.exports = skipInNonExecutableProcess(function() {
|
|
16
14
|
}
|
17
15
|
}
|
18
16
|
|
19
|
-
return
|
17
|
+
return {
|
18
|
+
meta: {
|
19
|
+
documentation: {
|
20
|
+
url: 'https://docs.camunda.org/manual/latest/modeler/history-time-to-live/'
|
21
|
+
}
|
22
|
+
},
|
20
23
|
check
|
21
|
-
}
|
24
|
+
};
|
22
25
|
});
|