Skip to content

MaYuehan/ip

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BotYue User Guide

Welcome to BotYue, your personal task manager! BotYue is a command-line application designed to help you keep track of your tasks efficiently. Whether it's deadlines, events, or simple to-dos, BotYue has got you covered.

GUI window

Quick Start

  1. Ensure you have Java11 or above installed in your computer.
  2. Download the yue.jar from from here.
  3. Copy the file to the folder that you wish to use as the home folder.
  4. In terminal, run the file by using command java -jar yue.jar

Key Features

  • Adding different types of tasks into the list
  • Task tracking and management
  • Time management

Table of Contents

  1. Adding Tasks
  2. Managing Tasks
  3. Greet and Exit
  4. Handling Exceptions

Adding Tasks

1. Adding Todos

To add a todo task, use the following command format:

todo <description>

Replace <description> with the description of your deadline task.

Example:

todo return book

Expected Output:

Got it. I've added this task:
 [T][] return book
Now you have 1 tasks in the list.

2. Adding Deadlines

To add a deadline task, use the following command format:

deadline <description> /by <deadline>

Replace <description> with the description of your deadline task and <deadline> with the deadline date and time.

The deadline format: yyyy-mm-dd or dd/mm/yyyy.

Example:

deadline Submit report /by 2024-03-15

Expected Output:

Got it. I've added this task:
 [D][] Submit report (by: Mar 15 2024)
Now you have 2 tasks in the list.

3. Adding Events

To add an event, use the following command format:

event <description> /from <start time> /to <end time>

Replace <description> with the description of your deadline task, replace <start time> and <end time> with the date and time.

Time format: yyyy-mm-dd, dd/mm/yyyy or dd/mm/yyyy HH:mm.

Example:

event project meeting /from 12/03/2024 1800 /to 21/03/2024 1830

Expected Output:

Got it. I've added this task:
 [E][] project meeting (from: Mar 12 2024 18:00 to: Mar 12 2024 18:30)
Now you have 3 tasks in the list.

Managing Tasks

1. Listing all tasks

Command format:

list

Example:

list

Expected Output:

Here are the tasks in your list:
1. [T][] return book
2. [D][] Submit report (by: Mar 15 2024)
3. [E][] project meeting (from: Mar 12 2024 18:00 to: Mar 12 2024 18:30)

2. Delete Task

Command format:

delete <task index>

Example:

delete 1

Expected Output:

Noted. I've removed this task:
 [T][] return book
Now you have 2 tasks in the list.

3. Mark Task as Done

Command format:

mark <task index>

Example:

mark 1

Expected Output:

Nice! I've marked this task as done:
 [D][X] Submit report (by: Mar 15 2024)

4. Mark Task as Not Done

Command format:

unmark <task index>

Example:

unmark 1

Expected Output:

OK, I've marked this task as not done yet:
 [D][] Submit report (by: Mar 15 2024)

5. Detect and Remove Duplicates

Command format:

detect

Example:

detect

Expected Output:

If there are two exactly the same todo tasks of return book.

Duplicates removed successfully:
1. [T][] return book

If all the tasks are unique in the list.

Great! There is no duplicates in the task list.

5. Find Tasks

BotYue can help you find the tasks that contains the keyword you provided. This command is case sensitive, and not full-text search.

Command format:

find <keyword>

Example:

find return

Expected Output:

If there are two tasks contain word 'return':

Here are the matching tasks in your list:
[T][] return book
[T][X] return books back to school

If there is no task matching the keyword:

There is no task matching the word: return

Greet and Exit

Greeting

To start communicating with BotYue, user can type a command:

hi

Then, BotYue will response:

Hello!
How can I help you?

Exiting

To end the conversation, input the command:

bye

Then, BotYue will end the conversation:

Bye. Hope to see you again soon!

Handling Exceptions

BotYue provides robust error handling to ensure smooth user interactions. When an error occurs during command processing, BotYue throws an exception along with an informative error message. Below are the common error scenarios and their corresponding error messages:

1. Invalid Command Format

If the user enters an empty command, BotYue displays the following error message:

OOPS!!! Please enter a valid command.

If the user enters an invalid command, BotYue displays the following error message:

OOPS!!! I'm sorry, I don't know what that means :-(

2. Invalid Task Index

When the user attempts to perform an action (e.g., mark, unmark, delete) on a task without an index, BotYue throws the following error:

OOPS!!! Please specify the task index to [action].

When the user attempts to perform an action (e.g., mark, unmark, delete) on a task with an invalid index, BotYue throws the following error:

OOPS!!! Please enter a valid task index to [action].

When the user attempts to perform an action (e.g., mark, unmark, delete) on a task with an index out of range, BotYue throws the following error:

OOPS!!! The index is out of range.

4. Empty Task Description

When adding a todo task or a deadline/event task without a description, BotYue responds with:

Todo

OOPS!!! The description of a todo task cannot be empty.
The correct format of input should be: todo <your task>.

Deadline

OOPS!!! The description of a deadline task cannot be empty.
The correct format of input should be:
deadline <description> /by <deadline>
The time format should be: dd/mm/yyyy or yyyy-mm-dd.

Event

OOPS!!! The description of an event task cannot be empty.
The correct format of input should be:
event <description> /from <start time> /to <end time>
The time format should be: dd/mm/yyyy HH:mm or yyyy-mm-dd or dd/mm/yyyy

5. Empty Deadline/Event Time

If the user fails to specify the deadline or event time, BotYue displays:

Deadline

OOPS!!! The deadline of a deadline task cannot be empty.
The correct format of input should be:
deadline <description> /by <deadline>
The time format should be: dd/mm/yyyy or yyyy-mm-dd.

Event (missing start and end time)

OOPS!!! The time of an event task cannot be empty.
The correct format of input should be: 
event <description> /from <start time> /to <end time>
The time format should be: dd/mm/yyyy HH:mm or yyyy-mm-dd or dd/mm/yyyy

Event (missing end time)

OOPS!!! The end time of an event task cannot be empty.
The correct format of input should be: 
event <description> /from <start time> /to <end time>
The time format should be: dd/mm/yyyy HH:mm or yyyy-mm-dd or dd/mm/yyyy

6. Invalid Deadline/Event Time Format

When the deadline or event time is provided in an incorrect format, BotYue throws an error:

Example:

deadline homework /by 12/03/21

Output:

Unable to parse date/time as the time might be missing or in a wrong format 12/03/21

These error messages help users understand the nature of the problem and guide them in providing the correct input to BotYue.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 98.1%
  • Shell 1.1%
  • Batchfile 0.8%