@runfile/cli 0.12.0 → 0.12.1
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/bin/darwin-arm64/README.md +11 -3
- package/bin/darwin-arm64/run +0 -0
- package/bin/darwin-x64/README.md +11 -3
- package/bin/darwin-x64/run +0 -0
- package/bin/linux-arm64/README.md +11 -3
- package/bin/linux-arm64/run +0 -0
- package/bin/linux-x64/README.md +11 -3
- package/bin/linux-x64/run +0 -0
- package/bin/win32-arm64/run.exe +0 -0
- package/bin/win32-x64/run.exe +0 -0
- package/package.json +1 -1
|
@@ -167,9 +167,9 @@ $ run :env inject -f .env.production -- ./deploy.sh # encrypted values aut
|
|
|
167
167
|
|
|
168
168
|
#### Powerful argument substitution
|
|
169
169
|
|
|
170
|
-
Positional, named, flags, env vars, and runtime context (`{{ RUN.os }}` / `{{ RUN.
|
|
171
|
-
`{{ RUN.file }}` / `{{ RUN.parent }}`) — with chained fallbacks and required values. The
|
|
172
|
-
avoids collisions with shell `$(...)` command substitution.
|
|
170
|
+
Positional, named, flags, env vars, and runtime context (`{{ RUN.os }}` / `{{ RUN.arch }}` / `{{ RUN.shell }}` /
|
|
171
|
+
`{{ RUN.cwd }}` / `{{ RUN.file }}` / `{{ RUN.parent }}`) — with chained fallbacks and required values. The
|
|
172
|
+
`{{ ... }}` syntax avoids collisions with shell `$(...)` command substitution.
|
|
173
173
|
|
|
174
174
|
```jsonc
|
|
175
175
|
"PORT": "{{ ARGS.port ? ENV.PORT ? '3000' }}",
|
|
@@ -242,6 +242,7 @@ and work as full substitution bodies *or* as chain segments:
|
|
|
242
242
|
// transform : escape, repeat, replace_all, remove_all
|
|
243
243
|
// regex : regex_replace, regex_remove, regex_matches
|
|
244
244
|
// build : concat, join
|
|
245
|
+
// split : nth, first, last, count_parts
|
|
245
246
|
// encoding : base64_encode, base64_decode
|
|
246
247
|
// shell : shell_quote
|
|
247
248
|
// variables : define
|
|
@@ -253,6 +254,13 @@ and work as full substitution bodies *or* as chain segments:
|
|
|
253
254
|
"go test {{ replace_all(ARGS.flags, ' ', ' -tag=') }}",
|
|
254
255
|
// Strip every match of a regex (here: collapse whitespace runs to a single space):
|
|
255
256
|
"echo {{ regex_replace(ARGS.text, '\\s+', ' ') }}",
|
|
257
|
+
// Split-by-separator scalar accessors — string in, string out, no list type:
|
|
258
|
+
// basename idiom (last segment after `/`); empty string when input ends in `/`.
|
|
259
|
+
"echo basename={{ last(ARGS.path, '/') }}",
|
|
260
|
+
// Pull out the N-th comma-separated field; out-of-bounds returns "".
|
|
261
|
+
"echo target={{ nth(ARGS.csv, ',', '1') }}",
|
|
262
|
+
// Pair `count_parts` with `nth` to bound-check before indexing:
|
|
263
|
+
// "if": "{{ count_parts(ARGS.csv, ',') == '3' }}"
|
|
256
264
|
// Boolean-returning helpers are valid DSL `Truthy` values — use them in `if`:
|
|
257
265
|
// "if": "{{ starts_with(ARGS.path, '/usr') }}"
|
|
258
266
|
// "if": "{{ regex_matches(ARGS.tag, '^v[0-9]+\\.[0-9]+$') }}"
|
package/bin/darwin-arm64/run
CHANGED
|
Binary file
|
package/bin/darwin-x64/README.md
CHANGED
|
@@ -167,9 +167,9 @@ $ run :env inject -f .env.production -- ./deploy.sh # encrypted values aut
|
|
|
167
167
|
|
|
168
168
|
#### Powerful argument substitution
|
|
169
169
|
|
|
170
|
-
Positional, named, flags, env vars, and runtime context (`{{ RUN.os }}` / `{{ RUN.
|
|
171
|
-
`{{ RUN.file }}` / `{{ RUN.parent }}`) — with chained fallbacks and required values. The
|
|
172
|
-
avoids collisions with shell `$(...)` command substitution.
|
|
170
|
+
Positional, named, flags, env vars, and runtime context (`{{ RUN.os }}` / `{{ RUN.arch }}` / `{{ RUN.shell }}` /
|
|
171
|
+
`{{ RUN.cwd }}` / `{{ RUN.file }}` / `{{ RUN.parent }}`) — with chained fallbacks and required values. The
|
|
172
|
+
`{{ ... }}` syntax avoids collisions with shell `$(...)` command substitution.
|
|
173
173
|
|
|
174
174
|
```jsonc
|
|
175
175
|
"PORT": "{{ ARGS.port ? ENV.PORT ? '3000' }}",
|
|
@@ -242,6 +242,7 @@ and work as full substitution bodies *or* as chain segments:
|
|
|
242
242
|
// transform : escape, repeat, replace_all, remove_all
|
|
243
243
|
// regex : regex_replace, regex_remove, regex_matches
|
|
244
244
|
// build : concat, join
|
|
245
|
+
// split : nth, first, last, count_parts
|
|
245
246
|
// encoding : base64_encode, base64_decode
|
|
246
247
|
// shell : shell_quote
|
|
247
248
|
// variables : define
|
|
@@ -253,6 +254,13 @@ and work as full substitution bodies *or* as chain segments:
|
|
|
253
254
|
"go test {{ replace_all(ARGS.flags, ' ', ' -tag=') }}",
|
|
254
255
|
// Strip every match of a regex (here: collapse whitespace runs to a single space):
|
|
255
256
|
"echo {{ regex_replace(ARGS.text, '\\s+', ' ') }}",
|
|
257
|
+
// Split-by-separator scalar accessors — string in, string out, no list type:
|
|
258
|
+
// basename idiom (last segment after `/`); empty string when input ends in `/`.
|
|
259
|
+
"echo basename={{ last(ARGS.path, '/') }}",
|
|
260
|
+
// Pull out the N-th comma-separated field; out-of-bounds returns "".
|
|
261
|
+
"echo target={{ nth(ARGS.csv, ',', '1') }}",
|
|
262
|
+
// Pair `count_parts` with `nth` to bound-check before indexing:
|
|
263
|
+
// "if": "{{ count_parts(ARGS.csv, ',') == '3' }}"
|
|
256
264
|
// Boolean-returning helpers are valid DSL `Truthy` values — use them in `if`:
|
|
257
265
|
// "if": "{{ starts_with(ARGS.path, '/usr') }}"
|
|
258
266
|
// "if": "{{ regex_matches(ARGS.tag, '^v[0-9]+\\.[0-9]+$') }}"
|
package/bin/darwin-x64/run
CHANGED
|
Binary file
|
|
@@ -167,9 +167,9 @@ $ run :env inject -f .env.production -- ./deploy.sh # encrypted values aut
|
|
|
167
167
|
|
|
168
168
|
#### Powerful argument substitution
|
|
169
169
|
|
|
170
|
-
Positional, named, flags, env vars, and runtime context (`{{ RUN.os }}` / `{{ RUN.
|
|
171
|
-
`{{ RUN.file }}` / `{{ RUN.parent }}`) — with chained fallbacks and required values. The
|
|
172
|
-
avoids collisions with shell `$(...)` command substitution.
|
|
170
|
+
Positional, named, flags, env vars, and runtime context (`{{ RUN.os }}` / `{{ RUN.arch }}` / `{{ RUN.shell }}` /
|
|
171
|
+
`{{ RUN.cwd }}` / `{{ RUN.file }}` / `{{ RUN.parent }}`) — with chained fallbacks and required values. The
|
|
172
|
+
`{{ ... }}` syntax avoids collisions with shell `$(...)` command substitution.
|
|
173
173
|
|
|
174
174
|
```jsonc
|
|
175
175
|
"PORT": "{{ ARGS.port ? ENV.PORT ? '3000' }}",
|
|
@@ -242,6 +242,7 @@ and work as full substitution bodies *or* as chain segments:
|
|
|
242
242
|
// transform : escape, repeat, replace_all, remove_all
|
|
243
243
|
// regex : regex_replace, regex_remove, regex_matches
|
|
244
244
|
// build : concat, join
|
|
245
|
+
// split : nth, first, last, count_parts
|
|
245
246
|
// encoding : base64_encode, base64_decode
|
|
246
247
|
// shell : shell_quote
|
|
247
248
|
// variables : define
|
|
@@ -253,6 +254,13 @@ and work as full substitution bodies *or* as chain segments:
|
|
|
253
254
|
"go test {{ replace_all(ARGS.flags, ' ', ' -tag=') }}",
|
|
254
255
|
// Strip every match of a regex (here: collapse whitespace runs to a single space):
|
|
255
256
|
"echo {{ regex_replace(ARGS.text, '\\s+', ' ') }}",
|
|
257
|
+
// Split-by-separator scalar accessors — string in, string out, no list type:
|
|
258
|
+
// basename idiom (last segment after `/`); empty string when input ends in `/`.
|
|
259
|
+
"echo basename={{ last(ARGS.path, '/') }}",
|
|
260
|
+
// Pull out the N-th comma-separated field; out-of-bounds returns "".
|
|
261
|
+
"echo target={{ nth(ARGS.csv, ',', '1') }}",
|
|
262
|
+
// Pair `count_parts` with `nth` to bound-check before indexing:
|
|
263
|
+
// "if": "{{ count_parts(ARGS.csv, ',') == '3' }}"
|
|
256
264
|
// Boolean-returning helpers are valid DSL `Truthy` values — use them in `if`:
|
|
257
265
|
// "if": "{{ starts_with(ARGS.path, '/usr') }}"
|
|
258
266
|
// "if": "{{ regex_matches(ARGS.tag, '^v[0-9]+\\.[0-9]+$') }}"
|
package/bin/linux-arm64/run
CHANGED
|
Binary file
|
package/bin/linux-x64/README.md
CHANGED
|
@@ -167,9 +167,9 @@ $ run :env inject -f .env.production -- ./deploy.sh # encrypted values aut
|
|
|
167
167
|
|
|
168
168
|
#### Powerful argument substitution
|
|
169
169
|
|
|
170
|
-
Positional, named, flags, env vars, and runtime context (`{{ RUN.os }}` / `{{ RUN.
|
|
171
|
-
`{{ RUN.file }}` / `{{ RUN.parent }}`) — with chained fallbacks and required values. The
|
|
172
|
-
avoids collisions with shell `$(...)` command substitution.
|
|
170
|
+
Positional, named, flags, env vars, and runtime context (`{{ RUN.os }}` / `{{ RUN.arch }}` / `{{ RUN.shell }}` /
|
|
171
|
+
`{{ RUN.cwd }}` / `{{ RUN.file }}` / `{{ RUN.parent }}`) — with chained fallbacks and required values. The
|
|
172
|
+
`{{ ... }}` syntax avoids collisions with shell `$(...)` command substitution.
|
|
173
173
|
|
|
174
174
|
```jsonc
|
|
175
175
|
"PORT": "{{ ARGS.port ? ENV.PORT ? '3000' }}",
|
|
@@ -242,6 +242,7 @@ and work as full substitution bodies *or* as chain segments:
|
|
|
242
242
|
// transform : escape, repeat, replace_all, remove_all
|
|
243
243
|
// regex : regex_replace, regex_remove, regex_matches
|
|
244
244
|
// build : concat, join
|
|
245
|
+
// split : nth, first, last, count_parts
|
|
245
246
|
// encoding : base64_encode, base64_decode
|
|
246
247
|
// shell : shell_quote
|
|
247
248
|
// variables : define
|
|
@@ -253,6 +254,13 @@ and work as full substitution bodies *or* as chain segments:
|
|
|
253
254
|
"go test {{ replace_all(ARGS.flags, ' ', ' -tag=') }}",
|
|
254
255
|
// Strip every match of a regex (here: collapse whitespace runs to a single space):
|
|
255
256
|
"echo {{ regex_replace(ARGS.text, '\\s+', ' ') }}",
|
|
257
|
+
// Split-by-separator scalar accessors — string in, string out, no list type:
|
|
258
|
+
// basename idiom (last segment after `/`); empty string when input ends in `/`.
|
|
259
|
+
"echo basename={{ last(ARGS.path, '/') }}",
|
|
260
|
+
// Pull out the N-th comma-separated field; out-of-bounds returns "".
|
|
261
|
+
"echo target={{ nth(ARGS.csv, ',', '1') }}",
|
|
262
|
+
// Pair `count_parts` with `nth` to bound-check before indexing:
|
|
263
|
+
// "if": "{{ count_parts(ARGS.csv, ',') == '3' }}"
|
|
256
264
|
// Boolean-returning helpers are valid DSL `Truthy` values — use them in `if`:
|
|
257
265
|
// "if": "{{ starts_with(ARGS.path, '/usr') }}"
|
|
258
266
|
// "if": "{{ regex_matches(ARGS.tag, '^v[0-9]+\\.[0-9]+$') }}"
|
package/bin/linux-x64/run
CHANGED
|
Binary file
|
package/bin/win32-arm64/run.exe
CHANGED
|
Binary file
|
package/bin/win32-x64/run.exe
CHANGED
|
Binary file
|
package/package.json
CHANGED