nushell/crates/nu-command/src/random
NotTheDr01ds 3dc9691aaa
Clarify random int help (#13503)
# Description

Minor nitpicks, but the `random int` help and examples were a bit
ambiguous in several aspects. Updated to clarify that:

* An unconstrained `random int` returns a non-negative integer. That is,
the smallest potential value is 0. Technically integers include negative
numbers as well, and `random int` will never return one unless you pass
it a range with a negative lower-bound.

* To that end, changed the final example to demonstrate a negative
lower-bound.

* The range is inclusive. While most people would probably assume this,
the changes make this explicit in the examples and argument description.

# User-Facing Changes

Help only

# Tests + Formatting

- 🟢 `toolkit fmt`
- 🟢 `toolkit clippy`
- 🟢 `toolkit test`
- 🟢 `toolkit test stdlib

# After Submitting

N/A
2024-07-31 16:34:38 -05:00
..
bool.rs Add command_prelude module (#12291) 2024-03-26 21:17:30 +00:00
chars.rs Add command_prelude module (#12291) 2024-03-26 21:17:30 +00:00
dice.rs Add and use new Signals struct (#13314) 2024-07-07 22:29:01 +00:00
float.rs Range refactor (#12405) 2024-04-06 09:04:56 -05:00
int.rs Clarify random int help (#13503) 2024-07-31 16:34:38 -05:00
mod.rs remove random integer in favor of random int (#10568) 2023-10-19 18:42:07 +02:00
random_.rs Make get_full_help take &dyn Command (#12903) 2024-05-19 19:56:33 +02:00
uuid.rs Add command_prelude module (#12291) 2024-03-26 21:17:30 +00:00