about summary refs log tree commit diff
path: root/src/database.rs
diff options
context:
space:
mode:
authorJoan Lledó <jlledom@member.fsf.org>2023-09-16 11:34:25 +0200
committerJoan Lledó <jlledom@member.fsf.org>2023-09-30 13:14:45 +0200
commit5ff42c0a2d7944fd4bbfb424dd0fa05ced266469 (patch)
tree7045b3a8ea3b30637a43cf4f873e5bde03a59397 /src/database.rs
parent549803558d22b36ac6ac178722f2a8cc0548531e (diff)
downloadFurtherance-5ff42c0a2d7944fd4bbfb424dd0fa05ced266469.tar.zst
Implement ToString trait for Task
Diffstat (limited to 'src/database.rs')
-rw-r--r--src/database.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/database.rs b/src/database.rs
index 6c558fe..f422d23 100644
--- a/src/database.rs
+++ b/src/database.rs
@@ -38,6 +38,12 @@ pub struct Task {
     pub tags: String,
 }
 
+impl ToString for Task {
+    fn to_string(&self) -> String {
+        format!("{} #{}", self.task_name, self.tags)
+    }
+}
+
 #[derive(
     Debug,
     Clone,