From d1309a36b2404b312e9aa23f28ec4d76e9e9e19e Mon Sep 17 00:00:00 2001 From: Antoine Stevan <44101798+amtoine@users.noreply.github.com> Date: Mon, 20 Mar 2023 05:05:49 +0100 Subject: [PATCH] standard library: fix the readme (#8526) # Description as we now want to put all the library in `std.nu` alone, this PR removes the mentions to "creating a separate submodule from `std.nu`" from the `README` of the standard library and adds a few clarifications about the structure of the library. # User-Facing Changes ``` $nothing ``` # Tests + Formatting ``` $nothing ``` # After Submitting ``` $nothing ``` --- crates/nu-utils/standard_library/README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/crates/nu-utils/standard_library/README.md b/crates/nu-utils/standard_library/README.md index ec09056d1f..ea8c477373 100644 --- a/crates/nu-utils/standard_library/README.md +++ b/crates/nu-utils/standard_library/README.md @@ -51,8 +51,12 @@ use /path/to/standard_library/std.nu > ``` ## :pencil2: contribute to the standard library +- all the commands of the standard_library are located in [`std.nu`](std.nu) +- the tests are located in files that have a name starting with "test_", e.g. [`test_std.nu`](test_std.nu) +- a test runner, at [`tests.nu`](tests.nu), allows to run all the tests automatically + ### :wrench: add new commands -- add new standard commands to [`std.nu`](std.nu), or preferably create a new submodule. +- add new standard commands by appending to [`std.nu`](std.nu) - add associated tests to [`test_std.nu`](tests_std.nu) or preferably to `test_.nu`. - define a new exported (!) `test_` command - import the `assert` functions you need at the top of the functions, e.g. `use std.nu "assert eq"`