Skip to content

Commit

Permalink
fix typo (#71)
Browse files Browse the repository at this point in the history
  • Loading branch information
CorneeldH authored Dec 11, 2024
1 parent be18e99 commit 5729f14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vignettes/custom.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Answering these questions can help you better understand whether your problem is

## The prompt directory

The easiest way to write a new pal that's loaded every time you load R is to add a markdown file to the _prompt directory_. The prompt directory is a folder of markdown files that serves as a library of possible pals. By default, the prompt directory lives at `~/.config/pal`, but that default can be changed by adding a `.pal_dir` option in your `.Rprofile` using `options(pal_dir = some/dir/`). `directory_path()` returns the path to the directory, `directory_set()` changes it, `directory_list()` enumerates all of the prompts that currently live in it, and `directory_load()` registers/refreshes all of the prompts in the directory with the pal package.
The easiest way to write a new pal that's loaded every time you load R is to add a markdown file to the _prompt directory_. The prompt directory is a folder of markdown files that serves as a library of possible pals. By default, the prompt directory lives at `~/.config/pal`, but that default can be changed by adding a `.pal_dir` option in your `.Rprofile` using `options(.pal_dir = some/dir/`). `directory_path()` returns the path to the directory, `directory_set()` changes it, `directory_list()` enumerates all of the prompts that currently live in it, and `directory_load()` registers/refreshes all of the prompts in the directory with the pal package.

To create a new pal, add a prompt to pal's prompt directory with `prompt_new()`. You'll need to supply a `role` (a single keyword describing what the pal does, like `"roxygen"`) and an `interface` describing how the pal will interact with the selection (one of `"replace"`, `"prefix"`, or `"suffix"`). You can also "pre-fill" the contents of the prompt by supplying a file path with the `contents` argument.

Expand Down

0 comments on commit 5729f14

Please sign in to comment.