-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #225 from Peefy/run-cli-documents
feat: add cli overview and run command documents.
- Loading branch information
Showing
8 changed files
with
302 additions
and
176 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
--- | ||
sidebar_position: 1 | ||
--- | ||
|
||
# Run | ||
|
||
This command runs the kcl code and displays the output. 'kcl run' takes multiple input for arguments. | ||
|
||
## Args | ||
|
||
```shell | ||
Usage: | ||
kcl run [flags] | ||
|
||
Aliases: | ||
run, r | ||
|
||
Examples: | ||
# Run a single file and output YAML | ||
kcl run path/to/kcl.k | ||
|
||
# Run a single file and output JSON | ||
kcl run path/to/kcl.k --format json | ||
|
||
# Run multiple files | ||
kcl run path/to/kcl1.k path/to/kcl2.k | ||
|
||
# Run OCI packages | ||
kcl run oci://ghcr.io/kcl-lang/hello-world | ||
|
||
# Run the current package | ||
kcl run | ||
|
||
|
||
Flags: | ||
-D, --argument strings Specify the top-level argument | ||
-d, --debug Run in debug mode | ||
-n, --disable_none Disable dumping None values | ||
-E, --external strings Specify the mapping of package name and path where the package is located | ||
--format string Specify the output format (default "yaml") | ||
-h, --help help for run | ||
--no_style Set to prohibit output of command line waiting styles, including colors, etc. | ||
-o, --output string Specify the YAML/JSON output file path | ||
-O, --overrides strings Specify the configuration override path and value | ||
-S, --path_selector strings Specify the path selectors | ||
-q, --quiet Set the quiet mode (no output) | ||
-Y, --setting strings Specify the command line setting files | ||
-k, --sort_keys Sort output result keys | ||
-r, --strict_range_check Do perform strict numeric range checks | ||
-t, --tag string Specify the tag for the OCI or Git artifact | ||
-V, --vendor Run in vendor mode | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
49 changes: 49 additions & 0 deletions
49
i18n/zh-CN/docusaurus-plugin-content-docs/current/tools/cli/kcl/run.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
--- | ||
sidebar_position: 1 | ||
--- | ||
|
||
# 运行 KCL 代码 | ||
|
||
## 参数说明 | ||
|
||
```shell | ||
Usage: | ||
kcl run [flags] | ||
|
||
Aliases: | ||
run, r | ||
|
||
Examples: | ||
# Run a single file and output YAML | ||
kcl run path/to/kcl.k | ||
|
||
# Run a single file and output JSON | ||
kcl run path/to/kcl.k --format json | ||
|
||
# Run multiple files | ||
kcl run path/to/kcl1.k path/to/kcl2.k | ||
|
||
# Run OCI packages | ||
kcl run oci://ghcr.io/kcl-lang/hello-world | ||
|
||
# Run the current package | ||
kcl run | ||
|
||
|
||
Flags: | ||
-D, --argument strings Specify the top-level argument | ||
-d, --debug Run in debug mode | ||
-n, --disable_none Disable dumping None values | ||
-E, --external strings Specify the mapping of package name and path where the package is located | ||
--format string Specify the output format (default "yaml") | ||
-h, --help help for run | ||
--no_style Set to prohibit output of command line waiting styles, including colors, etc. | ||
-o, --output string Specify the YAML/JSON output file path | ||
-O, --overrides strings Specify the configuration override path and value | ||
-S, --path_selector strings Specify the path selectors | ||
-q, --quiet Set the quiet mode (no output) | ||
-Y, --setting strings Specify the command line setting files | ||
-k, --sort_keys Sort output result keys | ||
-r, --strict_range_check Do perform strict numeric range checks | ||
-t, --tag string Specify the tag fo | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.