2

Does "Create project from existing sample" modify anything in the original sample project files?

If so, what is the best way to "Create project from existing sample" without modifying anything in the original sample project files?

(I am assuming project duplication is involved, but step-by-step instructions would be very helpful for future Android-newbies)

The following is a snapshot of the options available, to further clarify my question:

enter image description here

Android Eve
  • 14,864
  • 26
  • 71
  • 96
  • 1
    Are you sure you don't mean "Create project from existing *source*"? (emphasis mine) – CommonsWare Feb 04 '11 at 14:48
  • @CommonsWare Oops... I copied the text verbatim from the Pro Android 2 book that I am using to learn Android development. Sorry. Thanks for pointing this out, I will correct my original message shortly. +1 for the sharp eye. :) – Android Eve Feb 04 '11 at 15:21
  • @CommonsWare Oops again... I overlooked the "Create project from existing SAMPLE" option. This is sooooooo confusing. What is the differene between the two and why is it not explained even in a great book like "Pro Android 2"? – Android Eve Feb 07 '11 at 16:42

2 Answers2

2

Using this "Create project from existing source" option should not modify anything inside the project.

It simply modifies your worskpace settings (inside the .metadata folder of your current workspace) so as to include the imported project into the view.

If you select the "Copy into workspace" option, the original project folder will be copied into your workspace folder, otherwise, Eclipse will work on the original folder. But in both cases the contents of the folder are not modified.

Dunaril
  • 2,757
  • 5
  • 31
  • 53
  • 1
    Mind you that if you start CHANGING the files in your project you are changing the origional files if i'm not mistaken! – Nanne Feb 04 '11 at 15:49
  • It depends if you made a copy of the project into your workspace - that's what I wrote in my edit. It is about the same as doing a copy of the folder into another location from your file explorer, and starting working on the copy – Dunaril Feb 04 '11 at 15:51
  • @Dunaril Thanks and +1. It turns out that I was totally confused by the terminology in the ADT plugin: There are **two** options for creating a project "from existing": Source and Sample. What I really mean is "from **sample**". I didn't see any "Copy into workspace" option. Where do I find it? – Android Eve Feb 07 '11 at 16:46
  • @Dunaril I am posting a link to the exact snapshot of what I see: http://img683.imageshack.us/img683/7551/createprojectfromexisti.png – Android Eve Feb 07 '11 at 16:50
  • @Nanne That's exactly what I meant -- I do want to play with files in the project I created from sample, so that I can learn more, but still retain the original copies to be used as baseline/reference. +1 for helping me articulate this. – Android Eve Feb 07 '11 at 16:53
  • @Android My bad. I did not know about this specific "from existing sample" option. My guess is that it will use the original source, so if you want to keep it untouched you should do a copy of it before modifying the code. I also think that you should ask for more opinions than mine, I know Eclipse but not its specific Android configuration. – Dunaril Feb 07 '11 at 17:00
0

The short answer to this question is Yes.

An excellent analysis of this is provided in the "Yes" link above,

Community
  • 1
  • 1
Android Eve
  • 14,864
  • 26
  • 71
  • 96