This is a project template for a greenfield Java project. It's the starting point for the Panda chatbot. Given below are instructions on how to use it.
Prerequisites: JDK 25, update Intellij to the most recent version.
- Open Intellij (if you are not in the welcome screen, click
File>Close Projectto close the existing project first) - Open the project into Intellij as follows:
- Click
Open. - Select the project directory, and click
OK. - If there are any further prompts, accept the defaults.
- Click
- Configure the project to use JDK 25 (not other versions) as explained in here.
In the same dialog, set the Project language level field to theSDK defaultoption. - After that, locate the
src/main/java/Panda.javafile, right-click it, and chooseRun Panda.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:____________________________________________________________ PANDA Hello! I'm Panda. What can I do for you? ____________________________________________________________ todo read book ____________________________________________________________ Got it. I've added this task: [T][ ] read book Now you have 1 tasks in the list. ____________________________________________________________ deadline return book /by June 6th ____________________________________________________________ Got it. I've added this task: [D][ ] return book (by: June 6th) Now you have 2 tasks in the list. ____________________________________________________________ event project meeting /from Aug 6th 2pm /to 4pm ____________________________________________________________ Got it. I've added this task: [E][ ] project meeting (from: Aug 6th 2pm to: 4pm) Now you have 3 tasks in the list. ____________________________________________________________ list ____________________________________________________________ Here are the tasks in your list: 1.[T][ ] read book 2.[D][ ] return book (by: June 6th) 3.[E][ ] project meeting (from: Aug 6th 2pm to: 4pm) ____________________________________________________________ mark 2 ____________________________________________________________ Nice! I've marked this task as done: [D][X] return book (by: June 6th) ____________________________________________________________ unmark 2 ____________________________________________________________ OK, I've marked this task as not done yet: [D][ ] return book (by: June 6th) ____________________________________________________________ unmark 2 ____________________________________________________________ OK, I've marked this task as not done yet: [ ] return book ____________________________________________________________ list ____________________________________________________________ Here are the tasks in your list: 1.[ ] read book 2.[ ] return book ____________________________________________________________ bye ____________________________________________________________ ( ) ( ) ( ) \ | / \|/ .-----. / \ | o o | \_______/ Bye. Hope to see you again soon! ____________________________________________________________
This project is configured to build a runnable fat JAR using the Shadow plugin.
- Make sure Java 25 is active.
- From the project root, run:
./gradlew shadowJar
- The packaged JAR is created at:
build/libs/panda.jar - Run it with:
java -jar build/libs/panda.jar
This produces a single executable JAR that includes the application and its dependencies.
Warning: Keep the src\main\java folder as the root folder for Java files (i.e., don't rename those folders or move Java files to another folder outside of this folder path), as this is the default location some tools (e.g., Gradle) expect to find Java files.