Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
jcs090218 committed Feb 23, 2024
1 parent a8431b2 commit 89f216e
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 5 deletions.
16 changes: 12 additions & 4 deletions docs/content/Development-API/_index.en.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,14 @@ Points to `lisp` directory from the project root.
(message "%s" eask-lisp-root) ; path/to/eask/cli/lisp/
```

## 🔍 Function: eask-working-directory ()

Return the working directory of the program going to be executed.

```elisp
(message "%s" (eask-working-directory)) ; path/to/current/work/space/
```

## 🔍 Function: eask-command ()

Return the current command in string. Suppose the command is:
Expand Down Expand Up @@ -166,7 +174,7 @@ Call another eask script.

## 🔍 Function: eask-import (`url`)

Load and evaluate the script from a url.
Load and evaluate the script from the url.

```elisp
(eask-import "https://raw.githubusercontent.com/emacsmirror/emacswiki.org/master/yes-no.el")
Expand All @@ -176,7 +184,7 @@ Load and evaluate the script from a url.

## 🔍 Macro: eask-defvc< (`version` &rest `body`)

Define scope if Emacs version is below specific version.
Define the scope if the Emacs version is below a specific version.

`VERSION` is an integer and will be compared with `emacs-major-version`.

Expand Down Expand Up @@ -292,7 +300,7 @@ The following output is with Emacs 28.1:

Return a list of Eask files from DIR.

Consider following directory tree:
Consider the following directory tree:

```
. root
Expand All @@ -311,7 +319,7 @@ The following output is with Emacs 28.1:

Find the Eask-file from START-PATH.

Consider following directory tree:
Consider the following directory tree:

```
.project
Expand Down
8 changes: 8 additions & 0 deletions docs/content/Development-API/_index.zh-tw.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,14 @@ $ eask <command> -- args0 args1
(message "%s" eask-lisp-root) ; path/to/eask/cli/lisp/
```

## 🔍 函式: eask-working-directory ()

傳回將要執行的程式的工作目錄。

```elisp
(message "%s" (eask-working-directory)) ; path/to/current/work/space/
```

## 🔍 函式: eask-command ()

返回字符串中的當前命令。假設命令是:
Expand Down
2 changes: 1 addition & 1 deletion lisp/_prepare.el
Original file line number Diff line number Diff line change
Expand Up @@ -1024,7 +1024,7 @@ Argument BODY are forms for execution."
result))

(defun eask-working-directory ()
"Return the working directory of program is going to be executed."
"Return the working directory of the program going to be executed."
(cond ((eask-config-p) user-emacs-directory)
((eask-global-p) (expand-file-name "../../" user-emacs-directory))
(t default-directory)))
Expand Down

0 comments on commit 89f216e

Please sign in to comment.