diff --git a/README.md b/README.md index 93737a9..eb81fff 100644 --- a/README.md +++ b/README.md @@ -131,7 +131,7 @@ If you want to TBC... - `TASK` - create task + prefix with space if you want a task to start with a command character - + copy in text with newlines to create one task per line + + paste text with newlines to create one task per line - `.` - clear all filters - `.TASK` + activate task by id @@ -140,7 +140,8 @@ If you want to TBC... - `.2` - set view depth to the given number (how many subtask levels to show, default is 1) - `/[TEXT]` - activate task or filter by smart-case substring match (empty: move to root) - `||TASK` - create and activate a new task procedure (where subtasks automatically depend on the previously created task) -- `|[TASK]` - (un)mark current task as procedure or create a sibling task depending on the current one and move up +- `|[TASK]` - mark current task as procedure or create a sibling task depending on the current one and move up +- sibling task shortcut? Dot or slash can be repeated to move to parent tasks before acting. Append `@TIME` to any task creation or change command to record the action with the given time. @@ -274,7 +275,7 @@ since they will automatically take on that context. By automating these contexts based on triggers, scripts or time, relevant tasks can be surfaced automatically. -#### Example +#### Vision of Work-Life-Balance for Freelancer In the morning, your groggy brain is good at divergent thinking, and you like to do sports in the morning. diff --git a/src/main.rs b/src/main.rs index 0f64ccd..1fb65cd 100644 --- a/src/main.rs +++ b/src/main.rs @@ -554,6 +554,7 @@ async fn main() -> Result<()> { match arg { None => match tasks.get_position() { None => { + info!("Use | to create dependent sibling task and || to create a procedure"); tasks.set_state_filter( StateFilter::State(State::Procedure.to_string())); } @@ -643,7 +644,7 @@ async fn main() -> Result<()> { Ok(number) => max = number, Err(e) => warn!("Unsure what to do with {:?}", e), } - let (label, mut times) = tasks.times_tracked(); + let (label, times) = tasks.times_tracked(); println!("{}\n{}", label.italic(), times.rev().take(max).collect_vec().iter().rev().join("\n")); } else if let Ok(key) = PublicKey::parse(arg) { // TODO also match name @@ -658,7 +659,7 @@ async fn main() -> Result<()> { } } } else { - let (label, mut times) = tasks.times_tracked(); + let (label, times) = tasks.times_tracked(); println!("{}\n{}", label.italic(), times.rev().take(80).collect_vec().iter().rev().join("\n")); } @@ -749,7 +750,6 @@ async fn main() -> Result<()> { _ => if Regex::new("^wss?://").unwrap().is_match(command.trim()) { - tasks.move_to(None); if let Some((url, tasks)) = relays.iter().find(|(key, _)| key.as_ref().is_some_and(|url| url.as_str().starts_with(&command))) { selected_relay.clone_from(url); println!("{}", tasks); @@ -780,7 +780,7 @@ async fn main() -> Result<()> { println!("{}", tasks); } Err(ReadlineError::Eof) => break 'repl, - Err(ReadlineError::Interrupted) => break 'repl, // TODO exit if prompt was empty, or clear + Err(ReadlineError::Interrupted) => break 'repl, // TODO exit only if prompt is empty, or clear Err(e) => warn!("{}", e), } }