Skip to content

Commit 360605e

Browse files
committed
Merge branch 'rm-ratatui'
2 parents 47976ca + 6477254 commit 360605e

File tree

15 files changed

+517
-575
lines changed

15 files changed

+517
-575
lines changed

.typos.toml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,3 @@
22
extend-exclude = [
33
"CHANGELOG.md",
44
]
5-
6-
[default.extend-words]
7-
"ratatui" = "ratatui"

Cargo.lock

Lines changed: 3 additions & 160 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,9 @@ include = [
4949
ahash = { version = "0.8.11", default-features = false }
5050
anyhow = "1.0.86"
5151
clap = { version = "4.5.16", features = ["derive"] }
52+
crossterm = { version = "0.28.1", default-features = false, features = ["windows", "events"] }
5253
notify-debouncer-mini = { version = "0.4.1", default-features = false }
5354
os_pipe = "1.2.1"
54-
ratatui = { version = "0.28.0", default-features = false, features = ["crossterm"] }
5555
rustlings-macros = { path = "rustlings-macros", version = "=6.2.0" }
5656
serde_json = "1.0.125"
5757
serde.workspace = true

rustlings-macros/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ include = [
1616
proc-macro = true
1717

1818
[dependencies]
19-
quote = "1.0.36"
19+
quote = "1.0.37"
2020
serde.workspace = true
2121
toml_edit.workspace = true
2222

src/app_state.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -271,6 +271,7 @@ impl AppState {
271271
Ok(exercise.path)
272272
}
273273

274+
// Reset the exercise by index and return its name.
274275
pub fn reset_exercise_by_ind(&mut self, exercise_ind: usize) -> Result<&'static str> {
275276
if exercise_ind >= self.exercises.len() {
276277
bail!(BAD_INDEX_ERR);
@@ -280,7 +281,7 @@ impl AppState {
280281
let exercise = &self.exercises[exercise_ind];
281282
self.reset(exercise_ind, exercise.path)?;
282283

283-
Ok(exercise.path)
284+
Ok(exercise.name)
284285
}
285286

286287
// Return the index of the next pending exercise or `None` if all exercises are done.

src/exercise.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use anyhow::Result;
2-
use ratatui::crossterm::style::{style, StyledContent, Stylize};
2+
use crossterm::style::{style, StyledContent, Stylize};
33
use std::{
44
fmt::{self, Display, Formatter},
55
io::Write,

src/init.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use anyhow::{bail, Context, Result};
2-
use ratatui::crossterm::style::Stylize;
2+
use crossterm::style::Stylize;
33
use serde::Deserialize;
44
use std::{
55
env::set_current_dir,

0 commit comments

Comments
 (0)