DiceCli 5.1.4
dotnet tool install --global DiceCli --version 5.1.4
This package contains a .NET tool you can call from the shell/command line.
dotnet new tool-manifest
dotnet tool install --local DiceCli --version 5.1.4
This package contains a .NET tool you can call from the shell/command line.
#tool dotnet:?package=DiceCli&version=5.1.4
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
nuke :add-package DiceCli --version 5.1.4
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
DiceCli
A command-line utility to help gamers roll random dice based on a well defined dice notation. DiceCli parses the notation and rolls the appropriate dice. This can be use for any types of games including most roleplaying games.
Run Dice-Cli in your favorite shell terminal.
Features
- Roll random dice from the command line
- Supports:
- simple dice notation parsing (1d20+5)
- complex dice notations and combination (4dk3 + d8 + 1)
- run interactively to keep rolling dice continuously
- Output total result along with individual die rolls.
Installation
Install globally using the .NET CLI:
dotnet tool install --global DiceCli
To update the tool:
dotnet tool update --global DiceCli
Usage
Welcome to DiceCli! Use this tool to roll random dice of any type.
d20> --help
USAGE:
dice-cli [OPTIONS] [COMMAND]
OPTIONS:
-h, --help Prints help information
-v, --version Prints version information
COMMANDS:
start Starts an interactive prompt for this sample CLI
roll <DICE-NOTATION> Rolls the dice described by the notation string
notation Display details about how dice notations are defined and written
favorites Commands to manage and use favorite rolls
Examples
Roll a single dice string:
dice-cli roll "1d20+5"
Run DiceCli interactively:
dice-cli
You can manage a list of favorite rolls for quick access of your common rolls:
d20> favorites -h
DESCRIPTION:
Commands to manage and use favorite rolls
USAGE:
dice-cli favorites [OPTIONS] <COMMAND>
EXAMPLES:
dice-cli favorites list
dice-cli favorites add -i attack-roll -n Attack (Longsword) -e 1d20+5
dice-cli favorites edit -i attack-roll -n Attack (Short sword) -e 1d20+7
dice-cli favorites delete -i damage-roll
dice-cli favorites roll -i attack-roll
OPTIONS:
-h, --help Prints help information
COMMANDS:
list Lists all favorite rolls
add Adds a new favorite roll
edit Edits an existing favorite roll
delete Removes a favorite roll by name
roll Rolls a favorite roll by name
To roll a previous saved favorite, run the following command:
dice-cli favorites roll "attack-roll'
Feedback
If you use this tool and have any feedback, bugs, or suggestions, please file them in the Issues section of this repository.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
Initial version with ability to roll dice based on known dice notation.