Skip to content
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

[kenzantonius] iP #378

Open
wants to merge 36 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
556af3f
Add Gradle support
May 24, 2020
d0da323
Add Level 1
Jan 18, 2023
9395dc6
Add Level 2
Jan 18, 2023
2a3787e
Add Level 3
Jan 26, 2023
c76707f
Add Level 4
Jan 26, 2023
2d45761
Add level 5
Jan 30, 2023
5b12a41
Add level 6
Jan 31, 2023
5506608
Add level 7
Feb 13, 2023
30e51fb
Add level 8
Feb 13, 2023
e125b5f
no message
Feb 19, 2023
c47d8ac
Merge branch 'branch-Level-7'
Feb 19, 2023
462d127
no message
Feb 19, 2023
502bbbc
Merge branch 'branch-Level-8'
Feb 19, 2023
cedbe55
Make the code more OOP
Feb 19, 2023
14a39a6
Merge branch 'branch-A-MoreOOP'
Feb 19, 2023
0843b84
Divide classes into packages
Feb 19, 2023
1fcdf42
Merge branch 'branch-A-Packages'
Feb 19, 2023
1bbfa6a
Merge branch 'add-gradle-support'
Feb 19, 2023
f8939fc
Add JUnit tests to test the behavior of the code
Feb 19, 2023
90e04a4
Add JavaDoc comments to the code.
Feb 20, 2023
96be1dc
Merge branch 'branch-A-JavaDoc'
Feb 20, 2023
e864b36
Tweak the code to comply with a coding standard.
Feb 20, 2023
d70d794
Merge branch 'branch-A-CodingStandard'
Feb 20, 2023
44be10d
Implement Level 9. Give users a way to find a task by searching for a…
Feb 20, 2023
fb0b9d4
Merge branch 'branch-Level-9'
Feb 20, 2023
710f5ef
Implement Level 10. Add a GUI to Duke.
Feb 20, 2023
bbce7ed
Merge branch 'branch-Level-10'
Feb 20, 2023
913f4bf
Use Assertions.
Feb 20, 2023
f8f798a
Improve code quality.
Feb 20, 2023
3f90dae
Merge pull request #2 from kenzantonius/branch-A-Assertions
kenzantonius Feb 20, 2023
2ba8057
Merge pull request #3 from kenzantonius/branch-A-CodeQuality
kenzantonius Feb 20, 2023
e16deb6
Merge branch 'master' of https://github.com/kenzantonius/ip
Feb 20, 2023
0e40946
Add Ui.png.
Feb 20, 2023
cd96457
Update README.md
kenzantonius Feb 20, 2023
6bd37c2
Merge branch 'master' of https://github.com/kenzantonius/ip
Feb 20, 2023
94f55bf
Fix bugs.
Mar 2, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Duke project template
# duke.Duke project template

This is a project template for a greenfield Java project. It's named after the Java mascot _Duke_. Given below are instructions on how to use it.

