Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Java Build a JavaFX Application Build a Pomodoro App Explore Existing Code

kabir k
PLUS
kabir k
Courses Plus Student 18,036 Points

How to get the files and folders into the Pomodoro project like Craig's?

At 1:03 of the Explore Existing Code video, I noticed that Craig already has all his files and folder set up in the Pomodoro project folder and just continued with the video without explaining how he got them there. I also noticed a .gitignore file in the project folder as well.

Would someone please explain how to get to this point?

Thanks.

5 Answers

Seth Kroger
Seth Kroger
56,413 Points

First go the the Downloads tab by the teacher's notes and download the project files. Unzip them. You can move the unzipped folder wherever you need to. Then in your IDE of choice, import the folder as a new project (in IntelliJ its File > New > Project From Existing Sources, others will vary).

kabir k
kabir k
Courses Plus Student 18,036 Points

I have downloaded the project files and unzipped them. Then I have moved the s3v1 folder that contains the needed folders and files to my Downloads folder.

kabir k
kabir k
Courses Plus Student 18,036 Points

I see Create New Project and Import Project on IntelliJ start up window

Seth Kroger
Seth Kroger
56,413 Points

You want Import then.

Hi Kabir,

Have you downloaded the project files and have you got Intelli-J iDEA running? If you're not familiar with Git, the .gitignore can be safely, erm, ignored. If you are familiar with Git, just add the project root to Git, and the .gitignore file will auto-generate.

You need to download the project files, then extract them to a location. Then point IDEA at an 'existing project' and locate the project folder. That should get you to where Craig is; maybe without the involvement of Git.

Let me know how you get on.

Steve.

kabir k
kabir k
Courses Plus Student 18,036 Points

Yes, I have downloaded the project files and got IntelliJ IDEA running. How do I point IDEA to an 'existing project'?

Seth's note below will help with that in more detail.

The opening splash screen gives you multiple options, one is about an existing project.

kabir k
kabir k
Courses Plus Student 18,036 Points

So, how do I add the project root to Git, for the .gitignore file to show up in the Pomodoro project folder. What are the steps to accomplish this?

Do you know how to use Git? If not, there's plenty of courses within Treehouse that covers it, like here. The file you can see there has no bearing on the running of the Pomodoro application so if you want to progress through the course without having a Git root, that's absolutely fine. Otherwise, run through the Git Basics course which will tell you how to run git init in your root folder (after installing Git) and many other useful functions that Git provides.

kabir k
kabir k
Courses Plus Student 18,036 Points

As I'm running out of time, I was hoping for a quick step by step guide to get the .gitignore file in my Pomodoro project folder without having to go through Git courses, but thanks anyway

You don't need the .gitignore file in your project; it is far quicker to proceed without it. Git is about version control, among other things, not JavaFX. You can proceed without it; you won't use it in the course at all.

As in my previous post, if you install git (unless you're on a Mac when it comes pre-bundled) go to your project root folder and type git init. That starts your local repo. Then type git add . (with the full stop, or git add -A) to add all your files, then git commit -m "initial commit" - and that should do it.

Alternatively, don't do any of that, just go to your project root folder and create a file called .gitignore - it'll serve the same purpose.

No problem! :smile: :+1:

kabir k
PLUS
kabir k
Courses Plus Student 18,036 Points

Hi Seth, I did the import one but it didn't work. So, I had to manually create a Pomodoro folder, copy and paste the 5 items into it and follow the steps you mentioned. But I'm still missing the .gitignore file. Do you know the step by step way of getting it to show up in the Pomodoro project as seen on the video?

You get this first:

https://goo.gl/photos/tS3jj3pAziTrGAjr8

Then click Open to get this and select your folder:

https://goo.gl/photos/ift6YVTo3FCTMfN18

Hope that helps ...

Steve.

Carlos Reyes
Carlos Reyes
30,056 Points

This is what worked for me:

File > New > Project > JavaFX Project Name: Pomodoro I don't know why but I had to use project location to create the folder, in c:\users\user\IdeaProjects\Pomodoro

Then copy/paste the folders in s3v1. Delete the sample folder Right click and run, in com.treehouse.pomodoro\Main