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

[See Toh Jin Wei] iP #16

Open
wants to merge 78 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
78 commits
Select commit Hold shift + click to select a range
556af3f
Add Gradle support
May 24, 2020
379a115
Add skeletal version of Duke
seetohjinwei Aug 12, 2022
da2d0ea
Duke: add tasks
seetohjinwei Aug 12, 2022
c019c1a
Duke: list tasks
seetohjinwei Aug 12, 2022
5b83795
Add Task class
seetohjinwei Aug 12, 2022
29fbd4e
Duke class: change switch-case to conditional
seetohjinwei Aug 12, 2022
ae3b69a
Task class: split toggleDone into markAsDone and markAsUndone
seetohjinwei Aug 12, 2022
26be28f
Duke class: mark tasks as done and not done
seetohjinwei Aug 12, 2022
28026ee
Add Todo class
seetohjinwei Aug 13, 2022
949c716
Add Deadline class
seetohjinwei Aug 13, 2022
81e39e5
Add Event class
seetohjinwei Aug 13, 2022
bb48f99
Duke class: show number of tasks when adding
seetohjinwei Aug 13, 2022
699f9d6
Add automated text UI testing
seetohjinwei Aug 13, 2022
5d4bc0a
Add DukeException and error handling for Todo
seetohjinwei Aug 13, 2022
565a914
Add error handling for Deadline
seetohjinwei Aug 13, 2022
c4c1b12
Add error handling for Event
seetohjinwei Aug 13, 2022
0a321e2
Add error handling for unknown command
seetohjinwei Aug 13, 2022
3d54671
Add tests for error handling
seetohjinwei Aug 13, 2022
7904841
Duke class: change task array to task arraylist
seetohjinwei Aug 13, 2022
a7eb540
Duke class: add ability to delete tasks
seetohjinwei Aug 13, 2022
72d366c
Duke class: improved user input handling
seetohjinwei Aug 13, 2022
ca279e8
Improved input handling for various Todo classes
seetohjinwei Aug 13, 2022
d7f3cae
Duke: Abstracted out operations into individual methods
seetohjinwei Aug 17, 2022
41c9a8a
Load tasks from file
seetohjinwei Aug 17, 2022
4a466ba
Save tasks to file
seetohjinwei Aug 18, 2022
9140c0d
Change dates from String to LocalDate
seetohjinwei Aug 19, 2022
ed90e3a
Merge branch 'branch-Level-7'
seetohjinwei Aug 19, 2022
f6f7a6d
Merge branch 'branch-Level-8'
seetohjinwei Aug 19, 2022
42c07b8
Fix bug on reading saved dates
seetohjinwei Aug 19, 2022
6fcae4e
Add Storage class
seetohjinwei Aug 19, 2022
0519015
Add Ui class
seetohjinwei Aug 20, 2022
ece4fe4
Add Command, CommandResult and *Command classes
seetohjinwei Aug 20, 2022
4176f24
Add Parser class
seetohjinwei Aug 20, 2022
d2acc2f
Add TaskList class
seetohjinwei Aug 20, 2022
fac6452
Reorganise Duke class
seetohjinwei Aug 20, 2022
af2fdde
Divide classes into packages
seetohjinwei Aug 20, 2022
c5c5327
Add Gradle for build, run, test
seetohjinwei Aug 20, 2022
2d61563
Add some JUnit tests
seetohjinwei Aug 21, 2022
0fba36d
Add shadowjar plugin to Gradle
seetohjinwei Aug 21, 2022
2daf647
Add JavaDoc comments
seetohjinwei Aug 21, 2022
23a50fd
Follow coding standard
seetohjinwei Aug 21, 2022
e433e4b
Find task by keyword
seetohjinwei Aug 21, 2022
c64c73d
Merge branch 'branch-A-JavaDoc'
seetohjinwei Aug 21, 2022
550359f
Merge branch 'branch-A-CodingStandard'
seetohjinwei Aug 21, 2022
62cb9bb
Fix some constant names
seetohjinwei Aug 21, 2022
664f583
Merge branch 'branch-Level-9'
seetohjinwei Aug 21, 2022
14852fa
Add no tasks found message
seetohjinwei Aug 21, 2022
5068c00
Merge remote-tracking branch 'upstream/add-gradle-support'
seetohjinwei Aug 23, 2022
026f533
Change LocalDate to LocalDateTime
seetohjinwei Aug 23, 2022
793e73d
Fix minor coding standard violations
seetohjinwei Aug 25, 2022
3d3b398
Add basic JavaFX GUI
seetohjinwei Aug 27, 2022
21dc328
Add command history
seetohjinwei Aug 27, 2022
b1bf5ad
Merge branch 'branch-Level-10'
seetohjinwei Aug 27, 2022
07cf521
Minor change to variable name
seetohjinwei Aug 29, 2022
30a4081
Add assertions
seetohjinwei Sep 2, 2022
44f1648
Improve code quality
seetohjinwei Sep 2, 2022
b3931ef
Add streams
seetohjinwei Sep 2, 2022
ca7a69f
Merge pull request #1 from seetohjinwei/branch-A-Assertions
seetohjinwei Sep 2, 2022
2be643c
Merge branch 'master' into branch-A-CodeQuality
seetohjinwei Sep 2, 2022
ca61ac3
Merge pull request #2 from seetohjinwei/branch-A-CodeQuality
seetohjinwei Sep 2, 2022
ecc6c97
Merge branch 'master' into branch-A-Streams
seetohjinwei Sep 2, 2022
e4feb5c
Merge pull request #3 from seetohjinwei/branch-A-Streams
seetohjinwei Sep 2, 2022
3fc2d50
Add undo command
seetohjinwei Sep 3, 2022
68b2654
Merge branch 'branch-C-Undo'
seetohjinwei Sep 3, 2022
25ccf6f
Add continuous integration
seetohjinwei Sep 4, 2022
e1db3a9
Organise exceptions better
seetohjinwei Sep 5, 2022
628f24b
Fix some comments and SLAP
seetohjinwei Sep 11, 2022
a364cff
Update user guide
seetohjinwei Sep 11, 2022
e774a89
Fix undo actions order
seetohjinwei Sep 11, 2022
eb76bd7
Add message when there are no tasks to list
seetohjinwei Sep 11, 2022
14ad0c3
Add resizing to GUI
seetohjinwei Sep 11, 2022
584cb6a
Improve styling of GUI
seetohjinwei Sep 11, 2022
f267162
Improve messages
seetohjinwei Sep 12, 2022
fa1f752
Add acknowledgement
seetohjinwei Sep 12, 2022
289bc84
Update README.md
seetohjinwei Sep 16, 2022
377a63e
Fix for Linux
seetohjinwei Sep 18, 2022
b6bc9ba
GUI: Set minimum height and width of stage
seetohjinwei Sep 18, 2022
f834b33
Fix crash on Windows and Linux
seetohjinwei Sep 20, 2022
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
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,5 @@ bin/

