-
Notifications
You must be signed in to change notification settings - Fork 364
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
[zrei] iP #44
base: master
Are you sure you want to change the base?
[zrei] iP #44
Conversation
Make duke echo commands and exit when user types "bye".
Duke can now store text and display the stored text to users.
Tasks can now be marked as done or unmarked as done.
Implement Deadline class that extends from Task.
Implement Todo class that extends from Task.
Implement Event class that extends from Task and make Task an abstract class.
Implement exceptions.
Previously, Files.createDirectory(dirPath) was throwing an IOException when the directory data already existed. Creating the directory data only when it does not exist prevents the IOException from being thrown. The saved task list is now loaded correctly.
Add VS code and local storage files to .gitignore.
Add assertions
Improve code quality
When a help command is issued, Duke outputs a long response containing all commands it recognises. This is hard to read due to the text being longer than the window length, and needing the user to scroll up and down to find the command they want to execute. Let's add a separate window to contain all the commands that Duke recognises, and launch this window when a help command is issued. TODO: * Improve the GUI of the help window
Help command: launch a separate window
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.
I like the use of GIFs and the personalized feel of the project! Looks good with few coding issues, keep up the good work!
src/main/java/duke/Storage.java
Outdated
fw.write(taskList); | ||
fw.close(); | ||
} catch (IOException e) { | ||
throw new DukeException("I couldn't write to storage. I tripped past the entranceway."); |
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.
I like these personalized exception messages!
package duke.command; | ||
|
||
/** Enum to represent commands */ | ||
public enum CommandType { |
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.
I like the use of enums in your implementation of Commands!
import duke.gui.SpriteEmotion; | ||
import duke.task.Task; | ||
|
||
public class DeleteCommand extends Command { |
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.
Perhaps some descriptive header commends for this class?
private static final float ROUNDED_CORNERS_LENGTH = 25; | ||
|
||
private static final Color DUKE_COLOR = Color.CORNFLOWERBLUE; | ||
private static final Color USER_COLOR = Color.CRIMSON; |
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.
Perhaps associated constants should have a constant prefix?
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.
Thanks for pointing this out! I didn't notice this before now.
PRESENTING THE ILLUSTRIOUS DUKE
If you've ever found yourself at a loss on how to keep track of your humongous, ever-increasing mountain of tasks, then Duke is perfect for you!
Duke can do many
god-like, reality-shatteringamazing things, including but not limited to:Control realityRemember your tasks in-between sessions!You, too, can get access to this awesomeness through a few simple steps.
Give up your soulStart it up!Start Duke with this simple
command
:So, what are you waiting for?
And here's some random code that I have to include for some arbitrary reason. It's the classic
helloWorld
function!Can you believe that this printsHello World
?