aboutsummaryrefslogtreecommitdiffstats
path: root/src/command/history.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/command/history.rs')
-rw-r--r--src/command/history.rs12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/command/history.rs b/src/command/history.rs
index 72f821c5..4caf4c17 100644
--- a/src/command/history.rs
+++ b/src/command/history.rs
@@ -32,13 +32,21 @@ pub enum HistoryCmd {
}
impl HistoryCmd {
- pub fn run(&self, db: SqliteDatabase) -> Result<()> {
+ pub fn run(&self, db: &mut SqliteDatabase) -> Result<()> {
match self {
HistoryCmd::Start { command: words } => {
let command = words.join(" ");
let cwd = env::current_dir()?.display().to_string();
- let h = History::new(chrono::Utc::now().timestamp_nanos(), command, cwd, -1, -1);
+ let h = History::new(
+ chrono::Utc::now().timestamp_nanos(),
+ command,
+ cwd,
+ -1,
+ -1,
+ None,
+ None,
+ );
// print the ID
// we use this as the key for calling end