From 3946f2f7dcc67fd0fa37acf2c4574c79d464fc87 Mon Sep 17 00:00:00 2001 From: glyph Date: Sun, 2 Oct 2022 17:17:00 +0100 Subject: [PATCH] add instructions to include sled and xdg dependencies --- part_3_database_follows/README.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/part_3_database_follows/README.md b/part_3_database_follows/README.md index 034f988..0772bf3 100644 --- a/part_3_database_follows/README.md +++ b/part_3_database_follows/README.md @@ -62,7 +62,14 @@ impl Database { } ``` -The initialisation method requires a `Path` in order to open / create the database. We can use the [xdg](https://crates.io/crates/xdg) crate to generate a path using the XDG Base Directory specification. Open `src/main.rs` and add the following code: +The initialisation method requires a `Path` in order to open / create the database. We can use the [xdg](https://crates.io/crates/xdg) crate to generate a path using the XDG Base Directory specification. Add the dependencies for `sled` and `xdg` to `Cargo.toml`: + +```toml +sled = "0.34" +xdg = "2.4.1" +``` + +Now open `src/main.rs` and add the following code: ```rust mod db;