Expand All @@ -13,7 +13,7 @@ Prerequisites: JDK 11, update Intellij to the most recent version.
1. If there are any further prompts, accept the defaults.
1. Configure the project to use **JDK 11** (not other versions) as explained in [here](https://www.jetbrains.com/help/idea/sdk.html#set-up-jdk).<br>
In the same dialog, set the **Project language level** field to the `SDK default` option.
3. After that, locate the `src/main/java/Duke.java` file, right-click it, and choose `Run Duke.main()` (if the code editor is showing compile errors, try restarting the IDE). If the setup is correct, you should see something like the below as the output:
3. After that, locate the `src/main/java/duke.Duke.java` file, right-click it, and choose `Run duke.Duke.main()` (if the code editor is showing compile errors, try restarting the IDE). If the setup is correct, you should see something like the below as the output:
```
Hello from
____ _
Expand Down
57 changes: 57 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
plugins {
id 'java'
id 'application'
id 'com.github.johnrengelman.shadow' version '5.1.0'
id 'org.openjfx.javafxplugin' version '0.0.11'
}

repositories {
mavenCentral()
}

dependencies {
testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-api', version: '5.5.0'
testRuntimeOnly group: 'org.junit.jupiter', name: 'junit-jupiter-engine', version: '5.5.0'

String javaFxVersion = '11'

implementation group: 'org.openjfx', name: 'javafx-base', version: javaFxVersion, classifier: 'win'
implementation group: 'org.openjfx', name: 'javafx-base', version: javaFxVersion, classifier: 'mac'
implementation group: 'org.openjfx', name: 'javafx-base', version: javaFxVersion, classifier: 'linux'
implementation group: 'org.openjfx', name: 'javafx-controls', version: javaFxVersion, classifier: 'win'
implementation group: 'org.openjfx', name: 'javafx-controls', version: javaFxVersion, classifier: 'mac'
implementation group: 'org.openjfx', name: 'javafx-controls', version: javaFxVersion, classifier: 'linux'
implementation group: 'org.openjfx', name: 'javafx-fxml', version: javaFxVersion, classifier: 'win'
implementation group: 'org.openjfx', name: 'javafx-fxml', version: javaFxVersion, classifier: 'mac'
implementation group: 'org.openjfx', name: 'javafx-fxml', version: javaFxVersion, classifier: 'linux'
implementation group: 'org.openjfx', name: 'javafx-graphics', version: javaFxVersion, classifier: 'win'
implementation group: 'org.openjfx', name: 'javafx-graphics', version: javaFxVersion, classifier: 'mac'
implementation group: 'org.openjfx', name: 'javafx-graphics', version: javaFxVersion, classifier: 'linux'
}

test {
useJUnitPlatform()

testLogging {
events "passed", "skipped", "failed"

showExceptions true
exceptionFormat "full"
showCauses true
showStackTraces true
showStandardStreams = false
}
}

application {
mainClassName = "duke.Launcher"
}

shadowJar {
archiveBaseName = "duke"
archiveClassifier = null
}

run{
standardInput = System.in
}
143 changes: 128 additions & 15 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,142 @@
# User Guide

## Features
Duke is a **desktop app for managing tasks, optimized for use via a Command Line Interface** (CLI) while still having the benefits of a Graphical User Interface (GUI). If you can type fast, Duke can get your tasks management done faster than traditional GUI apps.

### Feature-ABC
## Quick start

Description of the feature.
1. Ensure you have Java `11` or above installed in your Computer.

### Feature-XYZ
1. Download the latest `duke.jar` from [here](https://github.com/kenzantonius/ip/releases).

Description of the feature.
1. Copy the file to the folder you want to use as the _home folder_ for your Duke.

## Usage
1. Double click the jar file to run the application.<br>
A GUI similar to the below should appear in a few seconds. Note how the app contains some sample data.<br>
![Ui](images/Ui.png)

### `Keyword` - Describe action
1. Type the command in the command box and press Enter to execute it.<br>
Some example commands you can try:

Describe the action and its outcome.
* `list` : Lists all tasks.

Example of usage:
* `delete 3` : Deletes the 3rd task shown in the task list.

`keyword (optional arguments)`
* `mark 3` : Mark the 3rd task shown in the task list.

Expected outcome:
* `bye` : Exits the app.

Description of the outcome.
1. Refer to the [Features](#features) below for details of each command.

```
expected output
```
--------------------------------------------------------------------------------------------------------------------

## Features

### Adding a todo task: `todo`

Adds a todo task to the task list.

Format: `todo TASK_NAME`

Examples:
* `todo borrow book`

### Adding a deadline task: `deadline`

Adds a event task to the task list.

Format: `deadline TASK_NAME /by DUE_DATE`

Examples:
* `deadline return book /by Sunday`

### Adding a event task: `event`

Adds a event task to the task list.

Format: `event TASK_NAME /from START_DATE /to END_DATE`

Examples:
* `event project meeting /from Mon 2pm /to 4pm`

### Mark a task : `mark`

Marks the specified task from the task list.

Format: `mark INDEX`

* Deletes the task at the specified `INDEX`.
* The index refers to the index number shown in the displayed task list.
* The index **must be a positive integer** 1, 2, 3, …​

Examples:
* `mark 2` marks the 2nd task in the task list.

### Unmark a task : `unmark`

Unmarks the specified task from the task list.

Format: `unmark INDEX`

* Deletes the task at the specified `INDEX`.
* The index refers to the index number shown in the displayed task list.
* The index **must be a positive integer** 1, 2, 3, …​

Examples:
* `unmark 2` unmarks the 2nd task in the task list.

### Listing all tasks : `list`

Shows a list of all tasks in the task list.

Format: `list`

### Locating tasks by keyword: `find`

Finds tasks whose tasks contain any of the given keywords.

Format: `find KEYWORD`

Examples:
* `find John` returns tasks that have a keyword `John`

### Deleting a task : `delete`

Deletes the specified task from the task list.

Format: `delete INDEX`

* Deletes the task at the specified `INDEX`.
* The index refers to the index number shown in the displayed task list.
* The index **must be a positive integer** 1, 2, 3, …​

Examples:
* `delete 2` deletes the 2nd task in the task list.

### Exiting the program : `bye`

Exits the program.

Format: `bye`

### Saving the data

Duke data are saved in the hard disk automatically after any command that changes the data. There is no need to save manually.

### Editing the data file

Duke data are saved as a txt file `[JAR file location]/data/duke.txt`. Advanced users are welcome to update data directly by editing that data file.

<div markdown="span" class="alert alert-warning">:exclamation: **Caution:**
If your changes to the data file makes its format invalid, AddressBook will discard all data and start with an empty data file at the next run.
</div>

### Archiving data files `[coming in v2.0]`

_Details coming soon ..._

--------------------------------------------------------------------------------------------------------------------

## FAQ

**Q**: How do I transfer my data to another Computer?<br>
**A**: Install the app in the other computer and overwrite the empty data file it creates with the file that contains the data of your previous Duke home folder.
Binary file added docs/Ui.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
5 changes: 5 additions & 0 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading