Skip to content

docs: add reference documents for the file.read_env function #378

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions docs/reference/model/file.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,3 +65,9 @@ Copy a file or directory from the source path to the destination path.
`mv(src: str, dest: str)`

Move a file or directory from the source path to the destination path.

## read_env

`read_env(key: str) -> str`

Read the environment variable `key` from the current process.
Original file line number Diff line number Diff line change
Expand Up @@ -77,3 +77,9 @@ weight: 100
`write(filepath: str, content: str)`

将内容写入指定路径的文件。如果文件不存在,将会被创建。如果文件存在,其内容将被替换。

## read_env

`read_env(key: str) -> str`

从当前进程中读取环境变量 `key` 的值。
Original file line number Diff line number Diff line change
Expand Up @@ -77,3 +77,9 @@ weight: 100
`write(filepath: str, content: str)`

将内容写入指定路径的文件。如果文件不存在,将会被创建。如果文件存在,其内容将被替换。

## read_env

`read_env(key: str) -> str`

从当前进程中读取环境变量 `key` 的值。
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "kcl-website",
"version": "0.8.0",
"version": "0.9.0",
"private": true,
"scripts": {
"docusaurus": "docusaurus",
Expand Down
6 changes: 6 additions & 0 deletions versioned_docs/version-0.9/reference/model/file.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,3 +65,9 @@ Copy a file or directory from the source path to the destination path.
`mv(src: str, dest: str)`

Move a file or directory from the source path to the destination path.

## read_env

`read_env(key: str) -> str`

Read the environment variable `key` from the current process.
Loading