2

I have kind of a strange problem.

As I have read in this Question I have to add my .iml files to Git, because I am not using Maven.

But the .iml file in the Root-Folder changes its name depending on the Foldername the Project is cloned to :

Project Cloned to Folder "Test" the iml is --> Test.iml
Project Cloned to Folder "ProjectName"     --> Projectname.iml

How should this work, if I have to add the .iml File to Git, because People can clone the repository to whatever folder they like.

Community
  • 1
  • 1
JDurstberger
  • 4,127
  • 8
  • 31
  • 68

1 Answers1

1

Seems impossible to use different names for a tracked file in different repositories.

An alternative may be to keep the project with the .iml file in the sub-folder of the git root folder. In this way, no matter what folder people clone to, the name of the sub-folder for the project is not changed and so does the .iml file.

Landys
  • 7,169
  • 3
  • 25
  • 34
  • So you would put the whole Project in a subdirectory which then gets commited / pushed – JDurstberger Sep 29 '14 at 06:31
  • Yes, put the source codes of the project in a sub-directory. You may have `docs`, `test` and any other things in the root folder. I just searched `android` in `github`, and got the first item https://github.com/github/android for your reference. Its project is in a sub-directory called `app`. – Landys Sep 29 '14 at 07:55