Write README
This commit is contained in:
parent
3bbb64d065
commit
1f10bde1b4
20
README.md
20
README.md
@ -32,9 +32,10 @@ read("examples/assets/faithful.csv")
|
|||||||
- [Features](#features)
|
- [Features](#features)
|
||||||
- [Usage](#usage)
|
- [Usage](#usage)
|
||||||
- [Installation](#installation)
|
- [Installation](#installation)
|
||||||
|
- [Contributing](#contributing)
|
||||||
- [The Dust Programming Language](#the-dust-programming-language)
|
- [The Dust Programming Language](#the-dust-programming-language)
|
||||||
- [Variables and Data Types](#variables-and-data-types)
|
- [Variables and Data Types](#variables-and-data-types)
|
||||||
- [Commands](#commands)
|
- [Tools](#tools)
|
||||||
- [Lists](#lists)
|
- [Lists](#lists)
|
||||||
- [Maps](#maps)
|
- [Maps](#maps)
|
||||||
- [Tables](#tables)
|
- [Tables](#tables)
|
||||||
@ -56,6 +57,15 @@ read("examples/assets/faithful.csv")
|
|||||||
|
|
||||||
Dust is an experimental project under active development. At this stage, features come and go and the API is always changing. It should not be considered for serious use yet.
|
Dust is an experimental project under active development. At this stage, features come and go and the API is always changing. It should not be considered for serious use yet.
|
||||||
|
|
||||||
|
To get help with the shell you can use the "help" tool.
|
||||||
|
|
||||||
|
```dust
|
||||||
|
help() # Returns a table will all tool info.
|
||||||
|
help("random") # Returns a table with info on tools in the specified group.
|
||||||
|
# The above is simply a shorthand for this:
|
||||||
|
help() -> where(input, 'tool == "random"')
|
||||||
|
```
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
You must have the default rust toolchain installed and up-to-date. Install [rustup] if it is not already installed. Run `cargo install dust-lang` then run `dust` to start the interactive shell. Use `dust --help` to see the full command line options.
|
You must have the default rust toolchain installed and up-to-date. Install [rustup] if it is not already installed. Run `cargo install dust-lang` then run `dust` to start the interactive shell. Use `dust --help` to see the full command line options.
|
||||||
@ -98,9 +108,9 @@ map.key = "value";
|
|||||||
empty = ();
|
empty = ();
|
||||||
```
|
```
|
||||||
|
|
||||||
### Commands
|
### Tools
|
||||||
|
|
||||||
**Commands** are dust's built-in tools. Some of them can reconfigure your whole system while others are do very little. They may accept different inputs, or none at all. commands in the `random` group can be run without input, but the `random_integer` command can optionally take two numbers as in inclusive range.
|
**Tools** are dust's built-in functions. Some of them can reconfigure your whole system while others do very little. They may accept different inputs, or none at all. For example, commands in the `random` group can be run without input, but the `random_integer` command can optionally take two numbers as in inclusive range.
|
||||||
|
|
||||||
```dust
|
```dust
|
||||||
die_roll = random_integer(1, 6);
|
die_roll = random_integer(1, 6);
|
||||||
@ -108,11 +118,9 @@ d20_roll = random_integer(1, 20);
|
|||||||
coin_flip = random_boolean();
|
coin_flip = random_boolean();
|
||||||
```
|
```
|
||||||
|
|
||||||
Other commands can be found by pressing TAB in the interactive shell.
|
|
||||||
|
|
||||||
```dust
|
```dust
|
||||||
message = "I hate dust.";
|
message = "I hate dust.";
|
||||||
replace(message, "hate", "love");
|
replace(message, "hate", "love")
|
||||||
```
|
```
|
||||||
|
|
||||||
### Lists
|
### Lists
|
||||||
|
Loading…
Reference in New Issue
Block a user