diff options
author | Akshay <[email protected]> | 2020-07-23 18:09:28 +0100 |
---|---|---|
committer | Akshay <[email protected]> | 2020-07-23 18:09:28 +0100 |
commit | 2f47f50b0382491099391185c6a2702b1370b206 (patch) | |
tree | fd8ed91e0785cf78ec39c3d1ff1b573b7ee234ee | |
parent | 91cb3ebf5b3af666b13f4821ff25f219fdccd7b9 (diff) |
remove dependency on rustc v1.45, bump to v0.2.1v0.2.1
-rw-r--r-- | Cargo.lock | 2 | ||||
-rw-r--r-- | Cargo.toml | 2 | ||||
-rw-r--r-- | src/command.rs | 3 |
3 files changed, 3 insertions, 4 deletions
@@ -295,7 +295,7 @@ dependencies = [ | |||
295 | 295 | ||
296 | [[package]] | 296 | [[package]] |
297 | name = "dijo" | 297 | name = "dijo" |
298 | version = "0.2.0" | 298 | version = "0.2.1" |
299 | dependencies = [ | 299 | dependencies = [ |
300 | "chrono", | 300 | "chrono", |
301 | "clap", | 301 | "clap", |
@@ -1,6 +1,6 @@ | |||
1 | [package] | 1 | [package] |
2 | name = "dijo" | 2 | name = "dijo" |
3 | version = "0.2.0" | 3 | version = "0.2.1" |
4 | authors = ["Akshay <[email protected]>"] | 4 | authors = ["Akshay <[email protected]>"] |
5 | edition = "2018" | 5 | edition = "2018" |
6 | description = "Scriptable, curses-based, digital habit tracker" | 6 | description = "Scriptable, curses-based, digital habit tracker" |
diff --git a/src/command.rs b/src/command.rs index 38d48e9..0372065 100644 --- a/src/command.rs +++ b/src/command.rs | |||
@@ -61,8 +61,7 @@ pub fn open_command_window(s: &mut Cursive) { | |||
61 | let completion = get_habit_completion(word, &habit_list); | 61 | let completion = get_habit_completion(word, &habit_list); |
62 | eprintln!("{:?} | {:?}", completion, contents); | 62 | eprintln!("{:?} | {:?}", completion, contents); |
63 | if let Some(c) = completion { | 63 | if let Some(c) = completion { |
64 | let cb = | 64 | let cb = view.set_content(format!("{}", contents) + &c[word.len()..]); |
65 | view.set_content(format!("{}", contents) + c.strip_prefix(word).unwrap()); | ||
66 | return Some(EventResult::Consumed(Some(cb))); | 65 | return Some(EventResult::Consumed(Some(cb))); |
67 | }; | 66 | }; |
68 | return None; | 67 | return None; |