I have done Refactor -> Rename in Eclipse and the project has been renamed successfully in Eclipse. But when I copy/paste it in a folder, it still keeps the old name.
How can I completely rename it?
I have done Refactor -> Rename in Eclipse and the project has been renamed successfully in Eclipse. But when I copy/paste it in a folder, it still keeps the old name.
How can I completely rename it?
Open your
.project
file from the project folder and change following value in it.You need to change to Project name in it.
Another way,
Copy Old project from the Project explorer , and paste it over there, It will ask for new name, give a new name , and done.
COPY AND PASTE ANDROID PROJECT and CREATE a NEW PROJECT is neat. Follow the following steps below:
A. If you are using Eclipse and all you need to do is first open the project that you want to copy(DON"T FORGET TO OPEN THE PROJECT THAT YOU NEED TO COPY), then clone(copy/paste) your Android project within the explorer package window on the left side of Eclipse. Eclipse will ask you for a new project name when you paste. Give it a new project name. Since Eclipse project name and directory are independent of the application name and package, the following steps will help you on how to change package names. Note: there are two types of package names. (The main package as it indicated in Manifest file and sub-package which holds all java files)
TrueStudio is also Eclipse based, it probably works in a similar way. However refactoring the project name does not work. The way I clone one project to another is by using Ctrl-C/Ctrl-V on the main folder, and then rename the new folder to the desired name. Now we only need to change a directory name and some file names. And we need to modify the content of a couple of files. After that, the project can be opened in TrueStudio.
In short, see below example:
A python script placed in the root directory of the project can do this:
Any comments or suggestions for improvements are welcome!
1) Right click on your package -> refactor -> rename. select Update references and rename subpackages.
2) Change packagename in AndroidMenifest.xml
3) In resources->values->string.xml change app_name to "new_name"
Hope that will work!