1. (Not in Android Studio) Make a copy / duplicate the existing ‘OldProject’ directory.
  2. (Not in Android Studio) Rename the copied directory to ‘NewProject’.
  3. Start Android Studio 3.4.
  4. Select ‘Open an existing Android Studio project’.
  5. Navigate to the ‘NewProject’ directory, select it and click ‘Open’.
  6. Build -> Clean project.
  7. File -> Sync project with gradle file.
  8. Click the ‘1:Project’ side tab and choose Android from the drop-down menu.
  9. Expand the app -> java folder.
  10. Right-click and select Refactor -> Rename.
  11. Give a new name to the new project in the Rename dialog.
  12. Select ‘Search in comments and strings’ and ‘Search for text occurrences’. Click Refactor.
  13. The ‘Find: Refactoring Preview’ pane appears, click ‘Do Refactor’.
  14. Expand the res -> values folder and double-click the strings.xml file.
  15. Change the app_name string value to “New Project”.

Check the file and sync the project with the Gradle file:

  1. In Android Studio Project pane, expand Gradle Scripts and open build.gradle (Module: app).
  2. In android -> defaultConfig -> applicationId check that the value of the applicationID key is “”. If the value isn’t correct, change it manually.
  3. File -> Sync project with gradle file

Make sure that the app and package names are correct in the AndroidManifest.xml file:

  1. Expand the app -> manifests folder and double click AndroidManifest.xml.
  2. Check that the ‘package’ name is correct. It should be “”. If not, change it manually.


위 작업후에도 firebase를 사용한 경우

You have added the Google Play Services plugin to the project, which reads from the google-services.json found in your app module.

The google-services.json contains service configuration data, such as Google Project ID, application package name, etc..

Since the application package name is also stored in that json, it will not match anymore, so you have to create a new application in your Firebase console, and export the new configuration json.

Then replace the google-services.json in your project with the one you have generated.

위 작업을 해주어야 한다. 



우선 firebase 페이지에가서 새로운 프로젝트를 만든다.

그리고 setting페이지 하단을 보면 아래와 같은에 여기서 android icon 선택


google-services.json만드는 과정


gradle화일 둘다 수정

아래) android studio 왼쪽편에 있는 화일매니저에서 android 를  project 로 바꾸고 app안에 google-services.json이 있는 것을 확인할수 있다.

새로 생성된 화일 붙여넣기



이렇게 하고도 navigation args관련해서 navigation화일에 들어가 각각 argument의 class를 새로 고쳐주어야 했다. 또 몇몇 에러나는 부분을 손수 수정해줘야 했다.(extension func 도 그 한예에 속한다.)


git을 사용하는 경우 기존의 git을 없애고 새로 시작해야한다.

In order to drop the current git repository and create a new one you need to:

  • Go to the project’s directory: cd PROJECT_DIRECTORY
  • Remove all the git specific files: rm -rf $(find . -name ".git*")
  • Initialize a new git repository: git init

This doesn’t remove your project’s files, only git configs

참고로 macos에서 숨겨진 화일도 보고 싶은경우

command + shift + . 을 하면 된다.