-
Notifications
You must be signed in to change notification settings - Fork 196
[kristianachwan] iP #204
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
kristianachwan
wants to merge
46
commits into
nus-cs2113-AY2223S2:master
Choose a base branch
from
kristianachwan:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
[kristianachwan] iP #204
Changes from all commits
Commits
Show all changes
46 commits
Select commit
Hold shift + click to select a range
1e44177
Update welcome message
kristianachwan d604700
Add greet, echo, and exit feature
kristianachwan ea35053
Add add and list feature
kristianachwan 6c9b878
Add mark as done feature and Task class
kristianachwan 76d2e4c
Follow coding standard and refactor repeated code
kristianachwan 1c8a1eb
Create ToDo, Deadline, Event entities
kristianachwan 5d62adf
Incorporate adding todo, deadline, event entity
kristianachwan 9423d8a
Fix formatting
kristianachwan aa5f8b5
Bug fix empty line + add UI testing
kristianachwan 4fffeda
Change linebreak into the safer linearSeparator
kristianachwan 3cb44ea
Fix bug for adding deadline
kristianachwan 02cb628
Reformat code
kristianachwan 6f74566
Reformat code (2)
kristianachwan f9c599b
Refactor using case statement
kristianachwan 37eb12a
Fix bug not adding break in case
kristianachwan 85f757f
Add parser to each entity
kristianachwan 374ac57
Add exceptions and error handling
kristianachwan 3d199c2
Organize into packages
kristianachwan 0f6fcc6
Fix UI-testing
kristianachwan 2ca1e40
Improve variables naming
kristianachwan 075e95f
Adding command and payload model
kristianachwan 967378f
Add unknown command
kristianachwan 5838b80
Improve code quality
kristianachwan 21cedfd
Implement ArrayList for storing tasks
kristianachwan ffc1076
Extract methods refactoring
kristianachwan 5f38dce
Add delete task feature
kristianachwan 2a0f5ab
Add DataAccess class
kristianachwan 2fe149c
Merge pull request #1 from kristianachwan/branch-Level-6
kristianachwan 220b7b7
Merge branch 'master' into branch-Level-7
kristianachwan baac899
Merge pull request #2 from kristianachwan/branch-Level-7
kristianachwan 62219f3
Resolve error after merging
kristianachwan 5a25935
Fix bug writing duke.txt
kristianachwan 3496b8e
Clean code
kristianachwan 8a1dba8
Refactor to more OOP
kristianachwan 2b7328b
Add find feature
kristianachwan a8e51f7
Add method header comments
kristianachwan 08339d6
Merge pull request #3 from kristianachwan/branch-Level-9
kristianachwan f41e223
Syncing with master
kristianachwan 917ba29
Merge pull request #4 from kristianachwan/branch-A-JavaDoc
kristianachwan 5d5a498
Add user guide
kristianachwan 59d2021
Fix typo userguide
kristianachwan 13b1697
Change user guide filenaming
kristianachwan 89999d6
Change filepath of duke.txt
kristianachwan ae2b710
Change the format of printing search results
kristianachwan 2e3774d
Add line separator
kristianachwan 89782e8
Update minor mistake on UG
kristianachwan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| 1. [D][ ] tP Meeting (by: Friday 16.00pm) | ||
| 2. [E][ ] CS2113 tP Meeting (from: Friday 16.00pm to: 18.00pm) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,29 +1,143 @@ | ||
| # User Guide | ||
|
|
||
| ## Features | ||
| Duke is a Command-Line Interface (CLI) task manager. It allows you to keep track of your tasks quickly and navigate | ||
| through those tasks quickly. | ||
|
|
||
| ### Feature-ABC | ||
| ## Features | ||
|
|
||
| Description of the feature. | ||
| - Adding different types of tasks: | ||
| - Todo: the most basic type of task | ||
| - Deadline: type of task which you can assign the due date of it | ||
| - Event: type of task which has a start and end date | ||
| - Searching based on keyword and listing all tasks are also supported | ||
|
|
||
| ### Feature-XYZ | ||
| ## Getting started | ||
|
|
||
| Description of the feature. | ||
| > Java 11 is recommended to run `Duke` | ||
|
|
||
| ## Usage | ||
| 1. Download the latest ip.jar from [here](https://github.com/kristianachwan/ip/releases) | ||
| 2. Go to the directory where you downloaded | ||
| 3. Run `java -jar ip.jar` | ||
|
|
||
| ### `Keyword` - Describe action | ||
| ## Add ToDo | ||
|
|
||
| Describe the action and its outcome. | ||
| Adds todo to your list. Format: `todo <todo-name>` | ||
|
|
||
| Example of usage: | ||
| ### Adding `ToDo` example: | ||
|
|
||
| `keyword (optional arguments)` | ||
| ``` | ||
| todo CS2113 tP Meeting | ||
| ____________________________________________________________ | ||
| Got it. I've added this task: | ||
| [T][ ] CS2113 tP Meeting | ||
| ____________________________________________________________ | ||
| ``` | ||
|
|
||
| ## Add Deadline | ||
|
|
||
| Adds deadline to your list. Format: `deadline <deadline-name> /<due-by>` | ||
|
|
||
| ### Adding `Deadline` example: | ||
|
|
||
| ``` | ||
| deadline tP Meeting /Friday 16.00pm | ||
| ____________________________________________________________ | ||
| Got it. I've added this task: | ||
| [D][ ] tP Meeting (by: Friday 16.00pm) | ||
| ____________________________________________________________ | ||
| ``` | ||
|
|
||
| ## Add Deadline | ||
|
|
||
| Adds event to your list. Format: `event <event-name> /<start-time> /<end-time> ` | ||
|
|
||
| ### Adding `Event` example: | ||
|
|
||
| ``` | ||
| event CS2113 tP Meeting /Friday 16.00pm /18.00pm | ||
| ____________________________________________________________ | ||
| Got it. I've added this task: | ||
| [E][ ] CS2113 tP Meeting (from: Friday 16.00pm to: 18.00pm) | ||
| ____________________________________________________________ | ||
|
|
||
| ``` | ||
|
|
||
| ### Listing all tasks | ||
|
|
||
| List all of your tasks. Format: `list` | ||
|
|
||
| ### Listing all tasks example: | ||
|
|
||
| ``` | ||
| list | ||
| ____________________________________________________________ | ||
| 1. [T][ ] CS2113 tP Meeting | ||
| 2. [D][ ] tP Meeting (by: Friday 16.00pm) | ||
| 3. [E][ ] CS2113 tP Meeting (from: Friday 16.00pm to: 18.00pm) | ||
| ____________________________________________________________ | ||
| ``` | ||
|
|
||
| Expected outcome: | ||
| ## Deleting a task: | ||
|
|
||
| Description of the outcome. | ||
| Delete your task by indicate the index of the task. Format: `delete <task-index>` | ||
|
|
||
| ### Deleting a task example: | ||
|
|
||
| ``` | ||
| delete 1 | ||
| ____________________________________________________________ | ||
| Noted! I've removed this task | ||
| [T][ ] CS2113 tP Meeting | ||
| ____________________________________________________________ | ||
| ``` | ||
| expected output | ||
|
|
||
| ## Finding specific tasks | ||
|
|
||
| Find your task based on specific keyword. Format: `find <keyword>` | ||
|
|
||
| ### Finding specific tasks example | ||
|
|
||
| ``` | ||
| find tP | ||
| ____________________________________________________________ | ||
| [D][ ] tP Meeting (by: Friday 16.00pm) | ||
| [E][ ] CS2113 tP Meeting (from: Friday 16.00pm to: 18.00pm) | ||
| ____________________________________________________________ | ||
| ``` | ||
|
|
||
| ## Marking task as done | ||
|
|
||
| Mark your task as done. It will have `[X]` when it is listed again. | ||
| Format: `mark <task-index>` | ||
|
|
||
| ### Marking task as done example | ||
|
|
||
| ``` | ||
| mark 1 | ||
| ____________________________________________________________ | ||
| Nice! I've marked this task as done: | ||
| [D][X] tP Meeting (by: Friday 16.00pm) | ||
| ____________________________________________________________ | ||
| ``` | ||
|
|
||
| ### Marking task as undone | ||
|
|
||
| Mark your task as undone (or unmark). It will revert back to `[]`. | ||
| Format: `unmark <task-index>` | ||
|
|
||
| ``` | ||
| unmark 1 | ||
| ____________________________________________________________ | ||
| Ok, I've marked this task as not done: | ||
| [D][ ] tP Meeting (by: Friday 16.00pm) | ||
| ____________________________________________________________ | ||
| ``` | ||
|
|
||
| ### Exiting the program | ||
|
|
||
| ``` | ||
| bye | ||
| ____________________________________________________________ | ||
| Bye. Hope to see you again soon! | ||
| ____________________________________________________________ | ||
| ``` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| 1. [T][ ] asd1 | ||
| 2. [T][ ] asd23 | ||
| 3. [T][ ] asd33 | ||
| 4. [T][ ] a | ||
| 5. [D][ ] asd (by: 2pm) |
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,3 @@ | ||
| Manifest-Version: 1.0 | ||
| Main-Class: duke.Duke | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,32 @@ | ||
| package duke; | ||
|
|
||
| import duke.boundary.Ui; | ||
| import duke.controller.TaskList; | ||
| import duke.model.Command; | ||
| import duke.utils.Parser; | ||
| import duke.utils.Storage; | ||
|
|
||
| import java.util.Scanner; | ||
|
|
||
| /** | ||
| * A class that serves as an entry point to the application | ||
| */ | ||
| public class Duke { | ||
| public static void main(String[] args) { | ||
| Storage dataAccess = new Storage("duke.txt"); | ||
| Scanner scanner = new Scanner(System.in); | ||
| TaskList taskList = new TaskList(); | ||
| Ui ui = new Ui(taskList); | ||
| ui.printDuke(); | ||
| String input; | ||
| while (true) { | ||
| input = scanner.nextLine(); | ||
| Command command = Parser.parse(input); | ||
| ui.readCommand(command); | ||
| dataAccess.writeToFile("\t" + taskList.toString()); | ||
| } | ||
|
|
||
| } | ||
|
|
||
|
|
||
| } | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use condition here instead of system.Exit later