Skip to content

Commit 173073d

Browse files
committed
chore: update expression readme
1 parent 2f1f51e commit 173073d

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

.github/workflows/push_main.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,6 @@ jobs:
7171
verbose: true
7272
release_check:
7373
runs-on: ubuntu-latest
74-
needs: [test, lint]
7574
outputs:
7675
git_diff: ${{ steps.output.outputs.git_diff }}
7776
steps:
@@ -94,7 +93,7 @@ jobs:
9493
echo "::set-output name=git_diff::${{ env.GIT_DIFF }}"
9594
release:
9695
runs-on: ubuntu-latest
97-
needs: [release_check]
96+
needs: [test, lint, release_check]
9897
if: ${{ needs.release_check.outputs.git_diff }}
9998
outputs:
10099
version: ${{ steps.release.outputs.version }}

script/standard/README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ The standard script engine is a basic implementation of the script.Engine interf
2222
|`*`|multiplication|number|return the left-side number multiplied by the right-side number|
2323
|`/`|division|number|return the left-side number divided by the right-side number|
2424
|`%`|modulus|integer|return the remainder of the left-side number divided by the right-side number|
25+
|`in`|in|number\|string\|boolean and collection|return true if the left-side argument is in the right-side collection|
26+
|`not in`|in|number\|string\|boolean and collection|return true if the left-side argument is not in the right-side collection|
2527

2628
All operators have a left-side and right-side argument, expect the not `!` operator which only as a right-side argument. The arguments can be strings, numbers, boolean values, arrays, objects, a special parameter, or other expressions, for example `true && true || false` includes the logical AND operator with left-side `true` and right-side a logical OR operator with left-side `true` and right-side `false`.
2729

@@ -33,6 +35,10 @@ The right side pattern should be passed as a string, between single or double qu
3335

3436
> the regex operation is handled by the standard [`regexp`](https://pkg.go.dev/regexp) golang library `Match` function.
3537
38+
### In and Not In
39+
40+
The `in` and `not in` operators will check if the left-side value, treated either as a number, string, or boolean value, is included in the right-side collection values, a collection can either be an array, slice, or the values of a map.
41+
3642
## Special Parameters
3743

3844
The following symbols/tokens have special meaning when used in script expressions and will be replaced before the expression is evaluated. The symbols used within a string, between single or double quotes, will not be replaced.

0 commit comments

Comments
 (0)