I was developing some projects over eclipse, but my Eclipse crashed and I need to reinstall it. but how can I open my previous works as Project in Eclipse. I made it a zip file but its not working from Import.
Go to import>Existing Projects to Workspace>Select Root directory
uncheck the "copy projects into workspace" selectbox, and then click "refresh" button, you will be able to import the project
A very common problem.
Related
Just a beginner in android,
Was trying to learn Android and socket IO interaction. So picked up a opensource hello world project as mentioned. But I am not getting how to run such gradle project to my virtual AVD. I have eclipse and Android sdk on ubuntu 14.04. Thanks
You can generate eclipse project by using gradle eclipse plugin.
In your build.gradle,
apply plugin: 'eclipse'
and with running the following gradle task,
$ gradle eclipse
eclipse project will be generated. Another solution would be just using the gradle plugin for eclipse.
But I strongly recommend you to switch your IDE to AndroidStdio when it comes to Android development.
I have a simple trick to import Android Studio Projects in Eclipse.
Create a new Android Project on Eclipse with default settings.
Go to the workspace folder and open the project folder.
Now in parallel, open the gradle project in another folder.
Open the main application folder where the following folders/files will be there: java, res and AndroidManifest.xml
In you eclipse project (that you just created) folder, open the src folder and delete the contents of the folder. Now paste the contents of the java folder (the one mentioned in step 4) (it will contain the complete source code)
In you eclipse project (that you just created) folder, open the res folder and delete the contents of the folder. Now paste the contents of the res folder (the one mentioned in step 4) (it will contain all the resources of the project)
In you eclipse project (that you just created) folder, you will also see the AndroidManifest.xml. Now replace it with the AndroidManifest.xml of the gradle project (the one mentioned in step 4).
Now go back to Eclipse, select the project you just created, hit F5 (to refresh the contents). Clean the project.
Note: If there are any library dependencies for the project, you will have to locate it on the internet (or locate them if available in the gradle project) and copy it in the libs folder for you eclipse project. If the library is given as another project, follow the above steps again, right click on the library-project, and check the is Library option and import it as library in the application project.
Hope this helped. Cheers :)
I imported a project into eclipse but incidentally I forgot to check-mark the checkbox "copy projects into workspace" option. Now after wards(importing has been done) Is there any way through which I can copy the project into the workspace.
Also, while importing a maven project into eclipse which option should I select in order to copy the project into the workspace?
delete project (JUST FROM WORKSPACE, it will prompt you on delete with check box) and re import it
I am trying to import the projects I made on other machine. So I copied the workspace folder from other machine into current PC and replaced the default workspace folder that was created when I installed fresh eclipse. After replacing workspace, when I try to import the projects from the workspace, I get error "Invalid Project description".
What should I do to import all my projects in eclipse?
Thanks
I've found that when I try to import an existing project into my workspace, it only works if I select the General->Existing Projects into Workspace. If I select Android->Existing Android Code into workspace then I have an issue where it doesn't import properly.
Maybe you are facing a similar issue.
Try the following:
File >> New >> Android Project
Then choose:
Create project from existing source
And put your project path
OK try this, Zip your project folder. File->Import->General->Existing Projects into Workspace->Select archive file
or
http://code.google.com/p/android/issues/detail?id=8431
How to import existing Android project into Eclipse?
File->Import->General->Existing Projects into workspace
This works perfectly. Try it.
For anyone, if the above doesn't work for you, you may want to check that the .classpath and .project files are there. I had a similar experience where I was trying to import my project files' from my svn working copy. However, it shows up as a greyed out unselectable project. Copying .classpath and .project file from a local backup made it work.
I was facing same issue.
Eclips cannot import project if it is already exist in workspace. Double check if you already have a project with same name.
I downloaded and extract jmeter's source code: http://jmeter.apache.org/download_jmeter.cgi
How do I go about opening this project in IntelliJ?
I tried to 'open project' and navigated to the directory, but it doesn't seem to pickup any of the files to open the project.
Do I have to import or something?
Create a new project over existing source--you can't open a project when there's been no project set up.
IntelliJ will pop up a window with the source directories it discovers; by default they'll all be checked.
You can add the Ant build file in the "Ant Build" tool window to make Ant builds easier.
UPDATE
Since JMeter 5.2 it uses Gradle instead of ant, you can easily import the project into IntelliJ like so:
You require IntelliJ 2018.3.1 or newer.
Open the build.gradle.kts file with IntelliJ IDEA and choose Open as
Project Make sure Create separate module per source set is selected
Make sure Use default Gradle wrapper is selected
In the File already exists dialogue, choose Yes to overwrite
In the Open Project dialogue, choose Delete Existing Project and Import (if IntelliJ project already exists)
ORIGINAL
These are the steps I followed to get the JMeter source code into IntelliJ. I've included some screenshots on my blog.
Import project from Git: https://github.com/apache/jmeter.git
Select "Create project from existing sources"
Name the project
Select all source file directories
Deselect any libraries, (add them later)
Select all of the discovered modules
Select the SDK (you might need to add one if you've not used IntelliJ before)
Press Next and then Finish
Click the "Ant Build" menu in IntelliJ
Press add and add the build.xml file
Run the download_jars target
Open project settings (Ctrl+Alt+Shift+S) then add the downloaded jars to the project
Notes:
You can compile and start the GUI by executing the run_gui ant target
If there are any errors in IntelliJ when viewing files (or pressing build project) you can usually solve them by pressing alt+enter on the offending code and making the appropriate 'module' a dependency - however this shouldn't stop you developing or running things via ant.
I've also created a screencast of the above steps:
https://youtu.be/r0Z79PjEb80
When I do File -> Import, General (from the pop-up window)->Existing Projects into Workspace, I can browse to where all my projects are and import them so my Eclipse workspace folder with its .metadata is in a separate location from my source directory.
The problem is, if I add a new project or even add a new file within an existent project, the new files get made in my Eclipse workspace folder, not over where the other code lives.
How do I tell Eclipse to put new code in the source directory, not in the workspace directory? When importing, I did not check the checkboxes "Copy projects into workspace" or "Add project to working sets" (Add project to working sets requires the selection of working sets, which I don't know about).
It depends on the kind of project you are creating. For example, a "Project" type project that just contains dumb files lets you uncheck the "Use default location" option and will actually be created in whatever directory you give it.
Java projects, on the other hand force you to create them in the workspace.
For project types that eclipse will only create in the workspace you can use the following workaround.
Create the project in your workspace.
Delete the project from eclipse without deleting the files on disk.
Use your OS tools to move the project folder where you want it.
Back in eclipse: File -> Import -> Existing Projects into Workspace
Browse to folder containing your relocated project.
Make sure to uncheck the "Copy projects into workspace" option