Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
39c0d76
Changed Duke to Martin
jonyeokj Aug 24, 2023
4d307d8
Added isDone Functionality and Task.java
jonyeokj Aug 24, 2023
5a7a311
Added Tracking for Tasks: Todos, Events, Deadlines
jonyeokj Aug 24, 2023
37a5502
Abstraction of adding Task functions
jonyeokj Aug 24, 2023
7f32576
Edited Duke to Martin in runtest files
jonyeokj Aug 24, 2023
1228c38
Added Exceptions for empty tasks descriptions, invalid commands, inva…
jonyeokj Aug 24, 2023
a46f9a8
Added Delete Function for tasks
jonyeokj Aug 24, 2023
b47fcbf
Added saving functionality, tasks are saved and remembered
jonyeokj Sep 2, 2023
380082a
Removed wildcard import and added header messages to functions
jonyeokj Sep 2, 2023
3a1360f
Added Date and Time formatting to Deadline class, also Added date fun…
jonyeokj Sep 2, 2023
0930fb3
Created Parser, Storage, UI and TaskList classes for better OOP
jonyeokj Sep 2, 2023
002306a
Added Command interface and classes and organized files into packages
jonyeokj Sep 2, 2023
d6550fc
Added Gradle Support
jonyeokj Sep 2, 2023
2a1c9a5
Added DeleteCommandTest and TodoCommandTest files
jonyeokj Sep 2, 2023
67dc221
Implemented the Fat Jar
jonyeokj Sep 2, 2023
2b2ea68
Add JavaDoc comments to the code
jonyeokj Sep 2, 2023
e4b277c
Added Find Command
jonyeokj Sep 2, 2023
6b39994
Added Header comments for Exception classes
jonyeokj Sep 4, 2023
097541b
Changed Martin Bot from CLI to a GUI interface
jonyeokj Sep 9, 2023
7a49ebf
Implement assertions for null values
jonyeokj Sep 13, 2023
cd8ec93
Merge pull request #1 from jonyeokj/branch-A-Assertions
jonyeokj Sep 13, 2023
2445700
Implement A-CodeQuality
jonyeokj Sep 15, 2023
fe7abd0
Merge pull request #2 from jonyeokj/branch-A-CodeQuality
jonyeokj Sep 15, 2023
bc25324
Add Java CI workflow using GitHub Actions
jonyeokj Sep 17, 2023
13ab009
Changed runtest files
jonyeokj Sep 17, 2023
8a2a77c
Change JDK version
jonyeokj Sep 17, 2023
6ae82a3
Add LocalDateTime support to Events
jonyeokj Sep 17, 2023
f33d4f0
Implement Snooze and enhance Event format
jonyeokj Sep 17, 2023
432a0c6
Merge pull request #4 from jonyeokj/branch-B-Snooze
jonyeokj Sep 17, 2023
493ce02
Implement Sort Command and support for parsing Events
jonyeokj Sep 17, 2023
eae61d7
Merge pull request #5 from jonyeokj/branch-C-Sort
jonyeokj Sep 17, 2023
d965a0e
Improve GUI and updated README
jonyeokj Sep 19, 2023
e037039
Edit README file
jonyeokj Sep 20, 2023
0cd6b98
Replace gradle.yml file
jonyeokj Sep 20, 2023
dcba0e8
Change PATH in runtest files
jonyeokj Sep 20, 2023
92022a4
Replace gradle.yml file
jonyeokj Sep 20, 2023
b0556c3
Update FindCommand and Add NoTaskFoundException classes
jonyeokj Sep 20, 2023
d9381e8
Remove text-ui-test file
jonyeokj Sep 20, 2023
0c52d8d
Change build.gradle file
jonyeokj Sep 21, 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
34 changes: 34 additions & 0 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Java CI

on: [push, pull_request]

jobs:
build:
strategy:
matrix:
platform: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.platform }}

steps:
- name: Set up repository
uses: actions/checkout@master

- name: Set up repository
uses: actions/checkout@master
with:
ref: master

- name: Merge to master
run: git checkout --progress --force ${{ github.sha }}

- name: Validate Gradle Wrapper
uses: gradle/wrapper-validation-action@v1

- name: Setup JDK 11
uses: actions/setup-java@v1
with:
java-version: '11'
java-package: jdk+fx

- name: Build and check with Gradle
run: ./gradlew check
66 changes: 66 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
plugins {
id 'java'
id 'application'
id 'com.github.johnrengelman.shadow' version '7.1.2'
id 'org.openjfx.javafxplugin' version '0.0.13'
}

repositories {
mavenCentral()
}

dependencies {
String javaFxVersion = '17.0.7'

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'
testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-api', version: '5.10.0'
testRuntimeOnly group: 'org.junit.jupiter', name: 'junit-jupiter-engine', version: '5.10.0'
}

test {
useJUnitPlatform()

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

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

application {
mainClass.set("martin.gui.Launcher")
}

shadowJar {
archiveFileName = 'martin.jar'
}

sourceSets {
main {
java {
srcDirs = ['src/main/java']
}
resources {
srcDirs = ['src/main/resources']
}
}
}

run {
standardInput = System.in
}
5 changes: 5 additions & 0 deletions data/martin.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
E | 0 | Test | 01/01/2023 1500 | 01/01/2023 1800
E | 1 | Exam | 01/01/2023 1700 | 01/02/2023 0000
D | 1 | Homework | 08/01/2023 1500
D | 0 | Party | 01/02/2023 1800
0 | Read a Book
267 changes: 254 additions & 13 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,270 @@
# User Guide
# Martin Chatbot User Guide

## Features

### Feature-ABC
1. [Date - Find tasks by date](#date---find-tasks-by-date)
2. [Deadline - Create a deadline task](#deadline---create-a-deadline-task)
3. [Event - Create an event task](#event---create-an-event-task)
4. [Todo - Create a todo task](#todo---create-a-todo-task)
5. [Delete - Remove a task from the list](#delete---remove-a-task-from-the-list)
6. [Find - Search for tasks by keyword](#find---search-for-tasks-by-keyword)
7. [List - Display all tasks](#list---display-all-tasks)
8. [Mark - Mark a task as done](#mark---mark-a-task-as-done)
9. [Unmark - Unmark a task as done](#unmark---unmark-a-task-as-done)
10. [Snooze - Delay a task](#snooze---delay-a-task)
11. [Sort - Sort tasks chronologically](#sort---sort-tasks-chronologically)

Description of the feature.
## Usage

### Feature-XYZ
### `date` - Find tasks by date

Description of the feature.
Given a specific date, it displays all tasks (deadlines or events) associated with that date.

## Usage
**Example of usage:**

`date d/M/yyyy`

**Expected outcome:**

`Tasks on [date]`
A list of all deadlines or events for the given date is shown. If there are no tasks on the provided date, the output will display "No tasks on this date."

**Notes:**
- Use the format 'd/M/yyyy' for the date.
- The list will display tasks on the date or events spanning the date.

**Example output:**
```
Tasks on 1 1 2023:

[D][] Homework (by: Jan 01 2023 2359)
[E][] Test (from: Jan 01 2023 1500 to: Jan 01 2023 1700)
```

---

### `deadline` - Create a deadline task

Create a new deadline task and add it to the list. Deadlines have a description and a specific due date-time.

**Example of usage:**

\`deadline [description] /by d/M/yyyy HHmm\`

**Expected outcome:**

A confirmation message indicating that the deadline has been added.

**Example output:**
```
Got it. I've added this task:
[D][] Homework (by: Jan 01 2023 2359)
Now you have [total tasks] tasks in the list.
```

---

### `event` - Create an event task

Create a new event task and add it to the list. Events have a description and a start and end date-time.

**Example of usage:**

\`event [description] /from d/M/yyyy HHmm /to d/M/yyyy HHmm\`

**Expected outcome:**

A confirmation message indicating that the event has been added.

**Example output:**

### `Keyword` - Describe action
```
Got it. I've added this task:
[E][] Meeting (from: Jan 01 2023 1500 to: Jan 01 2023 1700)
Now you have [total tasks] tasks in the list.
```

---

### `todo` - Create a todo task

Create a new todo task and add it to the list. Todos only have a description.

**Example of usage:**

\`todo [description]\`

**Expected outcome:**

A confirmation message indicating that the todo task has been added.

**Example output:**

```
Got it. I've added this task:
[T][] Read a book
Now you have [total tasks] tasks in the list.
```

---

Describe the action and its outcome.
### `delete` - Remove a task from the list

Example of usage:
Delete a task based on its index in the list.

`keyword (optional arguments)`
**Example of usage:**

Expected outcome:
\`delete [index]\`

Description of the outcome.
**Expected outcome:**

A confirmation message indicating that the task has been removed.

**Notes:**
- Provide an integer index for the task's position in the list.
- Index starts from 1 (e.g., `delete 1` for the first task).
- Invalid or out-of-range indices will result in an error message.

**Example output:**
```
Noted. I've removed this task:
[T][] Read a book
Now you have [remaining tasks] tasks in the list.
```

---

### `find` - Search for tasks by keyword

Search for tasks that contain a specified keyword in their descriptions.

**Example of usage:**

\`find [keyword]\`

**Expected outcome:**

A list of tasks whose descriptions contain the specified keyword is displayed.

**Notes:**
- Matches tasks with the keyword as a substring in their description.

**Example output:**
```
expected output
Here are the matching tasks in your list:

[T][] CS lecture
[D][] Submit CS assignment (by: Mar 01 2023 2359)
```

---

### `list` - Display all tasks

Shows a list of all tasks currently in storage.

**Example of usage:**

\`list\`

**Expected outcome:**

A comprehensive list of all your tasks is displayed.

**Example output:**

```
Here are the tasks in your list:

[T][] Read a book
[D][] CS2103T ip submission (by: Sep 17 2023 2359)
[E][] Team meeting (from: Sep 20 2023 1500 to: Sep 20 2023 1700)
```

---

### `mark` - Mark a task as done

Marks a task at the specified index as completed.

**Example of usage:**

\`mark [index]\`

**Expected outcome:**

The specified task is marked as done and a confirmation message is displayed.

**Example output:**

```
Nice! I've marked this task as done:
[T][X] Read a book
```

---

### `unmark` - Unmark a task as done

Unmarks a task at the specified index, setting it back to its incomplete state.

**Example of usage:**

\`unmark [index]\`

**Expected outcome:**

The specified task is unmarked as done and a confirmation message is displayed.

**Example output:**
```
OK, I've marked this task as not done yet:
[T][] Read a book
```

---

### `snooze` - Delay a task

Snoozes a task at the specified index by a given number of minutes.

**Example of usage:**

\`snooze [index] [minutes]\`

**Expected outcome:**

The specified task's deadline or event time is delayed by the given number of minutes, and a confirmation message is shown.

**Notes:**
- Todos do not support snoozing, so ensure you pick tasks that can be snoozed.

**Example output:**
```
Got it. I've snoozed the task:
[D][] Homework (by: Jan 02 2023 0019)
```

---

### `sort` - Sort tasks chronologically

Sorts the tasks in the list chronologically, where deadlines are sorted by their due dates, events are sorted by their start dates, and tasks without dates (like ToDos) are placed at the end.

**Example of usage:**

\`sort\`

**Expected outcome:**

The tasks in the list will be rearranged in a chronological order based on their associated dates and times. A confirmation message will be displayed.

**Notes:**
- Tasks without associated dates (e.g., Todo tasks) will be placed at the end of the list.
- If the task list is empty, a notification will be given.

**Example output:**

```
Tasks have been sorted!
```
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.
Loading