Skip to content

Commit 33464a7

Browse files
authored
docs: update root, iroh, iroh-metrics readmes (#1258)
* docs: update readme.md * docs: iroh crate readme * add very basic iroh-metrics README
1 parent d1b4e18 commit 33464a7

File tree

5 files changed

+56
-21
lines changed

5 files changed

+56
-21
lines changed

Diff for: .img/iroh_wordmark.svg

+1
Loading

Diff for: README.md

+12-20
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
1-
<h1 align="center">iroh</h1>
2-
<div align="center">
3-
<strong>
4-
IPFS reimagined.
5-
</strong>
6-
</div>
1+
<img alt="iroh" src="./.img/iroh_wordmark.svg" width="100" />
2+
https://iroh.computer
73

8-
<br />
4+
Bytes, Distributed.
95

106
<div align="center">
117
<!-- Crates version -->
@@ -27,8 +23,12 @@
2723

2824
<div align="center">
2925
<h3>
26+
<a href="https://iroh.computer/docs">
27+
Docs Site
28+
</a>
29+
<span> | </span>
3030
<a href="https://docs.rs/iroh">
31-
API Docs
31+
Rust Docs
3232
</a>
3333
<span> | </span>
3434
<a href="https://github.com/n0-computer/iroh/releases">
@@ -38,25 +38,17 @@
3838
</div>
3939
<br/>
4040

41-
## Usage
41+
Iroh is a protocol for syncing & moving bytes. Bytes of any size, on any device. At it's core, it's a peer-2-peer network built on a _magic socket_ that establishes [QUIC](https://en.wikipedia.org/wiki/QUIC) connections between peers. Peers request and provide _blobs_ of opaque bytes that are incrementally verified by their BLAKE3 hash during transfer.
4242

43-
### Cli
44-
Sending data
45-
```sh
46-
$ ./iroh provide <file>
47-
```
43+
## Using Iroh
4844

49-
Receiving data
50-
```sh
51-
$ ./iroh get <hash>
52-
```
45+
Iroh is delivered as a Rust library and a CLI. Run `cargo build` to build the `iroh` CLI. To use iroh in your project, check out https://iroh.computer/install to get started.
5346

5447
### As a library
5548
Disable default features when using `iroh` as a library:
5649
`iroh = { version: "...", default-features = false }`
5750

58-
This removes dependencies that are only relevant when using `iroh` as
59-
a cli.
51+
This removes dependencies that are only relevant when using `iroh` as a cli.
6052

6153
# License
6254

Diff for: iroh-metrics/README.md

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# iroh-metrics
2+
3+
Metrics collection for iroh. It keeps the "glue" necessary to expose metrics defined metrics for collection: an HTTP server that exposes tracked metrics that a service like prometheus can poll for recording.
4+
5+
Nearly all metrics in iroh are recorded as simple counters.
6+
7+
# License
8+
9+
This project is licensed under either of
10+
11+
* Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or
12+
http://www.apache.org/licenses/LICENSE-2.0)
13+
* MIT license ([LICENSE-MIT](LICENSE-MIT) or
14+
http://opensource.org/licenses/MIT)
15+
16+
at your option.
17+
18+
### Contribution
19+
20+
Unless you explicitly state otherwise, any contribution intentionally submitted
21+
for inclusion in this project by you, as defined in the Apache-2.0 license,
22+
shall be dual licensed as above, without any additional terms or conditions.

Diff for: iroh/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name = "iroh"
33
version = "0.4.1"
44
edition = "2021"
55
readme = "README.md"
6-
description = "IPFS reimagined"
6+
description = "Bytes. Distributed."
77
license = "MIT/Apache-2.0"
88
authors = ["dignifiedquire <[email protected]>", "n0 team"]
99
repository = "https://github.com/n0-computer/iroh"

Diff for: iroh/README.md

+20
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,25 @@
11
# iroh
22

3+
The iroh crate defines both the `iroh` library and `iroh` command-line interface (CLI).
4+
5+
For more details on Iroh, see https://iroh.computer.
6+
7+
## Building the CLI
8+
9+
Simply run `cargo build` from the project root, it produces the `iroh` CLI by default.
10+
11+
## Using as a rust crate
12+
13+
Because iroh builds the CLI by default, you should disable `default-features` when importing the `iroh` crate via cargo:
14+
15+
```toml
16+
[dependencies]
17+
iroh = { version: "...", default-features = false }
18+
```
19+
20+
## Running Examples
21+
22+
examples are located in `iroh/examples`. Some have their own cargo.toml to show different use cases, and as such are shipped as their own packages. For these run them with `cargo run --package`. eg: `cargo run --package hello-world`
323

424
# License
525

0 commit comments

Comments
 (0)