/text-ui-test/ACTUAL.txt
text-ui-test/EXPECTED-UNIX.TXT
/data
/text-ui-test/data/
36 changes: 16 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,20 @@
# Duke project template
# Little Duke

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.
Little Duke is **great** for anyone who keeps a list of tasks! It

## Setting up in Intellij
* has text-based commands
* has a minimalistic user interface
* is simple but *lightning* fast

Prerequisites: JDK 11, update Intellij to the most recent version.
All you need to is

1. Open Intellij (if you are not in the welcome screen, click `File` > `Close Project` to close the existing project first)
1. Open the project into Intellij as follows:
1. Click `Open`.
1. Select the project directory, and click `OK`.
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:
```
Hello from
____ _
| _ \ _ _| | _____
| | | | | | | |/ / _ \
| |_| | |_| | < __/
|____/ \__,_|_|\_\___|
```
1. have Java 11 installed.
1. download the latest release from [here](https://github.com/seetohjinwei/ip/releases)!
1. double-click it (or run `java -jar duke.jar`)
1. add your tasks!
1. ...
1. profit!

And best of all, it is **FREE**!

Check out the online User Guide [here](https://seetohjinwei.github.io/ip/).
61 changes: 61 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
plugins {
id 'java'
id 'application'
id 'com.github.johnrengelman.shadow' version "5.1.0"
id 'checkstyle'
}

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 {
archiveFileName.set("duke.jar")
}

checkstyle {
toolVersion = '10.2'
}

run{
standardInput = System.in
enableAssertions = true
}
Loading